getHideFrom: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
m (example)
m (template:command argument fix)
Line 7: Line 7:
____________________________________________________________________________________________
____________________________________________________________________________________________


| Returns the [[Position]] where object believes the enemy to be. If there is no direct line of sight between the object and the enemy, this position is extrapolated based on the last known position and speed of the enemy. A returned position of [0,0,0] implies that object does not knowAbout enemy. If enemy is null it is some position in front of the object or enemy position. |= Description
| Returns the [[Position]] where object believes the enemy to be. If there is no direct line of sight between the object and the enemy, this position is extrapolated based on the last known position and speed of the enemy. A returned position of [0,0,0] implies that object does not knowAbout enemy. If enemy is null it is some position in front of the object or enemy position. |DESCRIPTION=
____________________________________________________________________________________________
____________________________________________________________________________________________


| object '''getHideFrom''' enemy |= Syntax
| object '''getHideFrom''' enemy |SYNTAX=


|p1= object: [[Object]] |= Parameter 1
|p1= object: [[Object]] |PARAMETER1=


|p2= enemy: [[Object]] |= Parameter 2
|p2= enemy: [[Object]] |PARAMETER2=


| [[Array]] - [[ASLToATL]] representation of the believed [[aimPos]] of the enemy object |= Return value
| [[Array]] - [[ASLToATL]] representation of the believed [[aimPos]] of the enemy object |RETURNVALUE=


|x1= <code>_pos = [[player]] [[getHideFrom]] _enemy;</code>|Example 1=
|x1= <code>_pos = [[player]] [[getHideFrom]] _enemy;</code>|Example 1=
____________________________________________________________________________________________
____________________________________________________________________________________________


|  [[findCover]], [[setHideBehind]], [[isHidden]], [[knowsAbout]], [[forgetTarget]] |= See also
|  [[findCover]], [[setHideBehind]], [[isHidden]], [[knowsAbout]], [[forgetTarget]] |SEEALSO=


}}
}}

Revision as of 14:40, 7 April 2019

-wrong parameter ("Arma") defined!-1.00
Hover & click on the images for description

Description

Description:
Returns the Position where object believes the enemy to be. If there is no direct line of sight between the object and the enemy, this position is extrapolated based on the last known position and speed of the enemy. A returned position of [0,0,0] implies that object does not knowAbout enemy. If enemy is null it is some position in front of the object or enemy position.
Groups:
Uncategorised

Syntax

Syntax:
object getHideFrom enemy
Parameters:
object: Object
enemy: Object
Return Value:
Array - ASLToATL representation of the believed aimPos of the enemy object

Examples

Example 1:
_pos = player getHideFrom _enemy;

Additional Information

See also:
findCoversetHideBehindisHiddenknowsAboutforgetTarget

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 April 25, 2015 - 07:15 (UTC)
Benargee
This command is definatlely not broken, at least not in A3 1.42. It functions exactly as the description says it does. The reason why the Z value is elevated is because it represents the units torso. When the unit is prone and spotted, the Z value is much less. Here you can see a perfectly working example of this command Talk:getHideFrom#Operation Script Sample