/datum/element
A holder for simple behaviour that can be attached to many different types
Only one element of each type is instanced during game init. Otherwise acts basically like a lightweight component.
Vars | |
argument_hash_start_idx | The index of the first attach argument to consider for duplicate elements |
---|---|
element_flags | Option flags for element behaviour |
Procs | |
Attach | Activates the functionality defined by the element on the given target datum |
Detach | Deactivates the functionality defines by the element on the given datum |
Var Details
argument_hash_start_idx
The index of the first attach argument to consider for duplicate elements
All arguments from this index onwards (1 based) are hashed into the key to determine if this is a new unique element or one already exists
Is only used when flags contains ELEMENT_BESPOKE
This is infinity so you must explicitly set this
element_flags
Option flags for element behaviour
Proc Details
Attach
Activates the functionality defined by the element on the given target datum
Detach
Deactivates the functionality defines by the element on the given datum