point_spotlight

From Source Entities
Jump to navigation Jump to search
A spotlight from cs_office showing a beam.

Code classes:

point_spotlight is a point entity present in all Source games. It's a lighting effect that either shows a beam or a halo, depending on where the viewer is.

Flags[edit | edit source]

  • 1: Start On
  • 2: No Dynamic Light - Does not emit real-time lighting affecting the brightness of props and world geometry.

Keyvalues[edit | edit source]

Ignore Solid (IgnoreSolid) <boolean> (only available in Half-Life 2: Deathmatch)
If not set, the beam will automatically shorten itself upon hitting a solid surface to avoid going through it.
Spotlight Length (spotlightlength) <float>
Length of the spotlight beam and dynamic light.
Spotlight Width (spotlightwidth) <float>
Width of the spotlight beam and dynamic light.
HDR color scale (HDRColorScale) <float>
No effect.
Render Color (R G B) (rendercolor) <color255>
Color channel filter to add to this entity's texture(s). Bug: Broken for brush entities.
Minimum DX Level (mindxlevel) to Maximum DX Level (maxdxlevel) <choices> (only available in games before Left 4 Dead)
Very outdated settings. Their functionality seems to no longer be fully intact. Nearly all players will be at the highest setting anyway because DirectX 8 has been obsolete since 2002. This is still in the FGD for Alien Swarm, but it doesn't use it.
Minimum CPU Level (mincpulevel) to Maximum CPU Level (maxcpulevel) <choices> (available in all games since )
A user with the "effect detail" setting not in this specific range will not see this object.
  • 0: Default
  • 1: Low
  • 2: Medium
  • 3: High
Minimum GPU Level (mingpulevel) to Maximum GPU Level (maxgpulevel) <choices> (available in all games since )
A user with the "shader detail" setting not in this specific range will not see this object. Settings are named differently in different games.
  • 0: Default
  • 1: Very low or Low
  • 2: Low or Medium
  • 3: Medium or High
  • 4: High or Very High
Halo size scale (HaloScale) <float> (only available in )
Multiplies the size of the halo.

Inputs[edit | edit source]

LightOn
Turns the light on.
LightOff
Turns the light off.
SetColor <color255> (available in all games since )
Sets Render Color. No reason to use this instead of Color.
ForceUpdate  (available in all games since )
"Force an update of the spotlight position and orientation" Clarify: What situations would require this?

Outputs[edit | edit source]

OnLightOn
Fires when the light turns on. Bug: Stops firing if the entity has or had a parent.
OnLightOff
Fires when the light turns off.

See Also[edit | edit source]