mirror of
https://github.com/EpochModTeam/DayZ-Epoch.git
synced 2026-02-10 10:12:54 +03:00
Fix door/plot management friends not writing to DB
This commit is contained in:
@@ -533,15 +533,12 @@ if (_canBuild select 0) then {
|
||||
PVDZ_obj_Publish = [_combination,_tmpbuilt,[_dir,_location,_playerUID, _vector], []];
|
||||
if (_lockable == 3) then {
|
||||
_tmpbuilt setVariable ["doorfriends", [[([player] call FNC_GetPlayerUID),(name player)]], true];
|
||||
PVDZ_veh_Save = [_tmpbuilt,"gear"];
|
||||
PVDZ_obj_Publish = [_combination,_tmpbuilt,[_dir,_location,_playerUID, _vector], [[([player] call FNC_GetPlayerUID),(name player)]]];
|
||||
};
|
||||
} else {
|
||||
PVDZ_obj_Publish = [_combination,_tmpbuilt,[_dir,_location, _vector],[]];
|
||||
};
|
||||
publicVariableServer "PVDZ_obj_Publish";
|
||||
if (!isNil "PVDZ_veh_Save") then {
|
||||
publicVariableServer "PVDZ_veh_Save";
|
||||
};
|
||||
|
||||
format[localize "str_epoch_player_140",_combinationDisplay,_text] call dayz_rollingMessages; //display new combination
|
||||
systemChat format[localize "str_epoch_player_140",_combinationDisplay,_text];
|
||||
@@ -554,18 +551,17 @@ if (_canBuild select 0) then {
|
||||
} else {
|
||||
if (DZE_permanentPlot) then {
|
||||
_tmpbuilt setVariable ["ownerPUID",_playerUID,true];
|
||||
PVDZ_obj_Publish = [dayz_characterID,_tmpbuilt,[_dir,_location,_playerUID, _vector], []];
|
||||
if (_canBuild select 1) then {
|
||||
_tmpbuilt setVariable ["plotfriends", [[([player] call FNC_GetPlayerUID),(name player)]], true];
|
||||
PVDZ_veh_Save = [_tmpbuilt,"gear"];
|
||||
_friendsArr = [[([player] call FNC_GetPlayerUID),(name player)]];
|
||||
_tmpbuilt setVariable ["plotfriends", _friendsArr, true];
|
||||
PVDZ_obj_Publish = [dayz_characterID,_tmpbuilt,[_dir,_location,_playerUID, _vector], _friendsArr];
|
||||
} else {
|
||||
PVDZ_obj_Publish = [dayz_characterID,_tmpbuilt,[_dir,_location,_playerUID, _vector], []];
|
||||
};
|
||||
} else {
|
||||
PVDZ_obj_Publish = [dayz_characterID,_tmpbuilt,[_dir,_location, _vector],[]];
|
||||
};
|
||||
publicVariableServer "PVDZ_obj_Publish";
|
||||
if (!isNil "PVDZ_veh_Save") then {
|
||||
publicVariableServer "PVDZ_veh_Save";
|
||||
};
|
||||
};
|
||||
};
|
||||
} else { //if magazine was not removed, cancel publish
|
||||
|
||||
@@ -441,15 +441,12 @@ if (_canBuild select 0) then {
|
||||
PVDZ_obj_Publish = [_combination,_tmpbuilt,[_dir,_location,_playerUID],_classname];
|
||||
if (_lockable == 3) then {
|
||||
_tmpbuilt setVariable ["doorfriends", [[([player] call FNC_GetPlayerUID),(name player)]], true];
|
||||
PVDZ_veh_Save = [_tmpbuilt,"gear"];
|
||||
PVDZ_obj_Publish = [_combination,_tmpbuilt,[_dir,_location,_playerUID, _vector], [[([player] call FNC_GetPlayerUID),(name player)]]];
|
||||
};
|
||||
} else {
|
||||
PVDZ_obj_Publish = [_combination,_tmpbuilt,[_dir,_location],[]];
|
||||
};
|
||||
publicVariableServer "PVDZ_obj_Publish";
|
||||
if (!isNil "PVDZ_veh_Save") then {
|
||||
publicVariableServer "PVDZ_veh_Save";
|
||||
};
|
||||
|
||||
format[localize "str_epoch_player_140",_combinationDisplay,_text] call dayz_rollingMessages;
|
||||
systemChat format[localize "str_epoch_player_140",_combinationDisplay,_text];
|
||||
@@ -462,18 +459,17 @@ if (_canBuild select 0) then {
|
||||
} else {
|
||||
if (DZE_permanentPlot) then {
|
||||
_tmpbuilt setVariable ["ownerPUID",_playerUID,true];
|
||||
PVDZ_obj_Publish = [dayz_characterID,_tmpbuilt,[_dir,_location,_playerUID],_classname];
|
||||
if (_canBuild select 1) then {
|
||||
_tmpbuilt setVariable ["plotfriends", [[([player] call FNC_GetPlayerUID),(name player)]], true];
|
||||
PVDZ_veh_Save = [_tmpbuilt,"gear"];
|
||||
_friendsArr = [[([player] call FNC_GetPlayerUID),(name player)]];
|
||||
_tmpbuilt setVariable ["plotfriends", _friendsArr, true];
|
||||
PVDZ_obj_Publish = [dayz_characterID,_tmpbuilt,[_dir,_location,_playerUID],_friendsArr];
|
||||
} else {
|
||||
PVDZ_obj_Publish = [dayz_characterID,_tmpbuilt,[_dir,_location,_playerUID],_classname];
|
||||
};
|
||||
} else {
|
||||
PVDZ_obj_Publish = [dayz_characterID,_tmpbuilt,[_dir,_location],[]];
|
||||
};
|
||||
publicVariableServer "PVDZ_obj_Publish";
|
||||
if (!isNil "PVDZ_veh_Save") then {
|
||||
publicVariableServer "PVDZ_veh_Save";
|
||||
};
|
||||
};
|
||||
};
|
||||
} else {
|
||||
|
||||
@@ -128,18 +128,17 @@ if ((count _upgrade) > 0) then {
|
||||
_ownerID = _obj getVariable["ownerPUID","0"];
|
||||
if (_ownerID == "0") then { _ownerID = [player] call FNC_GetPlayerUID; }; //APFL is on but UID is 0 so we will claim it to record the ownership.
|
||||
_object setVariable ["ownerPUID",_ownerID,true];
|
||||
PVDZE_obj_Swap = [_objectCharacterID,_object,[_dir,_location,_ownerID,_vector],_classname,_obj,player];
|
||||
if (_lockable == 3) then {
|
||||
_object setVariable ["doorfriends", [[([player] call FNC_GetPlayerUID),(name player)]], true];
|
||||
PVDZ_veh_Save = [_object,"gear"];
|
||||
_friendsArr = [[([player] call FNC_GetPlayerUID),(name player)]];
|
||||
_object setVariable ["doorfriends", _friendsArr, true];
|
||||
PVDZE_obj_Swap = [_objectCharacterID,_object,[_dir,_location,_ownerID,_vector],_classname,_obj,player,_friendsArr];
|
||||
} else {
|
||||
PVDZE_obj_Swap = [_objectCharacterID,_object,[_dir,_location,_ownerID,_vector],_classname,_obj,player];
|
||||
};
|
||||
} else {
|
||||
PVDZE_obj_Swap = [_objectCharacterID,_object,[_dir,_location,_vector],_classname,_obj,player];
|
||||
};
|
||||
publicVariableServer "PVDZE_obj_Swap";
|
||||
if (!isNil "PVDZ_veh_Save") then {
|
||||
publicVariableServer "PVDZ_veh_Save";
|
||||
};
|
||||
|
||||
player reveal _object;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user