Garry's Mod Wiki

Garry's Mod Wiki

  number WEAPON:TranslateFOV( number fov )

Description

Allows to change players field of view while player holds the weapon.

This hook must be defined shared and return same value on both to properly affect Area Portals.

Arguments

1 number fov
The current/default FOV.

Returns

1 number
The target FOV.

Example

Reduces players FOV by 30.

function SWEP:TranslateFOV( fov ) return fov - 30 end
Output: Players view is zoomed in.

This site is a community mirror of the official Garry's Mod wiki.. This site is not maintained by Facepunch Studios.

Page content is automatically updated four times a day. Edits and history are not available.

Last Parsed: Loading...