BIS fnc relPos: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
(see also)
No edit summary
Line 51: Line 51:
[[Category:{{Name|tkoh}}: Functions|{{uc:relPos}}]]
[[Category:{{Name|tkoh}}: Functions|{{uc:relPos}}]]
[[Category:{{Name|arma3}}: Functions|{{uc:relPos}}]]
[[Category:{{Name|arma3}}: Functions|{{uc:relPos}}]]
<!-- CONTINUE Notes -->
<dl class="command_description">
<dd class="notedate">Posted on January 7, 2016 - 19:26 (UTC)</dd>
<dt class="note">[[User:Lawman Actual|Lawman Actual]]</dt>
<dd class="note">
The function appears to work in two dimensions, and as such can be used to find the position of a target relative to the player if bearing and distance are known.
However, if there is a significant change in elevation between yourself and the target, the distance registered on a ragefinder (which is measuring a 3 dimensional straight line) will always be larger than the two-dimensional value required for BIS_fnc_relPos (see diagram below) and as such air-strikes and ordnance called in using such a function can miss by several hundred metres in extreme cases.
Currently searching for a method which incorporates the azimuth of the rangefinder in calculation.
</dd>
</dl>
<!-- DISCONTINUE Notes -->

Revision as of 20:26, 7 January 2016


Hover & click on the images for description

Description

Description:
/************************************************************
	Relative Position

Parameters: [object or position, distance, direction]

Returns a position that is a specified distance and compass
direction from the passed position or object.

Example: [player, 5, 100] call BIS_fnc_relPos
************************************************************/

(Placeholder description extracted from the function header by BIS_fnc_exportFunctionsToWiki)
Execution:
call
Groups:
Uncategorised

Syntax

Syntax:
Syntax needed
Return Value:
Return value needed

Examples

Example 1:

Additional Information

See also:
getPos

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

Bottom Section

Posted on January 7, 2016 - 19:26 (UTC)
Lawman Actual
The function appears to work in two dimensions, and as such can be used to find the position of a target relative to the player if bearing and distance are known. However, if there is a significant change in elevation between yourself and the target, the distance registered on a ragefinder (which is measuring a 3 dimensional straight line) will always be larger than the two-dimensional value required for BIS_fnc_relPos (see diagram below) and as such air-strikes and ordnance called in using such a function can miss by several hundred metres in extreme cases. Currently searching for a method which incorporates the azimuth of the rangefinder in calculation.