Garry's Mod Wiki




Used for cam.Start.

Unless stated otherwise, the default values for all these keys would be inherited from the engine's current CViewSetup and do not have static representations.


x [number]

The x position of the view port

y [number]

The y position of the view port

w [number]

The width of the view port

h [number]

The height of the view port

type [string]

The type of cam. Valid types are:

  • "2D" - No additional arguments are required
  • "3D" - Only origin and angles are needed, all other parameters are optional.

Default: "3D"

origin [Vector]

The position to render from

angles [Angle]

The angles to render from

fov [number]

The field of view

aspect [number]

The aspect ratio of the view port (Note that this is NOT set to w/h by default)

zfar [number]

The distance to the far clipping plane

znear [number]

The distance to the near clipping plane

subrect [boolean]

Set to true if this is to draw into a subrect of the larger screen.

Default: false

bloomtone [boolean]


Default: false

offcenter [table]

A table having these keys: ( all floats )

  • left
  • right
  • bottom
  • top

ortho [table]

If set, makes the view/camera orthogonal. A table having these keys: ( all floats )

  • left
  • right
  • bottom
  • top

Special Pages



Render Time: 33ms

DB GetPage 4
Generate Html 8
SaveChanges (1) 13
Render Body 0
Render Sidebar 6