mirror of
https://github.com/EpochModTeam/DayZ-Epoch.git
synced 2025-12-14 12:12:34 +03:00
Add a few missing playerIsNear checks
Blocks duping method reported by Sercan and confirmed with @oiad . Thanks
This commit is contained in:
@@ -14,9 +14,14 @@ if (DZE_permanentPlot) then {
|
||||
_ownerID = _obj getVariable["ownerPUID","0"];
|
||||
};
|
||||
|
||||
// Make sure you are the closest player to the tent
|
||||
_playerNear = _obj call dze_isnearest_player;
|
||||
if (_playerNear) exitWith {dayz_actionInProgress = false; localize "str_epoch_player_16" call dayz_rollingMessages;};
|
||||
|
||||
// Make sure no other players are nearby
|
||||
_playerNear = {isPlayer _x} count (([_obj] call FNC_GetPos) nearEntities ["CAManBase",10]) > 1;
|
||||
if (_playerNear) exitWith {dayz_actionInProgress = false; localize "str_pickup_limit_5" call dayz_rollingMessages;};
|
||||
|
||||
_packobj = getText (configFile >> "CfgVehicles" >> typeOf _obj >> "pack");
|
||||
|
||||
player removeAction s_player_packtent;
|
||||
|
||||
Reference in New Issue
Block a user