Addon: start_in_vehicle - Nomas-X/AET_AUX GitHub Wiki
This addon handles starting players in a vehicle through the editor while handling join in progress, the addon's feature can also be used at any point through out the mission. We will go over its functionality, and how it is utilized.
When a module is activated all units that meet the Apply (units)
setting in the module will be moved to the designated vehicle set in the Move Into (vehicle)
, if the vehicle is full, destroyed, or does not exist then the unit will be moved to the alternate position set in the Move To (backup LZ)
setting . Additionally you can call the function manually if the need arises.
In the picture below you can see the list of settings the module provides:
Below are the details of the settings the module provides:
-
Apply to (units): Controls the units that will be affected by the module.
- Synchronized objects only: Only the synchronized units will be affected by the module.
- Groups of synchronized objects: Any unit in the group of the synchronized unit will be affected by the module.
- Objects in synchronized triggers: Any unit in the trigger synchronized to the module will be affected.
-
Move Into (vehicle): The vehicle that the units will be moved into. Expected data type is a variable name of the vehicle.
-
Move To (backup LZ): The optional backup LZ that the units will be moved to if the vehicle is full or no longer available. Expected data type is a variable name of the LZ marker, an ASL position array, or empty.
-
Use cargo seats (vehicle): Should units be moved into cargo seats?
-
Use commander seat (vehicle): Should units be moved into the commander seat?
-
Use gunner seats (vehicle): Should units be moved into gunner seats?
-
Use driver seat (vehicle): Should units be moved into the driver seat?
-
Lock AI seats (vehicle): Should the vehicle seats with AI in them be locked?
-
Allow damage (vehicle): Should the vehicle be allowed to take damage?
-
Terminate condition (module): Once the condition is met, the module will be deleted automatically. The output of the statement must be a Boolean.
- Find the
Start In Vehicle
module under theAET Modules
section. - Open the module's attributes and set up its settings.
- Synchronize the module to the units or a trigger based on the module's settings.
Run the following function locally on the machine of the unit that should be affected:
/*
/*
Arguments:
0. <String> Type of event to publish.
1. <Any> Parameters to pass to the event handlers.
1.0. <Object> Unit to be added to the queue.
1.1. <Array>
1.1.0. <Object> Vehicle that the unit will be moved into.
1.1.1. <Array> or <Boolean> Position of the location the player will be teleported to incase it was not possible to move him into the vehicle or if the value is boolean then the player will not be teleported anywhere in that case.
1.1.2. <Boolean> Use cargo seats.
1.1.3. <Boolean> Use commander seat.
1.1.4. <Boolean> Use gunner seats.
1.1.5. <Boolean> Use driver seat.
*/
[
"AET_start_in_vehicle_EH_request",
[
player,
[
AET_HELI_1,
[0,0,0],
true,
true,
true,
false
]
]
] call CBA_fnc_serverEvent;