From 2d980b04c69bcf3f3ede7ec66b2cc9b08d5f233a Mon Sep 17 00:00:00 2001 From: ARMAzac Date: Sat, 15 Jul 2017 15:18:56 +1000 Subject: [PATCH] Fix for garrison saves --- .../overthrow_main/functions/AI/orders/fn_orderLoot.sqf | 8 ++++---- addons/overthrow_main/functions/save/fn_loadGame.sqf | 4 ++-- addons/overthrow_main/script_version.hpp | 2 +- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/addons/overthrow_main/functions/AI/orders/fn_orderLoot.sqf b/addons/overthrow_main/functions/AI/orders/fn_orderLoot.sqf index 4874f9dc..ffb2c64b 100644 --- a/addons/overthrow_main/functions/AI/orders/fn_orderLoot.sqf +++ b/addons/overthrow_main/functions/AI/orders/fn_orderLoot.sqf @@ -70,12 +70,12 @@ format["Looting nearby bodies into the %1",(typeof _target) call OT_fnc_vehicleG _unit doMove getpos _deadguy; [_unit,1] call OT_fnc_experience; - waitUntil {sleep 1; (!alive _unit) or (isNull _t) or (_unit distance _deadguy < 10) or (_timeOut < time)}; + waitUntil {sleep 1; (!alive _unit) or (isNull _t) or (_unit distance _deadguy < 12) or (_timeOut < time)}; if((!alive _unit) or (_timeOut < time)) exitWith {}; [_deadguy,_unit] call OT_fnc_takeStuff; sleep 2; - hideBody _deadguy; + deleteVehicle _deadguy; if(primaryWeapon _unit == "") then { _weapon = objNull; { @@ -86,7 +86,7 @@ format["Looting nearby bodies into the %1",(typeof _target) call OT_fnc_vehicleG }foreach(_unit nearentities ["WeaponHolderSimulated",10]); if !(isNull _weapon) then { _unit doMove getpos _weapon; - waitUntil {sleep 1; (!alive _unit) or (_unit distance _weapon < 10) or (_timeOut < time)}; + waitUntil {sleep 1; (!alive _unit) or (_unit distance _weapon < 12) or (_timeOut < time)}; if(alive _unit and (_timeOut > time)) then { _s = (weaponsItems _weapon) select 0; @@ -105,7 +105,7 @@ format["Looting nearby bodies into the %1",(typeof _target) call OT_fnc_vehicleG if(!alive _unit) exitWith {}; _timeout = time + 120; _unit doMove getpos _t; - waitUntil {sleep 1; (!alive _unit) or (isNull _t) or (_unit distance _t < 10) or (_timeOut < time)}; + waitUntil {sleep 1; (!alive _unit) or (isNull _t) or (_unit distance _t < 12) or (_timeOut < time)}; if((!alive _unit) or (_timeOut < time)) exitWith {}; if !([_unit,_t] call OT_fnc_dumpStuff) exitWith { diff --git a/addons/overthrow_main/functions/save/fn_loadGame.sqf b/addons/overthrow_main/functions/save/fn_loadGame.sqf index 46b17512..45e25888 100644 --- a/addons/overthrow_main/functions/save/fn_loadGame.sqf +++ b/addons/overthrow_main/functions/save/fn_loadGame.sqf @@ -254,7 +254,7 @@ sleep 0.2; _garrison = server getVariable [format["resgarrison%1",_code],[]]; if(count _garrison > 0) then { _group = creategroup resistance; - spawner setVariable [format["resgarrison",_code],_group,true]; + spawner setVariable [format["resgarrison%1",_code],_group,true]; { _x params ["_cls","_loadout"]; @@ -275,7 +275,7 @@ sleep 0.2; _garrison = server getVariable [format["resgarrison%1",_code],[]]; if(count _garrison > 0) then { _group = creategroup resistance; - spawner setVariable [format["resgarrison",_code],_group,true]; + spawner setVariable [format["resgarrison%1",_code],_group,true]; { _x params ["_cls","_loadout"]; if(_cls != "HMG" and _cls != "GMG") then { diff --git a/addons/overthrow_main/script_version.hpp b/addons/overthrow_main/script_version.hpp index 348e3546..741b3a4a 100644 --- a/addons/overthrow_main/script_version.hpp +++ b/addons/overthrow_main/script_version.hpp @@ -19,4 +19,4 @@ #define MAJOR 0 #define MINOR 7 #define PATCHLVL 5 -#define BUILD 2 +#define BUILD 3