From ee1885b3a015dda47d2929af9c65c6c0d9196326 Mon Sep 17 00:00:00 2001 From: James Jones Date: Tue, 15 Jan 2019 18:42:40 +1030 Subject: [PATCH] Allow statics to save in elevated buildings Use getPosATL instead of getPos when fetching position of static. This means if static is in an elevated position (such as roof of a building) it'll be correctly saved and reappear in the elevated position upon persistent load. --- A3-Antistasi/statSave/saveLoop.sqf | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/A3-Antistasi/statSave/saveLoop.sqf b/A3-Antistasi/statSave/saveLoop.sqf index 497585bf67..453787df0e 100644 --- a/A3-Antistasi/statSave/saveLoop.sqf +++ b/A3-Antistasi/statSave/saveLoop.sqf @@ -154,7 +154,7 @@ _sitios = marcadores select {lados getVariable [_x,sideUnknown] == buenos}; _posicion = position _x; if ((alive _x) and !(surfaceIsWater _posicion) and !(isNull _x)) then { - _arrayEst pushBack [typeOf _x,getPos _x,getDir _x]; + _arrayEst pushBack [typeOf _x,getPosATL _x,getDir _x]; /* _cercano = [_sitios,_posicion] call BIS_fnc_nearestPosition; if (_posicion inArea _cercano) then @@ -277,4 +277,4 @@ _controles = controles select {(lados getVariable [_x,sideUnknown] == buenos) an savingServer = false; [[petros,"hint",format ["Savegame Done.\n\nYou won't lose your stats in the event of a game update.\n\nRemember: if you want to preserve any vehicle, it must be near the HQ Flag with no AI inside.\nIf AI are inside, you will save the funds you spent on it.\n\nAI will be refunded\n\nStolen and purchased Static Weapons need to be ASSEMBLED in order to be saved. You can save disassembled Static Weapons in the ammo box.\n\nMounted Statics (Mortar/AA/AT squads) won't get saved, but you will be able to recover the cost.\n\nSame for assigned vehicles more than 50m away from HQ.\n\n%1 fund count:\nHR: %2\nMoney: %3 €",nameBuenos,_hrFondo,_resFondo]],"A3A_fnc_commsMP"] call BIS_fnc_MP; -diag_log "Antistasi: Persistent Save Done"; \ No newline at end of file +diag_log "Antistasi: Persistent Save Done";