byond - Modules - TypesVar Details - Proc Details

/datum/beam

Vars

always_turnwill the origin object always turn to face the target?
beam_typethe objects placed in the elements list
elementslist of beam objects. These have their visuals set by the visuals var which is created on starting
iconicon used by the beam.
icon_stateicon state of the main segments of the beam
max_distanceThe beam will qdel if it's longer than this many tiles.
originwhere the beam goes from
targetwhere the beam goes to
visualsThis is used as the visual_contents of beams, so you can apply one effect to this and the whole beam will look like that. never gets deleted on redrawing.

Procs

DrawCreates the beam effects and places them in a line from the origin to the target. Sets their rotation to make the beams face the target, too.
StartProc called by the atom Beam() proc. Sets up signals, and draws the beam for the first time.
redrawingTriggered by signals set up when the beam is set up. If it's still sane to create a beam, it removes the old beam, creates a new one. Otherwise it kills the beam.

Var Details

always_turn

will the origin object always turn to face the target?

beam_type

the objects placed in the elements list

elements

list of beam objects. These have their visuals set by the visuals var which is created on starting

icon

icon used by the beam.

icon_state

icon state of the main segments of the beam

max_distance

The beam will qdel if it's longer than this many tiles.

origin

where the beam goes from

target

where the beam goes to

visuals

This is used as the visual_contents of beams, so you can apply one effect to this and the whole beam will look like that. never gets deleted on redrawing.

Proc Details

Draw

Creates the beam effects and places them in a line from the origin to the target. Sets their rotation to make the beams face the target, too.

Start

Proc called by the atom Beam() proc. Sets up signals, and draws the beam for the first time.

redrawing

Triggered by signals set up when the beam is set up. If it's still sane to create a beam, it removes the old beam, creates a new one. Otherwise it kills the beam.

Arguments: mover: either the origin of the beam or the target of the beam that moved. oldloc: from where mover moved. direction: in what direction mover moved from.