This article's documentation is for anything that uses the Source engine. Click here for more information.

Env screeneffect: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
m (Robot: fixing template case.)
(Undo revision 487182 by Gtamike (talk) What does that even mean and why write about an output here? rephrase?)
Tag: Undo
 
(24 intermediate revisions by 15 users not shown)
Line 1: Line 1:
{{wrongtitle|title=env_screeneffect}}
{{LanguageBar}}
{{base_point_ep1}}[[Category: GUI Entities]]
{{CD|CEnvScreenEffect|file1=env_screenoverlay.cpp}}
{{This is a|logical entity|name=env_screeneffect}} It allows screenspace effects to be played on the player's view.


==Entity Description==
{{bug|hidetested=1|Does not function in {{tf2|4}} and {{portal2|4}}.}}
Allows screenspace effects to be played on the player's view.
{{bug|hidetested=1|Causes a memory leak in {{l4d2|4}} by spamming garbage data to the console, do not use this entity for that game!}}
==Keyvalues==
{{bug|tested={{hl2}},{{portal}},{{p2ce}},{{bms}}|Effects will not work properly if {{ent|func_reflective_glass}} or [[Water (shader)|water]] with planar reflections is in player's field of view. {{ent|env_fade}} also can't hide everything at such moment. [https://youtu.be/_6epgXedVBg Example].}}
* {{KV Targetname}}
 
* '''type'''
== Keyvalues ==
: <choices> Effect Type
{{KV Targetname}}
:{|
{{KV|Effect Type|intn=type|choices|Which effect to use.
! Literal Value || Description
:*0: Advisor Stun
|-
:*1: Intro Blur
| 0 || Advisor Stun
:*2: Groggy Vision}}
|-
 
| 1 || Intro Blur
== Inputs ==
|-
{{I|StartEffect|Start the effect with the duration in seconds as the passed parameter.|param=float}}
| 2 || Groggy Vision
{{I|StopEffect|Fade out the effect over the duration in seconds as the passed parameter.|param=float}}
|}
 
==Inputs==
[[Category:GUI Entities]]
* {{I Targetname}}
* '''StartEffect <float>'''
: Start the effect with the duration in seconds as the passed parameter.
* '''StopEffect'''
: Stop the effect.
==Outputs==
* {{O Targetname}}

Latest revision as of 08:21, 17 August 2025

English (en)Translate (Translate)
C++ Class hierarchy
CEnvScreenEffect
CPointEntity
CBaseEntity
C++ env_screenoverlay.cpp

env_screeneffect is a logical entity available in all Source Source games. It allows screenspace effects to be played on the player's view.

Icon-Bug.pngBug:Does not function in Team Fortress 2 Team Fortress 2 and Portal 2 Portal 2.
Icon-Bug.pngBug:Causes a memory leak in Left 4 Dead 2 Left 4 Dead 2 by spamming garbage data to the console, do not use this entity for that game!
Icon-Bug.pngBug:Effects will not work properly if func_reflective_glass or water with planar reflections is in player's field of view. env_fade also can't hide everything at such moment. Example.  (tested in: Half-Life 2,Portal,Portal 2: Community Edition,Black Mesa)

Keyvalues

Name (targetname) <string>[ Edit ]
The name that other entities refer to this entity by, via Inputs/Outputs or other keyvalues (e.g. parentname or target).
Also displayed in Hammer's 2D views and Entity Report.
See also:  Generic Keyvalues, Inputs and Outputs available to all entities

Effect Type (type) <choices>
Which effect to use.
  • 0: Advisor Stun
  • 1: Intro Blur
  • 2: Groggy Vision

Inputs

StartEffect <floatRedirectInput/float>
Start the effect with the duration in seconds as the passed parameter.
StopEffect <floatRedirectInput/float>
Fade out the effect over the duration in seconds as the passed parameter.