getRoadInfo: Difference between revisions
Jump to navigation
Jump to search
Lou Montana (talk | contribs) m (Text replacement - "\| *arma3 * * *\| *([0-2]\.[0-9]{2}) * " to "|game1= arma3 |version1= $1 ") |
Lou Montana (talk | contribs) m (Text replacement - " \| *(game[0-9]|version[0-9]|gr[0-9]|serverExec|mp|pr|descr|s[0-9]|p[0-9]{1,3}|r[0-9]|x1?[0-9]|seealso) *= +" to " |$1= ") |
||
Line 10: | Line 10: | ||
{{Feature | Informative | Pedestrian roads `mapType` is usually <tt>"TRAIL"</tt>. They are part of Road Net but excluded from path finding. Use [[roadsConnectedTo]] with alternative flag to find the connections between pedestrian roads.}} | {{Feature | Informative | Pedestrian roads `mapType` is usually <tt>"TRAIL"</tt>. They are part of Road Net but excluded from path finding. Use [[roadsConnectedTo]] with alternative flag to find the connections between pedestrian roads.}} | ||
|s1= | |s1= [[getRoadInfo]] road | ||
|p1= road: [[Object]] | |p1= road: [[Object]] |
Revision as of 22:11, 19 June 2021
Description
- Description:
- Returns road info in format [mapType, width, isPedestrian, texture, textureEnd, material, begPos, endPos, isBridge]
- Groups:
- Roads and Airports
Syntax
- Syntax:
- getRoadInfo road
- Parameters:
- road: Object
- Return Value:
- Array in format [mapType, width, isPedestrian, texture, textureEnd, material, begPos, endPos, isBridge], where:
- mapType: String - road segment type, could be "ROAD", "MAIN ROAD", "TRACK", "TRAIL" (see nearestTerrainObjects)
- width: Number - road segment width
- isPedestrian: Boolean - when true road is for pedestrian use only
- texture: String - road segment surface texture
- textureEnd: String - road segment surface texture
- material: String - road segment surface material
- begPos: PositionASL - start of the road segment
- endPos: PositionASL - finish of the road segment
- isBridge: Boolean - when true road segment is a bridge
Examples
- Example 1:
getRoadInfo _road
- Example 2:
- Get direction of the road segment:
private _info = getRoadInfo _road; private _dir = (_info select 6) getDir (_info select 7);
Additional Information
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