Beam spotlight: Difference between revisions
Jump to navigation
Jump to search

Warning:
Note:This spotlight is entirely client side, and rotation may be desynchronized between clients.
Note:This entity is also available in
Garry's Mod .
Tip:Can be set to rotate for a lighthouse search beam effect.
Thunder4ik (talk | contribs) m (→top: clean up, replaced: {{ModernTip| → {{tip|, {{ModernNote| → {{note| (2)) |
m (Updated old entity format to {{this is a}}. This action was perfomed by a bot.) |
||
Line 1: | Line 1: | ||
{{lang | <!-- When this page is updated to {{langsp}} or {{language subpage}} instead of {{lang}}, please move {{this is a}} to the base page, as it is automatically translated. -->{{lang}}{{CD|CBeamSpotlight|file1=beamspotlight.cpp}} | ||
{{CD|CBeamSpotlight|file1=beamspotlight.cpp}} | |||
{{ | {{this is a|name=beam_spotlight|1=e0|sprite=1|engine=2|since=Left 4 Dead}} It is used to draw a spotlight. Will draw a beam when the player views it side on, and a halo when it's facing towards the player. It will also create a dynamic light wherever the end of the spotlight rests. Other than its ability to rotate, this entity is functionally identical to {{ent|point_spotlight}}. | ||
{{note|This spotlight is entirely client side, and rotation may be desynchronized between clients.}} | {{note|This spotlight is entirely client side, and rotation may be desynchronized between clients.}} |
Revision as of 06:16, 4 January 2024
![]() |
---|
CBeamSpotlight |
![]() |

beam_spotlight
is an e0 available in all Template:2 games since Left 4 Dead.Template:2 topicon

- The {{{engine}}} parameter is inconsistent with the name defined by the {{2}} template.
If a parameter is consistent but you're still seeing this warning, it may be an issue with the template itself. Please discuss it on the template's talk page.
It is used to draw a spotlight. Will draw a beam when the player views it side on, and a halo when it's facing towards the player. It will also create a dynamic light wherever the end of the spotlight rests. Other than its ability to rotate, this entity is functionally identical to point_spotlight.




Flags
- Start On : [1]
- No Dynamic Light - Do not create any actual light. : [2]
- Start with Rotation On : [4]
- Reverse Direction : [8]
- X Axis : [16]
- Y Axis : [32]
([Clarify] are these axes relative to the world or to the entity?)
Keyvalues
- Max Rotation Speed (maxspeed) <integer>
- The maximum rotation speed of the spotlight, in degrees per second.
- Spotlight Length (SpotlightLength) <integer>
- Length of the spotlight beam.
- Spotlight Width (SpotlightWidth) <integer>
- Width of the spotlight beam.
- HDR color scale (HDRColorScale) <float>
- Multiplier for sprite color by when running in HDR mode.
- Halo Sprite (HaloSprite) <sprite> (only in
)
- The material that should be used for the halo.
- Beam Sprite (BeamSprite) <sprite> (only in
)
- The material that should be used for the beam.
RenderFields:
- Render Mode (rendermode) <byte choices>
- Set a non-standard rendering mode on this entity.
Render Modes
- Render FX (renderfx) <byte choices>
- Various somewhat legacy alpha effects. See render effects.
- Render Amount / Transparency (renderamt) <byte>
- Transparency amount, requires a Render Mode other than Normal. 0 is invisible, 255 is fully visible.
- Render Color (R G B) (rendercolor) <color255>
- Color tint.
Inputs
- LightOn
- Turn the spotlight on.
- LightOff
- Turn the spotlight off
- Start
- Start rotating.
- Stop
- Stop rotating.
- Reverse
- Reverse the direction of rotation.
RenderFields:
- Alpha <integer 0–255>
- Sets the entity's transparency to a number from 0 (invisible) to 255 (fully visible). Requires the entity to have its
rendermode
set to a number other than0
.
- Color <color255 >
- Sets an RGB color for the entity.
Outputs
- OnLightOn
- Fires when light turns on.
- OnLightOff
- Fires when light turns off.