Garry's Mod Wiki

Player:SetViewEntity

  Player:SetViewEntity( Entity viewEntity )

Description

Attaches the players view to the position and angles of the specified entity.

By default, the view is in first person and its model will not be rendered. Player:SetObserverMode can be used to enable drawing of view entity.

Arguments

1 Entity viewEntity
The entity to attach the player view to.