G.EyeVector

From GMod Wiki

Revision as of 21:40, 2 November 2009 by Crazy Quebecer (Talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search
Function
Syntax EyeVector( )
Where is this used?
Description:
Return the client's view orientation as a normalized forward vector. The same as EyeAngles( ):GetNormalized( ).
Returns: Vector
Part of Library: Global Functions
Realm: NewerClient.png
BBCode Link: [b][url=http://wiki.garrysmod.com/?title=G.EyeVector]G.EyeVector [img]http://wiki.garrysmod.com/favicon.ico[/img][/url][/b]



Examples

DescriptionThis example code draws an explosion in front of the player's eyes.
Used onNewerClient.png
Code
 
local SpawnPos = EyePos( ) + EyeVector( )*100
 
local fx = EffectData( )
fx:SetOrigin( SpawnPos )
util.Effect( "Explosion", fx )
OutputN/A


See Also

Personal tools
Namespaces
Variants
Actions
Navigation
Lua Scripting
Functions
Hooks
Toolbox