Skip to content

Commit

Permalink
Anpassungen aus #635 (#651)
Browse files Browse the repository at this point in the history
* fixed #635

* TFAR Stuff
  • Loading branch information
shukari authored Oct 21, 2021
1 parent 9fd902a commit 32dd59a
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 5 deletions.
13 changes: 12 additions & 1 deletion addons/main/functions/fnc_miscStuff.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -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],
Expand Down Expand Up @@ -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;
11 changes: 7 additions & 4 deletions addons/nachschub/functions/fnc_insertChildrenDeleteBox.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -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;

Expand Down

0 comments on commit 32dd59a

Please sign in to comment.