Env screenoverlay: Difference between revisions
Jump to navigation
Jump to search
Note:An overlay will be applied to all players in multiplayer games, even when the !activator is a player. To apply an overlay to a single client, (may require SV_CHEATS 1) you can call the Command r_screenoverlay <material_path> on a point_clientcommand.
Note:In some games including Counter-Strike: Global Offensive, Locally Hosted games require "sv_cheats 1" to use a point_clientcommand or a point_servercommand to set r_screenoverlay on individual players, despite that fact that r_screenoverlay has the flag server_can_execute. However, when hosted on a Dedicated Server, point_clientcommand CAN be used to set r_screenoverlay on individual players with "sv_cheats 0" - point_servercommand will not set r_screenoverlay on dedicated servers.
Note:In
, screen overlays are disabled by default. You must set cvar
Dimes2dope (talk | contribs) (add warning about setting screenoverlay on individual players in multiplayer - requires sv_cheats 1) |
Dimes2dope (talk | contribs) m (revised warning to a note, and added more information) |
||
Line 3: | Line 3: | ||
{{base point|env_screenoverlay}} It can display and control a set of screen overlays, to be displayed over the player's view. Useful for view effects like drunkenness, or teleporter afterimages, etc. | {{base point|env_screenoverlay}} It can display and control a set of screen overlays, to be displayed over the player's view. Useful for view effects like drunkenness, or teleporter afterimages, etc. | ||
{{note|An overlay will be applied to all players in multiplayer games, even when the !activator is a player. To apply an overlay to a single client, (may require '''SV_CHEATS 1''') you can call the Command r_screenoverlay <material_path> on a point_clientcommand. }} | {{note|An overlay will be applied to all players in multiplayer games, even when the !activator is a player. To apply an overlay to a single client, (may require '''SV_CHEATS 1''') you can call the Command r_screenoverlay <material_path> on a point_clientcommand. }} | ||
{{ | {{note|In some games including ''Counter-Strike: Global Offensive'', Locally Hosted games require "'''sv_cheats 1'''" to use a ''point_clientcommand'' or a ''point_servercommand'' to set '''r_screenoverlay''' on individual players, despite that fact that '''r_screenoverlay''' has the flag '''server_can_execute'''. However, when hosted on a Dedicated Server, point_clientcommand '''CAN''' be used to set '''r_screenoverlay''' on individual players with "'''sv_cheats 0'''" - ''point_servercommand'' will not set '''r_screenoverlay''' on dedicated servers. }} | ||
{{note|In {{portal2}}, screen overlays are disabled by default. You must set cvar <code>r_drawscreenoverlay</code> to <code>1</code> to enable.}} | {{note|In {{portal2}}, screen overlays are disabled by default. You must set cvar <code>r_drawscreenoverlay</code> to <code>1</code> to enable.}} | ||
Revision as of 20:04, 6 August 2017

env_screenoverlay in practice with effects/combine_binocoverlay. The following links to a youtube video of these in effect
Template:Base point It can display and control a set of screen overlays, to be displayed over the player's view. Useful for view effects like drunkenness, or teleporter afterimages, etc.




r_drawscreenoverlay
to 1
to enable.Materials
You can use any material as an overlay, but UnlitGeneric
ones are recommended to avoid artefacting.
Valve provide these materials in the /effects
folder:
- combine_binocoverlay
- Combine binoculars
- tp_eyefx/tpeye
- Green teleport shimmer
- tp_eyefx/tpeye2
Red teleport shimmer
- tp_eyefx/tpeye3
- Blue teleport shimmer
- tp_eyefx/tp_eyefx
- Drugged distortion
- tp_eyefx/tp_black
- Black. A probable bug makes it so that a thin border around the overlay is still visible.
- tp_eyefx/tp_eyefx_eli
- Flashing animation of three figures. Hardly usable as an overlay.
These materials are not designed as screen overlays, but will work as one:
- debug/yuv
- Monochrome (Black and white)
- effects/com_shield002a.vmt
- The combine shield shader effect - refraction with drifting squares.
- models/effects/portalfunnel_sheet
- Red-yellow-green scrolling ground overlay
- models/props_combine/portalball001_sheet
- Green downward haze
- effects/tp_refract
- Red/Orange Refractive overlay
- glass/glasswindow_refract01
- As if looking through a glass Observation window from Portal
Keyvalues
- Overlay Name 1 ([todo internal name (i)]) to Overlay Name 10 <string>
- Name of the first overlay material to display.
- Overlay Duration 1 ([todo internal name (i)]) to Overlay Duration 10 <float>
- Amount of time that the overlay should be displayed for, after which it will begin showing the next overlay. Setting this to -1 will make the entity display the overlay indefinitely, until it's forced to change by an input.
- Name (targetname) <string>[ Edit ]
- The name that other entities refer to this entity by, via Inputs/Outputs or other keyvalues (e.g.
parentname
ortarget
).
Also displayed in Hammer's 2D views and Entity Report.See also: Generic Keyvalues, Inputs and Outputs available to all entities
Flags
- 1 : Allow Suit Zoom
Inputs
- StartOverlays
- Start displaying the first overlay.
- StopOverlays
- Stop displaying any overlays.
- SwitchOverlay <float >
- Switch to displaying a specific overlay. Pass in the desired overlay number in the parameter. Entering -1 as the value will cause the overlay to display indefinitely.
Outputs
See also
- Overlays - A large list of overlays.