1.0.1.7 DEV TEST

+ [CHANGED] Can now fill empty fuel barrels on standard fuel tanks.
+ [CHANGED] Increased range of crafting from 2m to 3m
+ [FIXED] Removed repair action from tow truck with VIL_asistvan_DZE
+ [ADDED] Tow truck VIL_asistvan_DZE can tow vehicles that fit within
the bounding box of the model.
+ [ADDED] Ability for fuel trucks to fill nearby vehicles 30m when
engine is running.
+ [CHANGED] Reworked Epoch events scheduler and made it more accurate.
+ [REMOVED] Road debris no longer spawn loot, helps with performance and
we have added extra loot positions in the world.
+ and more
This commit is contained in:
[VB]AWOL
2013-08-05 11:09:26 -05:00
parent 9b1a3b3927
commit 9e5957b89d
40 changed files with 641 additions and 599 deletions

View File

@@ -10,15 +10,24 @@ diag_log("EPOCH EVENTS INIT");
EventSchedulerLastTime = "";
epoch_eventIsAny = {
private ["_boolReturn","_event","_real"];
private ["_boolReturn","_event","_date"];
_event = _this select 0;
_real = _this select 1;
_date = _this select 1;
_boolReturn = false;
if (typeName _event == "STRING") then {
_boolReturn = (_event == "any");
} else {
_boolReturn = (_real == _event);
};
_index = 0;
{
_bool = false;
if (typeName _x == "STRING") then {
_boolReturn = true;
} else {
_boolReturn = ((_date select _index) == _x);
};
if (!_boolReturn) exitWith {};
_index = _index + 1;
} forEach _event;
_boolReturn
};
@@ -36,41 +45,28 @@ while {true} do {
_datestr = str(_date);
if (EventSchedulerLastTime != _datestr) then {
// This is only ran every minute.
// Once a minute.
EventSchedulerLastTime = _datestr;
// diag_log ("EVENTS: Local Time is: " + str(_date));
diag_log ("EVENTS: Local Time is: " + _datestr);
{
if([(_x select 0),(date select 0)] call epoch_eventIsAny) then {
if([(_x select 1),(date select 1)] call epoch_eventIsAny) then {
if([(_x select 2),(date select 2)] call epoch_eventIsAny) then {
if([(_x select 3),(date select 3)] call epoch_eventIsAny) then {
if([(_x select 4),(date select 4)] call epoch_eventIsAny) then {
// EXECUTE SCRIPT
diag_log ("RUNNING EVENT: " + (_x select 5) + " on " + EventSchedulerLastTime);
_handle = [] execVM "\z\addons\dayz_server\modules\" + (_x select 5) + ".sqf";
};
};
};
};
if([[(_x select 0),(_x select 1),(_x select 2),(_x select 3),(_x select 4)],_date] call epoch_eventIsAny) then {
diag_log ("RUNNING EVENT: " + (_x select 5) + " on " + _datestr);
_handle = [] execVM "\z\addons\dayz_server\modules\" + (_x select 5) + ".sqf";
};
} forEach EpochEvents;
_time = diag_tickTime;
// perform cleanup here
if ((_time - zero_cleanDead) > 600) then
{
if ((_time - zero_cleanDead) > 600) then {
call server_cleanDead;
zero_cleanDead = _time;
};
if ((_time - zero_cleanLoot) > 1800) then
{
if ((_time - zero_cleanLoot) > 1800) then {
call server_cleanLoot;
zero_cleanLoot = _time;
};
};
};
sleep 5;
sleep 10;
};