byond - Modules - TypesVar Details - Proc Details

/datum/status_effect/stacking

Status effects that can stack.

Vars

consumed_on_thresholdIf TRUE, the status effect is consumed / removed when stack_threshold is met
delay_before_decay(first stack will be removed at this time plus tick_interval)
max_stacksThe maximum number of stacks that can be applied
stack_decayHow many stacks are lost per tick (decay trigger)
stack_thresholdThe threshold for having special effects occur when a certain stack number is reached
stacksHow many stacks are currently accumulated. Also, the default stacks number given on application.
threshold_crossedSet to true once the stack_threshold is crossed, and false once it falls back below

Procs

add_stacksAdd (or remove) [stacks_added] stacks to our current stack count.
can_gain_stacksWhether the owner can currently gain stacks or not Return FALSE if the owner is not in a valid state, or TRUE otherwise
can_have_statusWhether the owner can have the status effect. Return FALSE if the owner is not in a valid state (self-deletes the effect), or TRUE otherwise
fadeout_effectEffects that occur if the status is removed due to being under 1 remaining stack
on_threshold_crossCalled when the stack_threshold is crossed (stacks go over the threshold)
on_threshold_dropCalled when the stack_threshold is uncrossed / dropped (stacks go under the threshold after being over it)
stack_decay_effectRuns every time tick(), causes stacks to decay over time
stacks_consumed_effectEffects that occur if the status effect is removed due to the stack_threshold being crossed
threshold_cross_effectEffects that occur when the stack count crosses stack_threshold

Var Details

consumed_on_threshold

If TRUE, the status effect is consumed / removed when stack_threshold is met

delay_before_decay

(first stack will be removed at this time plus tick_interval)

max_stacks

The maximum number of stacks that can be applied

stack_decay

How many stacks are lost per tick (decay trigger)

stack_threshold

The threshold for having special effects occur when a certain stack number is reached

stacks

How many stacks are currently accumulated. Also, the default stacks number given on application.

threshold_crossed

Set to true once the stack_threshold is crossed, and false once it falls back below

Proc Details

add_stacks

Add (or remove) [stacks_added] stacks to our current stack count.

can_gain_stacks

Whether the owner can currently gain stacks or not Return FALSE if the owner is not in a valid state, or TRUE otherwise

can_have_status

Whether the owner can have the status effect. Return FALSE if the owner is not in a valid state (self-deletes the effect), or TRUE otherwise

fadeout_effect

Effects that occur if the status is removed due to being under 1 remaining stack

on_threshold_cross

Called when the stack_threshold is crossed (stacks go over the threshold)

on_threshold_drop

Called when the stack_threshold is uncrossed / dropped (stacks go under the threshold after being over it)

stack_decay_effect

Runs every time tick(), causes stacks to decay over time

stacks_consumed_effect

Effects that occur if the status effect is removed due to the stack_threshold being crossed

threshold_cross_effect

Effects that occur when the stack count crosses stack_threshold