From 32dd59afc0c8104afef1ffd564632cd82a8727a6 Mon Sep 17 00:00:00 2001 From: shukari Date: Thu, 21 Oct 2021 13:55:23 +0200 Subject: [PATCH] Anpassungen aus #635 (#651) * fixed #635 * TFAR Stuff --- addons/main/functions/fnc_miscStuff.sqf | 13 ++++++++++++- .../functions/fnc_insertChildrenDeleteBox.sqf | 11 +++++++---- 2 files changed, 19 insertions(+), 5 deletions(-) diff --git a/addons/main/functions/fnc_miscStuff.sqf b/addons/main/functions/fnc_miscStuff.sqf index 4b329e57e..37bcacb9c 100644 --- a/addons/main/functions/fnc_miscStuff.sqf +++ b/addons/main/functions/fnc_miscStuff.sqf @@ -275,7 +275,7 @@ GVAR(vehicleTransport) = ["Car", "Tank", "Motorcycle", "Helicopter", "Plane", "S private _actions = []; { - if (alive _x) then + if (alive _x && isNull (isVehicleCargo _x)) then { private _action = [ format ["vehicle_%1", random 999999], @@ -372,3 +372,14 @@ GVAR(vehicleTransport) = ["Car", "Tank", "Motorcycle", "Helicopter", "Plane", "S }; }; }] call ace_common_fnc_arithmeticSetSource; + + +// Enforce latest TFAR plugin version +["TFAR_ConfigRefresh", { + // TFAR just updated its plugin config, shove in a new min version after the fact. + // Next frame because there is a TFAR bug where it can process plugin messages in reverse order. + // Meaning the version that the TFAR script sent first, could arrive after our message and overwrite ours. + [{ + ["minimumPluginVersion", 328] call TFAR_fnc_setPluginSetting; + }] call CBA_fnc_execNextFrame; +}] call CBA_fnc_addEventHandler; diff --git a/addons/nachschub/functions/fnc_insertChildrenDeleteBox.sqf b/addons/nachschub/functions/fnc_insertChildrenDeleteBox.sqf index 3d7a71d5c..ff70b0c0b 100644 --- a/addons/nachschub/functions/fnc_insertChildrenDeleteBox.sqf +++ b/addons/nachschub/functions/fnc_insertChildrenDeleteBox.sqf @@ -5,13 +5,16 @@ */ params ["_target", "_player", "_params"]; -private _items = (_target nearEntities [["ReammoBox_F", "ACE_Wheel", "ACE_Track", "TB_Land_PlasticCase_01_small_F", "TB_Land_PlasticCase_01_medium_F"], 7]) select {!(_x isKindOf "TB_supply_base" || _x isKindOf "TB_arsenal_base")}; +private _items = (_target nearEntities [["ReammoBox_F", "ACE_Wheel", "ACE_Track", "TB_Land_PlasticCase_01_small_F", "TB_Land_PlasticCase_01_medium_F", QGVAR(CanisterFuel)], 7]) select {!(_x isKindOf "TB_supply_base" || _x isKindOf "TB_arsenal_base")}; -// Add children to this action private _actions = []; { - private _action = [str _x, format ["%1 (%2m)", [_x] call EFUNC(main,displayName), round (_target distance2D _x)], "", {deleteVehicle (_this select 2)}, {true}, {}, _x] call ace_interact_menu_fnc_createAction; - _actions pushBack [_action, [], _target]; + // Vehicle in Vehicle Transport verhindern + if (isNull (isVehicleCargo _x)) then + { + private _action = [str _x, format ["%1 (%2m)", [_x] call EFUNC(main,displayName), round (_target distance2D _x)], "", {deleteVehicle (_this select 2)}, {true}, {}, _x] call ace_interact_menu_fnc_createAction; + _actions pushBack [_action, [], _target]; + }; } forEach _items;