allDead – Talk

From Bohemia Interactive Community
Revision as of 17:03, 21 February 2014 by Bull a (talk | contribs) (Created page with "Can use a server game logic to create your own simple garbage collector <code> if (!isServer || !isDedicated) exitWith {}; while {isDedicated} do { _list = allDead; for {...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Can use a server game logic to create your own simple garbage collector

if (!isServer || !isDedicated) exitWith {}; while {isDedicated} do {

 _list = allDead;
 for {_i = 0; _i < count _list; _i = _i + 1} do
 {
   deleteVehicle _x;
 };
 sleep 600; // Cleans server every 10 minutes

};