Dateien

> > CS2D > Lua Scripts > Memory Cleaner/Garbage Collector v1.0
DateiübersichtCS2D-ÜbersichtLua Scripts-Übersicht

Englisch Memory Cleaner/Garbage Collector v1.0 >

17 Kommentare2 kb, 447 Downloads

alt Memory Cleaner/Garbage Collector v1.0

MikuAuahDark
User Off Offline

Memory Cleaner or Garbage Collector by user MikuAuahDark

∗ Description ∗
This LUA would make your server more faster by cleaning memory every 5 minutes and every 5 times(default, can be configured at MemoryCleaner.lua)
This LUA is presents for a newbie scripter
This LUA is useful when you're running big scripts
It just use collectgarbage() LUA function

∗ Features ∗
• > file cs2d Improved AddHook 2 compatible
• > Configurable settings(see below)

∗ How to Install ∗
> Just put MemoryCleaner.lua or MemoryCleaner_desc.lua at sys/lua/autorun

∗ Reserved Global Variables ∗
> MemoryCleaner
> CleanTimes
> TimeToClean
> ShowMsg
> NormHook

∗ Information ∗
> Hooks: 1(cs2d lua hook second)
> Lines: 30

∗ Configuration ∗
On MemoryCleaner.lua or MemoryCleaner_desc.lua you can see a configuration variable. Here is the list of it
• CleanTimes - Every 5 minutes do x times cleaning(default 5)
• TimeToClean - Clean every x seconds(default 300, 5 minutes)
• ShowMsg - Show message when cleaning is performed to stdout/console. true by default
• NormHook - Always use normal hook(cs2d lua cmd addhook) even if file cs2d Improved AddHook 2 is used(true by default, it can make it little faster)

∗ Rules ∗
√ You can use it for your server
√ You can edit it
√ You can upload at another website, say user MikuAuahDark made it
× You can't say this is yours
× You can't upload on another website without put me on credits

∗ Notes ∗
1. Tell me if there is a bugs
2. There is a file named MemoryCleaner_desc.lua. It just do same but file contents are different. it has description how the code works.
3. You can use MemoryCleaner.lua or MemoryCleaner_desc.lua. It just do same
4. Note that this is just simple scripts

∗ Version History ∗
> v1.0
>
ADDED
Initial Release
1× editiert, zuletzt 03.11.13 01:00:23
Zugelassen von Seekay

Download Download

2 kb, 447 Downloads

Kommentare

17 Kommentare
Zum Anfang Vorherige 1 Nächste Zum Anfang

Logge dich ein!

Du musst dich einloggen, um selber Kommentare verfassen zu können!Einloggen

alt

tek69
User Off Offline

bad as shit.

alt

MikuAuahDark
User Off Offline

user MrSlave hat geschrieben
WHA DIS TING MANE TO MUCH TEXTTT
sorry but i can't understand you.

alt

MrSlave
BANNED Off Offline

WHA DIS TING MANE TO MUCH TEXTTT

alt

MikuAuahDark
User Off Offline

user _Yank hat geschrieben
Does this really make a diference ?
yes. You can see it decreased with task manager

alt

_Yank
User Off Offline

Does this really make a diference ?
About how much seconds of diference ? - In a super hero script + admin script v30 for example.
Ãnywas helpful.
Ich mag es!

alt

VADemon
User Off Offline

user MikuAuahDark hat geschrieben
This LUA would make your server more faster by cleaning memory every 5 minutes and every 5 times

Why do you think that you're more efficient than Lua itself?
Same story as in Java with system.gc() IMHO

alt

Avo
User Off Offline

You know, it's very easy, but at least you wrote proper description. All descriptions would look like yours.

about variables access >

alt

MikuAuahDark
User Off Offline

user Promaster hat geschrieben
Nice Script, But need more explanation about how this Script really works. What exactly does it Cleans?
a value that can't accessed by any variable
and also do you want to see some explanation how it works? take a look at MemoryCleaner_desc.lua

alt

Promaster
User Off Offline

Nice Script, But need more explanation about how this Script really works. What exactly does it Cleans?
Ich mag es!

alt

MikuAuahDark
User Off Offline

user Obronca hat geschrieben
This Script is Hard :v , I Think you must teach me to make it :v
simple, just put this at your code
1
collectgarbage("collect")
i already said that is a simple script

alt

iii
User Off Offline

is good
Ich mag es!

alt

Obronca
User Off Offline

This Script is Hard :v , I Think you must teach me to make it :v
Ich mag es!

alt

MikuAuahDark
User Off Offline

user iii hat geschrieben
i am suspicious. Does collectgarbage("collect") only delete values which are not needed?

It's delete a value which does not have any variable.

alt

XiBaoZi
COMMUNITY BANNED Off Offline

Useful.
Ich mag es!

alt

iii
User Off Offline

i am suspicious. Does collectgarbage("collect") only delete values which are not needed?
Ich mag es!
Zum Anfang Vorherige 1 Nächste Zum Anfang