getCameraViewDirection: Difference between revisions
Jump to navigation
Jump to search
Killzone Kid (talk | contribs) m (internal camera for human players) |
mNo edit summary |
||
Line 7: | Line 7: | ||
____________________________________________________________________________________________ | ____________________________________________________________________________________________ | ||
| Returns the direction unit is looking. For human player it returns direction of the "INTERNAL" [[cameraView]] only. |= Description | | Returns the direction unit is looking in render time scope. For human player it returns direction of the "INTERNAL" [[cameraView]] only. |= Description | ||
____________________________________________________________________________________________ | ____________________________________________________________________________________________ | ||
Revision as of 00:55, 22 February 2016
Description
- Description:
- Returns the direction unit is looking in render time scope. For human player it returns direction of the "INTERNAL" cameraView only.
- Groups:
- Uncategorised
Syntax
Examples
- Example 1:
- Draw AI eye direction (green), weapon direction (red) and camera direction (blue) in 3D:
bob = createGroup east createUnit ["O_Soldier_F", [0,0,0], [], 0, "NONE"]; bob setVehiclePosition [player modelToWorld [0,100,0], [], 0, "NONE"]; onEachFrame { _beg = ASLToAGL eyePos bob; _endE = (_beg vectorAdd (eyeDirection bob vectorMultiply 100)); drawLine3D [ _beg, _endE, [0,1,0,1]]; _endW = (_beg vectorAdd (bob weaponDirection currentWeapon bob vectorMultiply 100)); drawLine3D [_beg, _endW, [1,0,0,1]]; _endV = (_beg vectorAdd (getCameraViewDirection bob vectorMultiply 100)); drawLine3D [_beg, _endV, [0,0,1,1]]; };
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
[[Category:Introduced with arma3dev version 1.57]][[ Category: arma3dev: New Scripting Commands | GETCAMERAVIEWDIRECTION]][[ Category: arma3dev: Scripting Commands | GETCAMERAVIEWDIRECTION]]