Goonstation 13 - Modules - TypesDefine Details

_std/defines/component_defines.dm

SEND_SIGNALUsed to trigger signals and call procs registered for that signal The datum hosting the signal is automaticaly added as the first argument Returns a bitfield gathered from all registered procs Arguments given here are packaged in a list and given to _SendSignal
SEND_GLOBAL_SIGNALtarget to use for signals that are global and not tied to a single datum.
AddComponentA wrapper for _AddComponent that allows us to pretend we're using normal named arguments
COMPONENT_INCOMPATIBLEReturn this from /datum/component/Initialize or datum/component/OnTransfer to have the component be deleted if it's applied to an incorrect type.
COMPONENT_NOTRANSFERReturned in PostTransfer to prevent transfer, similar to COMPONENT_INCOMPATIBLE
COMPONENT_DUPE_HIGHLANDERold component is deleted (default)
COMPONENT_DUPE_ALLOWEDduplicates allowed
COMPONENT_DUPE_UNIQUEnew component is deleted
COMPONENT_DUPE_UNIQUE_PASSARGSold component is given the initialization args of the new
COMPONENT_DUPE_SELECTIVEeach component of the same type is consulted as to whether the duplicate should be allowed
COMSIG_COMPONENT_ADDEDwhen a component is added to a datum: (/datum/component)
COMSIG_COMPONENT_REMOVINGbefore a component is removed from a datum because of RemoveComponent: (/datum/component)
COMSIG_PARENT_PRE_DISPOSINGjust before a datum's disposing()
COMSIG_ATOM_DIR_CHANGEDwhen an atom changes dir (olddir, newdir)
COMSIG_ATOM_HITBY_PROJwhen an atom is collided by a projectile (/obj/projectile)
COMSIG_ATOM_HITBY_THROWNwhen an atom is hit by a thrown thing (thrown_atom, /datum/thrown_thing)
COMSIG_ATOM_EXAMINEwhen an atom is examined (/mob/examiner, /list/lines), append to lines for more description
COMSIG_UPDATE_ICONwhen something happens that should trigger an icon update. Or something.
COMSIG_MOVABLE_MOVEDwhen an AM moves (thing, previous_loc, direction)
COMSIG_MOVABLE_SET_LOCwhen an AM moves (thing, previous_loc)
COMSIG_MOVABLE_THROW_ENDwhen an AM ends throw (thing, /datum/thrown_thing)
COMSIG_ITEM_EQUIPPEDWhen an item is equipped (user, slot)
COMSIG_ITEM_UNEQUIPPEDWhen an item is unequipped (user)
COMSIG_ITEM_PICKUPWhen an item is picked up (user)
COMSIG_ITEM_DROPPEDWhen an item is picked dropped (user)
COMSIG_ITEM_ATTACK_POSTWhen an item is used to attack a mob
COMSIG_ITEM_CONSUMED_PREJust before an item is eaten
COMSIG_ITEM_CONSUMEDWhen an item is eaten
COMSIG_ITEM_CONSUMED_PARTIALAfter an item's been eaten, but there's still some left
COMSIG_ITEM_CONSUMED_ALLAfter we've consumed an item
COMSIG_ITEM_ATTACK_PREWhen an item is used to attack a mob before it actually hurts the mob
COMSIG_ITEM_ATTACK_SELFWhen an item is used in-hand
COMSIG_ITEM_SWAP_TOWhen an item is swapped to [does not include being picked up/taken out of bags/etc] (user)
COMSIG_ITEM_SWAP_AWAYWhen an item is swapped away from [does not include being picked up/taken out of bags/etc] (user)
COMSIG_ITEM_SPECIAL_POSTAfter an item's itemspecial is used (user)
COMSIG_ITEM_PROCESSWhen items process ticks on an item
COMSIG_CLOAKING_DEVICE_DEACTIVATEMake cloaking devices turn off
COMSIG_DISGUISER_DEACTIVATEMake disguiser devices turn off
COMSIG_IMPLANT_IMPLANTEDWhen implanted
COMSIG_IMPLANT_REMOVEDWhen removed
COMSIG_TOOLTIP_BLOCKING_APPENDAppend to the end of the blocking section of tooltip (list/tooltip)
COMSIG_ITEM_BLOCK_BEGINAfter an item block is set up
COMSIG_ITEM_BLOCK_ENDWhen an item block is disposed
COMSIG_UNARMED_BLOCK_BEGINAfter an unarmed block is set up
COMSIG_UNARMED_BLOCK_ENDWhen an item block is created
COMSIG_BLOCK_BLOCKEDWhen a block blocks damage at all
COMSIG_MOB_LOGINWhen a client logs into a mob
COMSIG_MOB_LOGOUTWhen a client logs out of a mob
COMSIG_MOB_ATTACKED_PREAt the beginning of when an attackresults datum is being set up
COMSIG_MOB_DEATHWhen a mob dies
COMSIG_MOB_FAKE_DEATHWhen a mob fakes death
COMSIG_MOB_THROW_ITEMsent when a mob throws something (target, params)
COMSIG_MOB_GEIGER_TICKsent when radiation status ticks on mob (stage)
COMSIG_MOUSEUPon mouseup
COMSIG_LIVING_LIFE_TICKWhen a Life tick occurs
COMSIG_MOB_PROP_INVISIBILITYWhen invisibility of a mob gets updated (old_value)
COMSIG_ATTACKBYAttacking with an item in-hand (item, attacker)
COMSIG_ATTACKHANDAttacking without an item in-hand (attacker)
COMSIG_PROJ_COLLIDEAfter a projectile makes a valid hit on an atom (after immunity/other early returns, before other effects)
COMSIG_MECHCOMP_ADD_INPUTAdd an input chanel for a device to send into
COMSIG_MECHCOMP_ADD_CONFIGConnect two mechcomp devices together
COMSIG_MECHCOMP_ALLOW_MANUAL_SIGNALConnect two mechcomp devices together
COMSIG_MECHCOMP_RM_ALL_CONNECTIONSRemove all connected devices
COMSIG_MECHCOMP_TRANSMIT_SIGNALPassing the signal of a message to all connected mechcomp devices for handling (message will be instatiated by the component)
COMSIG_MECHCOMP_TRANSMIT_MSGPassing a message to all connected mechcomp devices for handling
COMSIG_MECHCOMP_TRANSMIT_DEFAULT_MSGPassing the stored message to all connected mechcomp devices for handling
_COMSIG_MECHCOMP_RECEIVE_MSGReceiving a message from a mechcomp device for handling
_COMSIG_MECHCOMP_RM_INCOMINGRemove {the caller} from the list of transmitting devices
_COMSIG_MECHCOMP_RM_OUTGOINGRemove {the caller} from the list of receiving devices
_COMSIG_MECHCOMP_GET_OUTGOINGReturn the component's outgoing connections
_COMSIG_MECHCOMP_GET_INCOMINGReturn the component's incoming connections
_COMSIG_MECHCOMP_DROPCONNECTBegin to connect two mechcomp devices together
_COMSIG_MECHCOMP_LINKConnect one MechComp compatible device as a receiver to a trigger. (This is meant to be a private method)
_COMSIG_MECHCOMP_COMPATIBLEReturns 1
_COMSIG_MECHCOMP_DISPATCH_ADD_FILTERAdd a filtered connection, getting user input on the filter
_COMSIG_MECHCOMP_DISPATCH_RM_OUTGOINGRemove a filtered connection
_COMSIG_MECHCOMP_DISPATCH_VALIDATETest a signal to be sent to a connection
COMSIG_CELL_SWAPWhen the cell in a uses_cell component should be swapped out (cell, user)
COMSIG_CELL_TRY_SWAPWhen a cell is attacked, try to initiate a cellswap on the attacking obj (cell, user)
COMSIG_CELL_CAN_CHARGEIf an item can be charged
COMSIG_CELL_CHARGECharge a small-cell (amount)
COMSIG_CELL_USEUse some charge from a small-cell (amount, bypass)
COMSIG_CELL_IS_CELLCheck if thing is a power cell
COMSIG_CELL_CHECK_CHARGEGet the current charge and max charge of a power cell (list(charge)), or check if charge is higher than an amount (charge), or just check if there is a cell at all (null)
COMSIG_CELL_FORCE_NEW_CELLForce an update to the cellholder's cell. Takes an atom/movable that is a powercell, a powercell component, or a list of args for the powercell to inherit
COMSIG_AREA_ACTIVATEDarea's active var set to true (when a client enters)
COMSIG_AREA_DEACTIVATEDarea's active var set to false (when all clients leave)

Define Details

AddComponent

A wrapper for _AddComponent that allows us to pretend we're using normal named arguments

COMPONENT_DUPE_ALLOWED

duplicates allowed

COMPONENT_DUPE_HIGHLANDER

old component is deleted (default)

COMPONENT_DUPE_SELECTIVE

each component of the same type is consulted as to whether the duplicate should be allowed

COMPONENT_DUPE_UNIQUE

new component is deleted

COMPONENT_DUPE_UNIQUE_PASSARGS

old component is given the initialization args of the new

COMPONENT_INCOMPATIBLE

Return this from /datum/component/Initialize or datum/component/OnTransfer to have the component be deleted if it's applied to an incorrect type.

parent must not be modified if this is to be returned. This will be noted in the runtime logs.

COMPONENT_NOTRANSFER

Returned in PostTransfer to prevent transfer, similar to COMPONENT_INCOMPATIBLE

COMSIG_AREA_ACTIVATED

area's active var set to true (when a client enters)

COMSIG_AREA_DEACTIVATED

area's active var set to false (when all clients leave)

COMSIG_ATOM_DIR_CHANGED

when an atom changes dir (olddir, newdir)

COMSIG_ATOM_EXAMINE

when an atom is examined (/mob/examiner, /list/lines), append to lines for more description

COMSIG_ATOM_HITBY_PROJ

when an atom is collided by a projectile (/obj/projectile)

COMSIG_ATOM_HITBY_THROWN

when an atom is hit by a thrown thing (thrown_atom, /datum/thrown_thing)

COMSIG_ATTACKBY

Attacking with an item in-hand (item, attacker)

COMSIG_ATTACKHAND

Attacking without an item in-hand (attacker)

COMSIG_BLOCK_BLOCKED

When a block blocks damage at all

COMSIG_CELL_CAN_CHARGE

If an item can be charged

COMSIG_CELL_CHARGE

Charge a small-cell (amount)

COMSIG_CELL_CHECK_CHARGE

Get the current charge and max charge of a power cell (list(charge)), or check if charge is higher than an amount (charge), or just check if there is a cell at all (null)

COMSIG_CELL_FORCE_NEW_CELL

Force an update to the cellholder's cell. Takes an atom/movable that is a powercell, a powercell component, or a list of args for the powercell to inherit

COMSIG_CELL_IS_CELL

Check if thing is a power cell

COMSIG_CELL_SWAP

When the cell in a uses_cell component should be swapped out (cell, user)

COMSIG_CELL_TRY_SWAP

When a cell is attacked, try to initiate a cellswap on the attacking obj (cell, user)

COMSIG_CELL_USE

Use some charge from a small-cell (amount, bypass)

COMSIG_CLOAKING_DEVICE_DEACTIVATE

Make cloaking devices turn off

COMSIG_COMPONENT_ADDED

when a component is added to a datum: (/datum/component)

COMSIG_COMPONENT_REMOVING

before a component is removed from a datum because of RemoveComponent: (/datum/component)

COMSIG_DISGUISER_DEACTIVATE

Make disguiser devices turn off

COMSIG_IMPLANT_IMPLANTED

When implanted

COMSIG_IMPLANT_REMOVED

When removed

COMSIG_ITEM_ATTACK_POST

When an item is used to attack a mob

COMSIG_ITEM_ATTACK_PRE

When an item is used to attack a mob before it actually hurts the mob

COMSIG_ITEM_ATTACK_SELF

When an item is used in-hand

COMSIG_ITEM_BLOCK_BEGIN

After an item block is set up

COMSIG_ITEM_BLOCK_END

When an item block is disposed

COMSIG_ITEM_CONSUMED

When an item is eaten

COMSIG_ITEM_CONSUMED_ALL

After we've consumed an item

COMSIG_ITEM_CONSUMED_PARTIAL

After an item's been eaten, but there's still some left

COMSIG_ITEM_CONSUMED_PRE

Just before an item is eaten

COMSIG_ITEM_DROPPED

When an item is picked dropped (user)

COMSIG_ITEM_EQUIPPED

When an item is equipped (user, slot)

COMSIG_ITEM_PICKUP

When an item is picked up (user)

COMSIG_ITEM_PROCESS

When items process ticks on an item

COMSIG_ITEM_SPECIAL_POST

After an item's itemspecial is used (user)

COMSIG_ITEM_SWAP_AWAY

When an item is swapped away from [does not include being picked up/taken out of bags/etc] (user)

COMSIG_ITEM_SWAP_TO

When an item is swapped to [does not include being picked up/taken out of bags/etc] (user)

COMSIG_ITEM_UNEQUIPPED

When an item is unequipped (user)

COMSIG_LIVING_LIFE_TICK

When a Life tick occurs

COMSIG_MECHCOMP_ADD_CONFIG

Connect two mechcomp devices together

COMSIG_MECHCOMP_ADD_INPUT

Add an input chanel for a device to send into

COMSIG_MECHCOMP_ALLOW_MANUAL_SIGNAL

Connect two mechcomp devices together

COMSIG_MECHCOMP_RM_ALL_CONNECTIONS

Remove all connected devices

COMSIG_MECHCOMP_TRANSMIT_DEFAULT_MSG

Passing the stored message to all connected mechcomp devices for handling

COMSIG_MECHCOMP_TRANSMIT_MSG

Passing a message to all connected mechcomp devices for handling

COMSIG_MECHCOMP_TRANSMIT_SIGNAL

Passing the signal of a message to all connected mechcomp devices for handling (message will be instatiated by the component)

COMSIG_MOB_ATTACKED_PRE

At the beginning of when an attackresults datum is being set up

COMSIG_MOB_DEATH

When a mob dies

COMSIG_MOB_FAKE_DEATH

When a mob fakes death

COMSIG_MOB_GEIGER_TICK

sent when radiation status ticks on mob (stage)

COMSIG_MOB_LOGIN

When a client logs into a mob

COMSIG_MOB_LOGOUT

When a client logs out of a mob

COMSIG_MOB_PROP_INVISIBILITY

When invisibility of a mob gets updated (old_value)

COMSIG_MOB_THROW_ITEM

sent when a mob throws something (target, params)

COMSIG_MOUSEUP

on mouseup

COMSIG_MOVABLE_MOVED

when an AM moves (thing, previous_loc, direction)

COMSIG_MOVABLE_SET_LOC

when an AM moves (thing, previous_loc)

COMSIG_MOVABLE_THROW_END

when an AM ends throw (thing, /datum/thrown_thing)

COMSIG_PARENT_PRE_DISPOSING

just before a datum's disposing()

COMSIG_PROJ_COLLIDE

After a projectile makes a valid hit on an atom (after immunity/other early returns, before other effects)

COMSIG_TOOLTIP_BLOCKING_APPEND

Append to the end of the blocking section of tooltip (list/tooltip)

COMSIG_UNARMED_BLOCK_BEGIN

After an unarmed block is set up

COMSIG_UNARMED_BLOCK_END

When an item block is created

COMSIG_UPDATE_ICON

when something happens that should trigger an icon update. Or something.

SEND_GLOBAL_SIGNAL

target to use for signals that are global and not tied to a single datum.

Note that this does NOT work with SEND_SIGNAL because of preprocessor weirdness. Use SEND_GLOBAL_SIGNAL instead.

SEND_SIGNAL

Used to trigger signals and call procs registered for that signal The datum hosting the signal is automaticaly added as the first argument Returns a bitfield gathered from all registered procs Arguments given here are packaged in a list and given to _SendSignal

_COMSIG_MECHCOMP_COMPATIBLE

Returns 1

_COMSIG_MECHCOMP_DISPATCH_ADD_FILTER

Add a filtered connection, getting user input on the filter

_COMSIG_MECHCOMP_DISPATCH_RM_OUTGOING

Remove a filtered connection

_COMSIG_MECHCOMP_DISPATCH_VALIDATE

Test a signal to be sent to a connection

_COMSIG_MECHCOMP_DROPCONNECT

Begin to connect two mechcomp devices together

_COMSIG_MECHCOMP_GET_INCOMING

Return the component's incoming connections

_COMSIG_MECHCOMP_GET_OUTGOING

Return the component's outgoing connections

Connect one MechComp compatible device as a receiver to a trigger. (This is meant to be a private method)

_COMSIG_MECHCOMP_RECEIVE_MSG

Receiving a message from a mechcomp device for handling

_COMSIG_MECHCOMP_RM_INCOMING

Remove {the caller} from the list of transmitting devices

_COMSIG_MECHCOMP_RM_OUTGOING

Remove {the caller} from the list of receiving devices