Env starfield: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
No edit summary
m (→‎Inputs: Substituted IO templates)
 
(30 intermediate revisions by 15 users not shown)
Line 1: Line 1:
env_starfield
{{LanguageBar}}
[[File:Env starfield.jpg|thumb|300px|right]]
{{CD|CEnvStarfield|file1=env_starfield.cpp}}
{{this is a|point entity|name=env_starfield|game=Half-Life 2 series}} This creates the starfield effect used in the {{ent|d1_trainstation_01}} intro for Half-Life 2.


Starfield effect
{{note|This is not the entity used in the {{ent|c5a1}} outro in Half-Life. That is a system of 42 {{ent|func_train}}s.}}


KEYS
{{bug|Due to how the star trails are coded, their direction of travel will look inconsistent if the player looks around.}}


Name targetname <target_source> The name that other entities refer to this entity by.
{{bug|If the player pauses the game, the number of star trails spawned will pile up over time, creating a sort of "burst" effect when unpaused.}}


{{stray ent|{{portal}}}}


INPUTS
==Keyvalues==
{{KV Targetname}}


Kill Removes this entity from the world.
==Inputs==
{{I|TurnOn|Turn on}}
{{I|TurnOff|Turn off}}
{{I|SetDensity|param=float|Set the density of the starfield. It's a multiplier, so 1 is the default.}}


KillHierarchy Removes this entity and all its children from the world.
==See also==
 
*{{ent|script_intro}}
AddOutput <string> Adds an entity I/O connection to this entity. Format: <output name> <targetname>:<inputname>:<parameter>:<delay>:<max times to fire (-1 == infinite)>. Very dangerous, use with care.
 
FireUser1 Causes this entity's OnUser1 output to be fired.
 
FireUser2 Causes this entity's OnUser2 output to be fired.
 
FireUser3 Causes this entity's OnUser3 output to be fired.
 
FireUser4 Causes this entity's OnUser4 output to be fired.
 
TurnOn Turn on
 
TurnOff Turn off
 
SetDensity <float> Set the density of the starfield. It's a multiplier, so 1 is the default.
 
 
OUTPUTS
 
OnUser1 Fired in response to FireUser1 input.
 
OnUser2 Fired in response to FireUser2 input.
 
OnUser3 Fired in response to FireUser3 input.
 
OnUser4 Fired in response to FireUser4 input.

Latest revision as of 10:54, 21 April 2025

English (en)Translate (Translate)
Env starfield.jpg
C++ Class hierarchy
CEnvStarfield
CBaseEntity
C++ env_starfield.cpp

env_starfield is a point entity available in Half-Life 2 series Half-Life 2 series. This creates the starfield effect used in the d1_trainstation_01 intro for Half-Life 2.

Note.pngNote:This is not the entity used in the c5a1 outro in Half-Life. That is a system of 42 func_trains.
Icon-Bug.pngBug:Due to how the star trails are coded, their direction of travel will look inconsistent if the player looks around.  [todo tested in ?]
Icon-Bug.pngBug:If the player pauses the game, the number of star trails spawned will pile up over time, creating a sort of "burst" effect when unpaused.  [todo tested in ?]
Note.pngNote:This entity is also in the code for Portal. Its functionality is not guaranteed.


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

Inputs

TurnOn
Turn on
TurnOff
Turn off
SetDensity <floatRedirectInput/float>
Set the density of the starfield. It's a multiplier, so 1 is the default.

See also