allMissionObjects: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
m (Text replacement - " <h3 style='display:none'>Bottom Section</h3>" to "")
m (Text replacement - " {3,}\|" to " |")
Line 17: Line 17:
* <tt>"#soundonvehicle"</tt> - sound created with [[say3D]] for example
* <tt>"#soundonvehicle"</tt> - sound created with [[say3D]] for example
* <tt>"#dynamicsound"</tt> - sound source created using [[createSoundSource]]
* <tt>"#dynamicsound"</tt> - sound source created using [[createSoundSource]]


| '''allMissionObjects''' type
| '''allMissionObjects''' type
Line 24: Line 23:


| [[Array]] of [[Object|Objects]]
| [[Array]] of [[Object|Objects]]


|x1= <code>_airObjects = [[allMissionObjects]] "Air";</code>
|x1= <code>_airObjects = [[allMissionObjects]] "Air";</code>
Line 31: Line 29:


|x3= <code>_allMObjects =[[ allMissionObjects]] "All";</code>
|x3= <code>_allMObjects =[[ allMissionObjects]] "All";</code>


|  [[allDead]], [[allGroups]], [[allUnits]], [[entities]], [[vehicles]], [[allMines]], [[allSimpleObjects]]
|  [[allDead]], [[allGroups]], [[allUnits]], [[entities]], [[vehicles]], [[allMines]], [[allSimpleObjects]]

Revision as of 18:07, 18 January 2021

Hover & click on the images for description

Description

Description:
Returns all mission objects (created by or during a mission) with given type (or its subtype). In some cases allMissionObjects could be substituted with entities, which would be much much faster alternative. Some of the unusual mission objects that can be detected with this command (as well as with nearestObject):
  • "#slop" - blood drop
  • "#mark" - unit footprints
  • "#track" - vehicle tracks
  • "#crater" - explosion crater on the ground
  • "#crateronvehicle" - bullet marks on vehicle
  • "#explosion" - an explosion
  • "#objectdestructed" - building, tree or bush destruction
  • "#soundonvehicle" - sound created with say3D for example
  • "#dynamicsound" - sound source created using createSoundSource
Groups:
Object Detection

Syntax

Syntax:
allMissionObjects type
Parameters:
type: String
Return Value:
Array of Objects

Examples

Example 1:
_airObjects = allMissionObjects "Air";
Example 2:
{ deleteVehicle _x } forEach (allMissionObjects "");
Example 3:
_allMObjects =allMissionObjects "All";

Additional Information

See also:
allDeadallGroupsallUnitsentitiesvehiclesallMinesallSimpleObjects

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
Posted on June 22, 2012
Rocket
Be VERY careful with the use of this command. It is very demanding as it must iterate through all mission created objects. Particular care should be taken exercising this often on dedicated servers.
Posted on Decembere 15, 2013
Killzone_Kid
For some reason in Arma 3 this command is up to 5 times faster on the dedicated server than on a connected client. In my experiments it took on average 5 ms for the command to complete on a client while under 1 ms on the server.