eyeDirection: Difference between revisions
Jump to navigation
Jump to search
Killzone Kid (talk | contribs) (example) |
Killzone Kid (talk | contribs) No edit summary |
||
Line 46: | Line 46: | ||
[[Category:Scripting Commands Arma 3|{{uc:{{PAGENAME}}}}]] | [[Category:Scripting Commands Arma 3|{{uc:{{PAGENAME}}}}]] | ||
[[Category:Scripting Commands|{{uc:{{PAGENAME}}}}]] | [[Category:Scripting Commands|{{uc:{{PAGENAME}}}}]] | ||
<!-- CONTINUE Notes --> | |||
<dl class="command_description"> | |||
<dd class="notedate">Posted on May 26, 2014 - 19:10 (UTC)</dd> | |||
<dt class="note">'''[[User:Killzone Kid|Killzone Kid]]'''</dt> | |||
<dd class="note"> | |||
This command should have really be named headDirection instead of [[eyeDirection]] as one could mistakenly think that eyes direction of your avatar correspond to the direction of the centre of your screen. '''In fact the direction returned by [[eyeDirection]] is avatar's head direction relative to the torso'''. Play with the script in example 1 to find out limitations. If you need centre of screen direction, use [[positionCameraToWorld]] instead. | |||
</dd> | |||
</dl> | |||
<!-- DISCONTINUE Notes --> |
Revision as of 20:10, 26 May 2014
Description
- Description:
- Returns the direction object is watching (eyes, or a vehicle primary observer).
- Groups:
- Uncategorised
Syntax
Examples
- Example 1:
can = "Land_Can_V3_F" createVehicle position player; onEachFrame { can setPosASL [ (eyePos player select 0) + (eyeDirection player select 0), (eyePos player select 1) + (eyeDirection player select 1), (eyePos player select 2) + (eyeDirection player select 2) ] }
Additional Information
- See also:
- positionCameraToWorld
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 May 26, 2014 - 19:10 (UTC)
- Killzone Kid
- This command should have really be named headDirection instead of eyeDirection as one could mistakenly think that eyes direction of your avatar correspond to the direction of the centre of your screen. In fact the direction returned by eyeDirection is avatar's head direction relative to the torso. Play with the script in example 1 to find out limitations. If you need centre of screen direction, use positionCameraToWorld instead.