Garry's Mod Wiki

Player:GetViewEntity

Description

Returns the entity the player is using to see from (such as the player itself, the camera, or another entity).

Returns

1 Entity
The entity the player is using to see from

Example

Will print what entity the first player uses to look through.

print( Entity( 1 ):GetViewEntity() )
Output: Player [1][ExamplePlayer]

Page Links


Special Pages


Wikis

?

Render Time: 31ms

Session 0
DB GetPage 4
Generate Html 5
SaveChanges 9
Render Body 0
Render Sidebar 11