getVehicleCargo: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
m (Text replacement - "\{\{GameCategory\|(arma[0123])\|[ _]?New[ _]Scripting[ _]Commands[ _]List\}\}" to "{{GameCategory|$1|New Scripting Commands}}")
m (Text replacement - "_{10,} " to "")
Line 1: Line 1:
{{Command|Comments=
{{Command|Comments=
____________________________________________________________________________________________


| arma3 |Game name=
| arma3 |Game name=
Line 10: Line 9:


|gr1= Vehicle in Vehicle Transport |GROUP1=
|gr1= Vehicle in Vehicle Transport |GROUP1=
____________________________________________________________________________________________


| Get a list of vehicles loaded as cargo inside this vehicle. The returned array is in the order the cargo vehicles were added to containing vehicle. |DESCRIPTION=
| Get a list of vehicles loaded as cargo inside this vehicle. The returned array is in the order the cargo vehicles were added to containing vehicle. |DESCRIPTION=
____________________________________________________________________________________________


| [[getVehicleCargo]] storingVehicle |SYNTAX=
| [[getVehicleCargo]] storingVehicle |SYNTAX=
Line 20: Line 17:


| [[Array]] - vehicles loaded in storingVehicle, in order of their loading |RETURNVALUE=
| [[Array]] - vehicles loaded in storingVehicle, in order of their loading |RETURNVALUE=
____________________________________________________________________________________________


|x1= <code>_vehicleCargo = [[getVehicleCargo]] blackfish; {{codecomment|// returns [] if empty}}</code> |EXAMPLE1=
|x1= <code>_vehicleCargo = [[getVehicleCargo]] blackfish; {{codecomment|// returns [] if empty}}</code> |EXAMPLE1=
____________________________________________________________________________________________


|x2= <code>_vehicleCargo = [[getVehicleCargo]] blackfish; {{codecomment|// returns [quad_3, quad_1, quad_2] as they were loaded in this order}}</code> |EXAMPLE2=
|x2= <code>_vehicleCargo = [[getVehicleCargo]] blackfish; {{codecomment|// returns [quad_3, quad_1, quad_2] as they were loaded in this order}}</code> |EXAMPLE2=
____________________________________________________________________________________________


| [[Arma_3_Vehicle_in_Vehicle_Transport|Vehicle in Vehicle Transport]] [[canVehicleCargo]] [[setVehicleCargo]] [[enableVehicleCargo]] [[isVehicleCargo]] [[vehicleCargoEnabled]] |SEEALSO=
| [[Arma_3_Vehicle_in_Vehicle_Transport|Vehicle in Vehicle Transport]] [[canVehicleCargo]] [[setVehicleCargo]] [[enableVehicleCargo]] [[isVehicleCargo]] [[vehicleCargoEnabled]] |SEEALSO=

Revision as of 02:41, 17 January 2021

Hover & click on the images for description

Description

Description:
Get a list of vehicles loaded as cargo inside this vehicle. The returned array is in the order the cargo vehicles were added to containing vehicle.
Groups:
Vehicle in Vehicle Transport

Syntax

Syntax:
getVehicleCargo storingVehicle
Parameters:
storingVehicle: Object
Return Value:
Array - vehicles loaded in storingVehicle, in order of their loading

Examples

Example 1:
_vehicleCargo = getVehicleCargo blackfish; // returns [] if empty
Example 2:
_vehicleCargo = getVehicleCargo blackfish; // returns [quad_3, quad_1, quad_2] as they were loaded in this order

Additional Information

See also:
Vehicle in Vehicle Transport canVehicleCargo setVehicleCargo enableVehicleCargo isVehicleCargo vehicleCargoEnabled

Notes

Report bugs on the Feedback Tracker and/or discuss them on the Arma Discord or on the Forums.
Only post proven facts here! Add Note

Bottom Section