Page contents

light

This page is incomplete! You can contribute information using GitHub issues or pull requests.

...

Related HaloScript

Function/global

Type

(debug_lights [boolean])

Shows orange and white spheres with the radius of each dynamic light. White seems to show when a light is not yet been activated, such as the Warthog's brake lights until their first use. Lens flare only lights are not shown since their radius is 0.

Global
(rasterizer_environment_diffuse_lights [boolean])

Toggles the rendering of dynamic light diffuse illumination on the BSP. Does not affect specular highlights.

Global

Structure and fields

FieldTypeComments
flagsbitfield
FlagMaskComments
dynamic0x1
no specular0x2
don't light own object0x4
supersize in first person0x8

Guerilla describes this flag as: "For dynamic lights, light every environment surface if this light is on the gun of the current window". What this means is that the game will render the flashlight shader on all BSP faces in view, rather than just those within the light radius. This does not affect the visual appearance of the light, just how many faces it renders on. It's unclear why this would be beneficial, but it's enabled for the cyborg flashlight. Its effect on rendered dynamic light triangles can be observed with rasterizer_stats 2.

first person flashlight0x10

Causes the flashlight to align with the rotation of the first person weapon's flashlight marker when seen from first person. When this light is seen from third person, such as another player's flashlight, it will be aligned with their armour's integrated flashlight. If the player is holding a weapon without a flashlight marker, like the oddball or flag, or is zoomed in, the first person flashlight will align with armour light.

don't fade active camouflage0x20
radiusfloat
  • Default: 1
radius modiferBounds
  • Default: 1,1
FieldTypeComments
minfloat
maxfloat
falloff anglefloat
  • Default: 3.14159274101257
cutoff anglefloat
  • Default: 3.14159274101257
lens flare only radiusfloat
cos falloff anglefloat
  • Cache only
cos cutoff anglefloat
  • Cache only
specular radius multiplierfloat
  • Cache only

Not setting this to 2 breaks the first person flashlight.

sin cutoff anglefloat
  • Cache only
interpolation flagsbitfield
FlagMaskComments
blend in hsv0x1
more colors0x2
color lower boundColorARGB
FieldTypeComments
alphafloat
redfloat
greenfloat
bluefloat
color upper boundColorARGB?
primary cube mapTagDependency: bitmap
texture animation functionenum
OptionValueComments
one0x0
zero0x1
cosine0x2
cosine variable period0x3
diagonal wave0x4
diagonal wave variable period0x5
slide0x6
slide variable period0x7
noise0x8
jitter0x9
wander0xA
spark0xB
texture animation periodfloat
  • Unit: seconds
secondary cube mapTagDependency: bitmap
yaw functionenum?
yaw periodfloat
  • Unit: seconds
  • Default: 1
roll functionenum?
roll periodfloat
  • Unit: seconds
  • Default: 1
pitch functionenum?
pitch periodfloat
  • Unit: seconds
  • Default: 1
lens flareTagDependency: lens_flare
intensityfloat
colorColorRGB
durationfloat
  • Unit: seconds
falloff functionenum
OptionValueComments
linear0x0
early0x1
very early0x2
late0x3
very late0x4
cosine0x5

Acknowledgements

Thanks to the following individuals for their research or contributions to this topic:

  • Kavawuvi (Invader tag definitions)
  • MosesOfEgypt (Tag structure research)
  • smx (Tip on internal fields)