Commit b2eaf7ef authored by Superxpdude's avatar Superxpdude

Added an "impound vehicle" function for BLUFOR to clean up vehicles.

Removed the "repair/flip" action from vehicles (no longer needed with impound).
Added a supply box and trash box to Feruz Abad (to be added to all checkpoints. Supply box still needs cargo definition).
parent 49492789
...@@ -10,6 +10,7 @@ class J23 // Function TAG, used for the first part of the function name ...@@ -10,6 +10,7 @@ class J23 // Function TAG, used for the first part of the function name
{ {
class Justyn23 // Function category, defines the folder that the file is located in class Justyn23 // Function category, defines the folder that the file is located in
{ {
class boxSetup {}; // Handles setting up supply and trash boxes
class civKilledServer {}; // Handle civilian deaths and synchronize the effects on all machines class civKilledServer {}; // Handle civilian deaths and synchronize the effects on all machines
class getItemName {}; // Retrieves the name of a transported item class getItemName {}; // Retrieves the name of a transported item
class itemDeliveredServer {}; // Handle item deliveries on the server class itemDeliveredServer {}; // Handle item deliveries on the server
......
// J23_fnc_boxSetup
// Author: Superxpdude
// Sets up ammo/supply boxes
params [
["_box",objNull,[objNull]],
["_type","",[""]]
];
_box allowDamage false;
if (isServer) then {
clearItemCargoGlobal _box;
clearMagazineCargoGlobal _box;
clearWeaponCargoGlobal _box;
clearBackpackCargoGlobal _box;
};
switch (toLower _type) do {
case "supply": {
[_box,"nato_supply"] call XPT_fnc_loadItemCargo;
[
_box,
"Take Body Bag",
"\a3\ui_f\data\IGUI\Cfg\holdactions\holdAction_connect_ca.paa",
"\a3\ui_f\data\IGUI\Cfg\holdactions\holdAction_connect_ca.paa",
"(_this distance _target < 3) AND (side (group _this) == west)",
"(_caller distance _target < 3) AND (side (group _this) == west)",
{},
{},
{
_caller addItem "ACE_bodyBag";
},
{},
[],
2,
-10,
false,
false
] call BIS_fnc_holdActionAdd;
};
case "trash": {
[
_box,
"Empty Trash",
"\a3\ui_f\data\IGUI\Cfg\holdactions\holdAction_connect_ca.paa",
"\a3\ui_f\data\IGUI\Cfg\holdactions\holdAction_connect_ca.paa",
"(_this distance _target < 3)",
"(_caller distance _target < 3)",
{},
{},
{
clearItemCargoGlobal _target;
clearMagazineCargoGlobal _target;
clearWeaponCargoGlobal _target;
clearBackpackCargoGlobal _target;
},
{},
[],
3,
-10,
false,
false
] call BIS_fnc_holdActionAdd;
};
};
\ No newline at end of file
...@@ -82,6 +82,28 @@ switch (_startingloc) do { ...@@ -82,6 +82,28 @@ switch (_startingloc) do {
] call BIS_fnc_holdActionAdd; ] call BIS_fnc_holdActionAdd;
} forEach (allMissionObjects "Land_BarGate_F"); } forEach (allMissionObjects "Land_BarGate_F");
if (side (group player) == west) then {
{
[
_x,
"Impound Vehicle",
"\a3\ui_f\data\IGUI\Cfg\holdactions\holdAction_connect_ca.paa",
"\a3\ui_f\data\IGUI\Cfg\holdactions\holdAction_connect_ca.paa",
"(_this distance _target < 5) AND (_target isKindOf 'Car_F')",
"(_caller distance _target < 5) AND (_target isKindOf 'Car_F')",
{},
{},
{deleteVehicle _target;},
{},
[],
10,
-10,
false,
false
] call BIS_fnc_holdActionAdd;
} forEach (allMissionObjects "Car_F");
};
// ACE_Killed event handler for killed civilian tracking // ACE_Killed event handler for killed civilian tracking
["ace_killed", { ["ace_killed", {
params ["_unit", "_causeOfDeath", "_killer", "_instigator"]; params ["_unit", "_causeOfDeath", "_killer", "_instigator"];
......
This diff is collapsed.
...@@ -25,10 +25,25 @@ _randomcar = ["C_Offroad_01_F", "C_Van_01_transport_F", "CUP_C_Ural_Civ_03", "C ...@@ -25,10 +25,25 @@ _randomcar = ["C_Offroad_01_F", "C_Van_01_transport_F", "CUP_C_Ural_Civ_03", "C
_spawnloc = getpos carspawn3_1; _spawnloc = getpos carspawn3_1;
}; };
private _veh = _randomcar createVehicle _spawnloc;
_randomcar createVehicle _spawnloc;
[
_veh,
"Impound Vehicle",
"\a3\ui_f\data\IGUI\Cfg\holdactions\holdAction_connect_ca.paa",
"\a3\ui_f\data\IGUI\Cfg\holdactions\holdAction_connect_ca.paa",
"(_this distance _target < 5) AND (_target isKindOf 'Car_F')",
"(_caller distance _target < 5) AND (_target isKindOf 'Car_F')",
{},
{},
{deleteVehicle _target;},
{},
[],
10,
-10,
false,
false
] remoteExec ["BIS_fnc_holdActionAdd", west];
sleep 10; //cooldown sleep 10; //cooldown
Cooldown = 0; Cooldown = 0;
......
...@@ -25,10 +25,25 @@ _randomcar = ["C_SUV_01_F", "CUP_C_S1203_CIV", "CUP_C_SUV_CIV", "CUP_C_LR_Trans ...@@ -25,10 +25,25 @@ _randomcar = ["C_SUV_01_F", "CUP_C_S1203_CIV", "CUP_C_SUV_CIV", "CUP_C_LR_Trans
_spawnloc = getpos carspawn2_1; _spawnloc = getpos carspawn2_1;
}; };
private _veh = _randomcar createVehicle _spawnloc;
_randomcar createVehicle _spawnloc;
_ [
_veh,
"Impound Vehicle",
"\a3\ui_f\data\IGUI\Cfg\holdactions\holdAction_connect_ca.paa",
"\a3\ui_f\data\IGUI\Cfg\holdactions\holdAction_connect_ca.paa",
"(_this distance _target < 5) AND (_target isKindOf 'Car_F')",
"(_caller distance _target < 5) AND (_target isKindOf 'Car_F')",
{},
{},
{deleteVehicle _target;},
{},
[],
10,
-10,
false,
false
] remoteExec ["BIS_fnc_holdActionAdd", west];
sleep 10; //cooldown sleep 10; //cooldown
Cooldown = 0; Cooldown = 0;
......
...@@ -24,11 +24,25 @@ _randomcar = ["CUP_C_Golf4_random_Civ", "CUP_C_Volha_Blue_TKCIV", "CUP_C_Lada_R ...@@ -24,11 +24,25 @@ _randomcar = ["CUP_C_Golf4_random_Civ", "CUP_C_Volha_Blue_TKCIV", "CUP_C_Lada_R
_spawnloc = getpos carspawn_1; _spawnloc = getpos carspawn_1;
}; };
private _veh = _randomcar createVehicle _spawnloc;
_randomcar createVehicle _spawnloc;
[
_veh,
"Impound Vehicle",
"\a3\ui_f\data\IGUI\Cfg\holdactions\holdAction_connect_ca.paa",
"\a3\ui_f\data\IGUI\Cfg\holdactions\holdAction_connect_ca.paa",
"(_this distance _target < 5) AND (_target isKindOf 'Car_F')",
"(_caller distance _target < 5) AND (_target isKindOf 'Car_F')",
{},
{},
{deleteVehicle _target;},
{},
[],
10,
-10,
false,
false
] remoteExec ["BIS_fnc_holdActionAdd", west];
sleep 10; //cooldown sleep 10; //cooldown
Cooldown = 0; Cooldown = 0;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment