Check if players are owner of other plots correctly

This fixes the checking done not picking up that a player was the owner of the plot by the userlist on the plot when it wasn't them that placed it
This commit is contained in:
oiad
2017-10-16 00:04:59 +13:00
committed by GitHub
parent de94cdfb23
commit f0e8796996

View File

@@ -45,7 +45,7 @@ if (_isPole) then {
_distance = DZE_PlotPole select 1;
if (DZE_limitPlots && {!(dayz_playerUID in DZE_PlotManagementAdmins)}) then {
{
if (_x getVariable["ownerPUID","0"] == dayz_playerUID or (_x getVariable["CharacterID","0"] == dayz_characterID)) exitWith {
if (_x getVariable["ownerPUID","0"] == dayz_playerUID || (_x getVariable["CharacterID","0"] == dayz_characterID) || ((((_x getVariable ["plotfriends",[]]) select 0) select 0) == dayz_playerUID)) exitWith {
_hasPole = true;
};
} count (entities "Plastic_Pole_EP1_DZ");