getMissionLayerEntities: Difference between revisions
Jump to navigation
Jump to search
(added 2nd example) |
m (template:command argument fix) |
||
Line 14: | Line 14: | ||
| '''getMissionLayerEntities''' layerName |= Syntax | | '''getMissionLayerEntities''' layerName |= Syntax | ||
|p1= layerName: [[String]] - layer name in the editor. If multiple layers with the same name are present in the scenario, the first found one is used. |= | |p1= layerName: [[String]] - layer name in the editor. If multiple layers with the same name are present in the scenario, the first found one is used. |PARAMETER1= | ||
| [[Array]] in format <code>[objects:Array, markers:Array]</code> |= | | [[Array]] in format <code>[objects:Array, markers:Array]</code> |RETURNVALUE= | ||
|x1= <code>_base = [[getMissionLayerEntities]] "Base";</code> | |x1= <code>_base = [[getMissionLayerEntities]] "Base";</code> | ||
|= | |EXAMPLE1= | ||
Line 25: | Line 25: | ||
[[deleteVehicle]] [[_x]]; | [[deleteVehicle]] [[_x]]; | ||
} [[forEach]] (('''getMissionLayerEntities''' "Simple Objects") [[select]] 0);//Deletes all objects within that layer after the player is over 800m away from _someObject</code> | } [[forEach]] (('''getMissionLayerEntities''' "Simple Objects") [[select]] 0);//Deletes all objects within that layer after the player is over 800m away from _someObject</code> | ||
|= | |EXAMPLE2= | ||
____________________________________________________________________________________________ | ____________________________________________________________________________________________ | ||
| [[get3DENLayerEntities]] |= | | [[get3DENLayerEntities]] |SEEALSO= | ||
| |= | | |MPBEHAVIOUR= | ||
____________________________________________________________________________________________ | ____________________________________________________________________________________________ | ||
}} | }} |
Revision as of 10:31, 7 April 2019
Description
- Description:
- Returns all entities within specific Eden Editor layer. To be used when the scenario is running, not in the editor workspace. Useful for disabling / enabling whole parts of the scenario which you add to specific layer while editing.
- Groups:
- Uncategorised
Syntax
- Syntax:
- getMissionLayerEntities layerName
- Parameters:
- layerName: String - layer name in the editor. If multiple layers with the same name are present in the scenario, the first found one is used.
- Return Value:
- Array in format
[objects:Array, markers:Array]
Examples
- Example 1:
_base = getMissionLayerEntities "Base";
- Example 2:
waitUntil {(player distance _someObject) > 800}; { deleteVehicle _x; } forEach ((getMissionLayerEntities "Simple Objects") select 0);//Deletes all objects within that layer after the player is over 800m away from _someObject
Additional Information
- See also:
- get3DENLayerEntities
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
Notes