mirror of
https://github.com/EpochModTeam/DayZ-Epoch.git
synced 2025-12-14 20:13:13 +03:00
+ Increased raise horde distance to 65m. + decreased raise horde action timer to 7 seconds. + sync with 1.7.6.1 CE
31 lines
899 B
Plaintext
31 lines
899 B
Plaintext
private["_animalbody","_qty","_rawfoodtype","_ehLoc"];
|
|
_animalbody = _this select 0;
|
|
_qty = _this select 1;
|
|
_rawfoodtype = getText (configFile >> "CfgSurvival" >> "Meat" >> typeOf _animalbody >> "rawfoodtype");
|
|
|
|
if (local _animalbody) then {
|
|
for "_x" from 1 to _qty do {
|
|
_animalbody addMagazine _rawfoodtype;
|
|
};
|
|
|
|
[time, _animalbody] spawn {
|
|
private ["_timer", "_body"];
|
|
_timer = _this select 0;
|
|
_body = _this select 1;
|
|
while {(count magazines _body >0) and (time - _timer < 300) } do {
|
|
sleep 5;
|
|
};
|
|
//["dayzHideBody",_body] call broadcastRpcCallAll;
|
|
dayzHideBody = _body;
|
|
hideBody _body; // local player
|
|
publicVariable "dayzHideBody"; // remote player
|
|
sleep 5;
|
|
deleteVehicle _body;
|
|
true;
|
|
};
|
|
|
|
} else {
|
|
_ehLoc = "client";
|
|
if (isServer) then { _ehLoc = "server"; };
|
|
diag_log format["gutObject EH on %1 item not local ! Type: %2",_ehLoc,str(_animalbody)];
|
|
}; |