nearestLocation: Difference between revisions
Jump to navigation
Jump to search
Lou Montana (talk | contribs) m (Text replacement - "\| arma1 \|1.([0-9]{2}) \|([^g]|g[^a])" to "| arma1 |1.$1 |game2= arma2 |version2= 1.00 |game3= arma2oa |version3= 1.50 |game4= tkoh |version4= 1.00 |game5= arma3 |version5= 0.50 |$2") |
Lou Montana (talk | contribs) m (Text replacement - " \| *(([^=\| ]+)('''|\[\[)([^=\| ]+)) * +\|p1=" to " |s1= $1 |p1=") |
||
Line 20: | Line 20: | ||
| Return the closest location of specified class to a given position.<br>Checked range is unlimited (i.e. covers the whole map). | | Return the closest location of specified class to a given position.<br>Checked range is unlimited (i.e. covers the whole map). | ||
| [[nearestLocation]] [position, locationClass] | |s1= [[nearestLocation]] [position, locationClass] | ||
|p1= [position, locationClass]: [[Array]] | |p1= [position, locationClass]: [[Array]] |
Revision as of 23:16, 12 June 2021
Description
- Description:
- Description needed
- Groups:
- Locations
Syntax
- Syntax:
- nearestLocation [position, locationClass]
- Parameters:
- [position, locationClass]: Array
- position: Object or Array in format PositionAGL or Position2D
- locationClass: String of a location class name. If "" is supplied, any nearest location is returned. See Location Types
- Return Value:
- Location
Examples
- Example 1:
_nearestCity = nearestLocation [getPos player, "nameCity"];
- Example 2:
_anyNearestLocation = nearestLocation [player, ""];
Additional Information
- See also:
- See also needed
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