From 2a4130349c5ae0068c306cea62d2e8f33a9ee0c1 Mon Sep 17 00:00:00 2001 From: "[VB]AWOL" Date: Fri, 25 Oct 2013 01:19:02 -0500 Subject: [PATCH] setdate experiment #2 --- SQF/dayz_code/init/compiles.sqf | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/SQF/dayz_code/init/compiles.sqf b/SQF/dayz_code/init/compiles.sqf index 35938ce10..aac0e3093 100644 --- a/SQF/dayz_code/init/compiles.sqf +++ b/SQF/dayz_code/init/compiles.sqf @@ -396,16 +396,13 @@ if (!isDedicated) then { }; player_setDate = { - private ["_setdatebool","_forEachIndex","_newdate","_n"]; + private ["_setdatebool"]; _setdatebool = false; - _n = _this; - { - if (_x != (_n select _forEachIndex)) exitWith { - _setdatebool = true; - }; - } forEach date; + if (!([_this, date] call BIS_fnc_areEqual)) exitWith { + _setdatebool = true; + }; if (_setdatebool) then { - setDate _newdate; + setDate _this; }; };