func_monitor
Code classes:
CFuncMonitor
CFuncBrush
CBaseEntity
(all ents)
func_monitor
is a brush entity present in all games except Day of Defeat: Source and the Left 4 Dead games. It displays a real-time scene captured from a point_camera
somewhere else in the world.
For the entity to work, the surface(s) on which the camera view will be displayed must have a material with $basetexture _rt_Camera
in its VMT. Stock materials that work are dev\dev_combinemonitor*
and dev\dev_tvmonitor*
.
Note: Unless you set up multiple render textures in your mod's binaries, only one point_camera
can be rendered at any one time. The first camera in the map will appear on all monitors.
Bug: Visual artifacts may appear if the camera can see a func_monitor
.
To enable monitors in your non-HL2 SDK mod, you must:[Noted January 2010. Still accurate?]
- Include the entity's client .cpp file (found in
\client\hl2\
). - Include the entity's server .cpp and .h files (found in
\server\hl2\
). #define USE_MONITORS
at the top of\client\viewrender.cpp
and\client\view.cpp
.- Fix a multiplayer bug in
CPointCamera::CPointCamera()
by settingm_bActive
to true.
Keyvalues[edit | edit source]
- Camera name
(target)
<target_destination>
- The camera to render.
Inputs[edit | edit source]
- SetCamera
<target_destination>
- Changes Camera name.
See Also[edit | edit source]
info_camera_link
- For rendering point_cameras on models.asw_stylincam
- Used in for remote camera views.