For counting the whole bunch of people inside a chopper, use
count crew choppername.
The command
crew returns everybody in the chopper (or in any vehicle) in order of [commander,driver,gunner,cargo] (if I remember correctly..)
For counting cargo there are several ways:
- Make a 'note' of the cargo position amount in an empty chopper in the init.sqs/sqf and save it in a global variable, using the command
emptyPositionssomeglobalvariable = choppername emptyPositions "cargo"
and then later on compare that amount with the current empty cargo seats in the chopper and this way you get the number of cargo seats taken, which you can then use in counting the cargo..
- Use the new command
getNumber. If your chopper is for example a blackhawk you can get the amount of cargo it can transport with
getNumbergetNumber (configFile >> "CfgVehicles" >> "UH60" >> "transportSoldier")
Which you can again compare to the empty seats you get with
emptyPositions like in the above example
- You can also write a script that goes through the array given by the
crew command and saves the amount of cargo in some variable. If the unit in the array is not commander, driver nor gunner, it is cargo..