/tg/ Station 13 - Modules - TypesVar Details - Proc Details

overlay_lighting

Movable atom overlay-based lighting component.

Vars

affected_turfsLazy list to track the turfs being affected by our light, to determine their visibility.
current_holderMovable atom currently holding the light. Parent might be a flashlight, for example, but that might be held by a mob or something else.
light_overlaysCache of the possible light overlays, according to size.
lum_powerHow much this light affects the dynamic_lumcount of turfs.
lumcount_rangeCeiling of range, integer without decimal entries.
overlay_lighting_flagsFor light sources that can be turned on and off.
parent_attached_toMovable atom the parent is attached to. For example, a flashlight into a helmet or gun. We'll need to track the thing the parent is attached to as if it were the parent itself.
rangeHow far the light reaches, float.
set_alphaTransparency value.
visible_maskOverlay effect to cut into the darkness and provide light.

Procs

add_dynamic_lumiAdds the luminosity and source for the afected movable atoms to keep track of their visibility.
check_holderUsed to determine the new valid current_holder from the parent's loc.
clean_old_turfsClears the affected_turfs lazylist, removing from its contents the effects of being near the light.
get_new_turfsPopulates the affected_turfs lazylist, adding to its contents the effects of being near the light.
make_luminosity_updateClears the old affected turfs and populates the new ones.
on_holder_movedCalled when current_holder changes loc.
on_holder_qdelCalled when the current_holder is qdeleted, to remove the light effect.
on_light_flags_changeTriggered right before the parent light flags change.
on_parent_attached_to_movedCalled when parent_attached_to changes loc.
on_parent_attached_to_qdelCalled when the current_holder is qdeleted, to remove the light effect.
on_parent_movedCalled when parent changes loc.
on_toggleToggles the light on and off.
remove_dynamic_lumiRemoves the luminosity and source for the afected movable atoms to keep track of their visibility.
set_colorChanges the light's color, pretty straightforward.
set_holderCalled to change the value of current_holder.
set_lum_powerHere we append the behavior associated to changing lum_power.
set_parent_attached_toCalled to change the value of parent_attached_to.
set_powerChanges the intensity/brightness of the light by altering the visual object's alpha.
set_rangeChanges the range which the light reaches. 0 means no light, 6 is the maximum value.
turn_offToggles the light off.
turn_onToggles the light on.

Var Details

affected_turfs

Lazy list to track the turfs being affected by our light, to determine their visibility.

current_holder

Movable atom currently holding the light. Parent might be a flashlight, for example, but that might be held by a mob or something else.

light_overlays

Cache of the possible light overlays, according to size.

lum_power

How much this light affects the dynamic_lumcount of turfs.

lumcount_range

Ceiling of range, integer without decimal entries.

overlay_lighting_flags

For light sources that can be turned on and off.

parent_attached_to

Movable atom the parent is attached to. For example, a flashlight into a helmet or gun. We'll need to track the thing the parent is attached to as if it were the parent itself.

range

How far the light reaches, float.

set_alpha

Transparency value.

visible_mask

Overlay effect to cut into the darkness and provide light.

Proc Details

add_dynamic_lumi

Adds the luminosity and source for the afected movable atoms to keep track of their visibility.

check_holder

Used to determine the new valid current_holder from the parent's loc.

clean_old_turfs

Clears the affected_turfs lazylist, removing from its contents the effects of being near the light.

get_new_turfs

Populates the affected_turfs lazylist, adding to its contents the effects of being near the light.

make_luminosity_update

Clears the old affected turfs and populates the new ones.

on_holder_moved

Called when current_holder changes loc.

on_holder_qdel

Called when the current_holder is qdeleted, to remove the light effect.

on_light_flags_change

Triggered right before the parent light flags change.

on_parent_attached_to_moved

Called when parent_attached_to changes loc.

on_parent_attached_to_qdel

Called when the current_holder is qdeleted, to remove the light effect.

on_parent_moved

Called when parent changes loc.

on_toggle

Toggles the light on and off.

remove_dynamic_lumi

Removes the luminosity and source for the afected movable atoms to keep track of their visibility.

set_color

Changes the light's color, pretty straightforward.

set_holder

Called to change the value of current_holder.

set_lum_power

Here we append the behavior associated to changing lum_power.

set_parent_attached_to

Called to change the value of parent_attached_to.

set_power

Changes the intensity/brightness of the light by altering the visual object's alpha.

set_range

Changes the range which the light reaches. 0 means no light, 6 is the maximum value.

turn_off

Toggles the light off.

turn_on

Toggles the light on.