mirror of
https://github.com/EpochModTeam/DayZ-Epoch.git
synced 2025-12-14 04:02:37 +03:00
Replace sleep with uiSleep
see the below links for more info. uiSleep is based off of a more accurate method of tracking time, whereas sleep can fluctuate depending on application performance since it is based on framerate. https://community.bistudio.com/wiki/uiSleep https://community.bistudio.com/wiki/sleep_vs_uiSleep https://community.bistudio.com/wiki/sleep
This commit is contained in:
@@ -29,7 +29,7 @@ fnc_usec_pitchWhine = {
|
||||
};
|
||||
r_pitchWhine = true;
|
||||
[] spawn {
|
||||
sleep 32;
|
||||
uiSleep 32;
|
||||
r_pitchWhine = false;
|
||||
};
|
||||
};
|
||||
@@ -54,7 +54,7 @@ fnc_usec_damageUnconscious = {
|
||||
if (r_player_unconscious) then {
|
||||
_unit action ["eject", _veh];
|
||||
waitUntil{((vehicle _this) != _this)};
|
||||
sleep 1;
|
||||
uiSleep 1;
|
||||
_unit setVariable ["NORRN_unconscious", true, true];
|
||||
_unit playActionNow "Die";
|
||||
};
|
||||
@@ -132,7 +132,7 @@ fnc_med_publicBlood = {
|
||||
while {(r_player_injured || r_player_infected) && r_player_blood > 0} do {
|
||||
player setVariable["USEC_BloodQty",r_player_blood,true];
|
||||
player setVariable["medForceUpdate",true];
|
||||
sleep 5;
|
||||
uiSleep 5;
|
||||
};
|
||||
};
|
||||
|
||||
@@ -166,7 +166,7 @@ fnc_usec_playerBleed = {
|
||||
{player setVariable[_x,false,true];} count USEC_woundHit;
|
||||
player setVariable ["USEC_injured",false,true];
|
||||
};
|
||||
sleep 1;
|
||||
uiSleep 1;
|
||||
};
|
||||
};
|
||||
|
||||
@@ -226,14 +226,14 @@ fnc_usec_damageBleed = {
|
||||
_source setDropInterval 0.02;
|
||||
_point attachTo [_unit,_modelPos,_wound];
|
||||
|
||||
sleep 5;
|
||||
uiSleep 5;
|
||||
|
||||
while {((_unit getVariable["USEC_injured",true]) && (alive _unit))} do {
|
||||
scopeName "loop";
|
||||
if (vehicle _unit != _unit) then {
|
||||
BreakOut "loop";
|
||||
};
|
||||
sleep 1;
|
||||
uiSleep 1;
|
||||
};
|
||||
deleteVehicle _source;
|
||||
deleteVehicle _point;
|
||||
@@ -257,7 +257,7 @@ fnc_usec_recoverUncons = {
|
||||
r_player_cardiac = false;
|
||||
r_player_handler1 = false;
|
||||
|
||||
sleep 1;
|
||||
uiSleep 1;
|
||||
|
||||
disableUserInput false;
|
||||
if (vehicle player == player) then {
|
||||
|
||||
Reference in New Issue
Block a user