Space Station 13 - Baystation 12 - Modules - TypesVar Details - Proc Details

mob

Vars

logout_timeInteger or null. Stores the world.time value at the time of Logout(). If null, the mob is either considered logged in or has never logged out.
renderersRenderers on /mob We attach renderers to mobs for their lifespan. Only mobs with clients get renderers, and they are removed again when the mob loses its client. Mobs get their own unique renderer instances but it would not be inconceivable to share them globally. The list of renderers associated with this mob.

Procs

AltClickOnCalled when the mob alt+clicks on an atom. By default, this calls the targeted atom's on_click/alt extension's on_click() proc, or the atom's AltClick() proc.
CreateRenderersCreates the mob's renderers on /Login()
CtrlAltClickOnCalled when the mob ctrl+alt+clicks on an atom. By default, this calls the atom's CtrlAltClick() proc or calls the mob's pointed() proc.
CtrlClickOnCalled when the mob ctrl+clicks on an atom. By default, this calls the targeted atom's CtrlClick() proc.
CtrlShiftClickOnCalled when the mob ctrl+shift+clicks on an atom. By default, calls the atom's CtrlShiftClick() proc.
GetAllHeldFetches all held items of the given path.
HandsEmptyWhether or not the mob's hands or other holding slots are empty. Returns boolean.
HasFreeHandWhether or not the mob has any free hands/holding slots.
IsHoldingChecks if a given item or path is in any of the mob's hands or other holding slots.
MiddleClickOnCalled when a mob middle-clicks on an object. By default, this is used only as a hotkey to call swap_hand().
RangedAttackCalled when a mob attmepts to interact with an object that it is not adjacent to. For complex mobs, this includes interacting with an empty hand or empty module.
RemoveRenderersRemoves the mob's renderers on /Logout()
RestrainedClickOnCalled when a mob attempts to interact with an atom while handcuffed or otherwise restrained. Not currently used.
ShiftClickOnCalled when the mob shift+clicks on an atom. By default, this calls the targeted atom's ShiftClick() proc.
ShowMemoriesVerbs
UnarmedAttackCalled when the mob interacts with something it is adjacent to. For complex mobs, this includes interacting with an empty hand or empty module. Generally, this translates to attack_hand(), attack_robot(), etc.
add_to_living_mob_listLife Handling
attack_empty_handCalled when a mob attempts to use an empty hand on itself.
direct_machine_interfaceWhether or not the mob can directly interact with the machine regardless of screen and input status. Checked in CanUseTopic().
drop_itemDrops the item in our active hand. TODO: rename this to drop_active_hand or something Make sure you are ABSOLUTELY CERTAIN you need to drop this and ignore unequip checks (For example, grabs can be "dropped" but only willingly) Else use unequip_item
equip_to_appropriate_slotPlace I into the first slot it fits in the order of slots_by_priority, returning the slot or falsy.
equip_to_slotUNSAFELY place I into this mob's inventory at slot if existentially possible. Generally, use the _if_possible version.
equip_to_slot_if_possibleAttempt to place I into this mob's inventory at slot. See TRYEQUIP_* flags for behavior modifiers.
get_attack_speedUsed to get how fast a mob should attack, and influences click delay. This is just for inheritance.
has_danger_grabChecks if the target has a grab from the user
isEquippedReturns truthy when item is in the mobs inventory slots, or in slot if specified.
is_speciesDetermine if the mob is the supplied species by text name, species path, or species instance name
set_see_in_darkSee In Dark Set Handling
set_see_invisibleSee Invisible Set Handling
set_sightSight Set Handling

Var Details

logout_time

Integer or null. Stores the world.time value at the time of Logout(). If null, the mob is either considered logged in or has never logged out.

renderers

Renderers on /mob We attach renderers to mobs for their lifespan. Only mobs with clients get renderers, and they are removed again when the mob loses its client. Mobs get their own unique renderer instances but it would not be inconceivable to share them globally. The list of renderers associated with this mob.

Proc Details

AltClickOn

Called when the mob alt+clicks on an atom. By default, this calls the targeted atom's on_click/alt extension's on_click() proc, or the atom's AltClick() proc.

Parameters:

CreateRenderers

Creates the mob's renderers on /Login()

CtrlAltClickOn

Called when the mob ctrl+alt+clicks on an atom. By default, this calls the atom's CtrlAltClick() proc or calls the mob's pointed() proc.

Parameters:

CtrlClickOn

Called when the mob ctrl+clicks on an atom. By default, this calls the targeted atom's CtrlClick() proc.

Parameters:

Returns boolean - Whether or not the action was handled.

CtrlShiftClickOn

Called when the mob ctrl+shift+clicks on an atom. By default, calls the atom's CtrlShiftClick() proc.

Parameters:

GetAllHeld

Fetches all held items of the given path.

If not passed any parameters, will simply fetch all held items.

Parameters:

Returns list of found instances, or null.

HandsEmpty

Whether or not the mob's hands or other holding slots are empty. Returns boolean.

HasFreeHand

Whether or not the mob has any free hands/holding slots.

IsHolding

Checks if a given item or path is in any of the mob's hands or other holding slots.

Parameters:

Returns instance of /obj/item or null. the item found in the mob's hands.

MiddleClickOn

Called when a mob middle-clicks on an object. By default, this is used only as a hotkey to call swap_hand().

Parameters:

RangedAttack

Called when a mob attmepts to interact with an object that it is not adjacent to. For complex mobs, this includes interacting with an empty hand or empty module.

Exception: Telekinesis will call UnarmedAttack([target], 0) instead.

Parameters:

Returns boolean - Whether or not the mob was able to perform the interaction.

RemoveRenderers

Removes the mob's renderers on /Logout()

RestrainedClickOn

Called when a mob attempts to interact with an atom while handcuffed or otherwise restrained. Not currently used.

Parameters:

ShiftClickOn

Called when the mob shift+clicks on an atom. By default, this calls the targeted atom's ShiftClick() proc.

Parameters:

ShowMemories

Verbs

UnarmedAttack

Called when the mob interacts with something it is adjacent to. For complex mobs, this includes interacting with an empty hand or empty module. Generally, this translates to attack_hand(), attack_robot(), etc.

Exception: This is also called when telekinesis is used, even if not adjacent to the target.

Parameters:

Returns boolean - Whether or not the mob was able to perform the interaction.

add_to_living_mob_list

Life Handling

attack_empty_hand

Called when a mob attempts to use an empty hand on itself.

Parameters:

direct_machine_interface

Whether or not the mob can directly interact with the machine regardless of screen and input status. Checked in CanUseTopic().

drop_item

Drops the item in our active hand. TODO: rename this to drop_active_hand or something Make sure you are ABSOLUTELY CERTAIN you need to drop this and ignore unequip checks (For example, grabs can be "dropped" but only willingly) Else use unequip_item

equip_to_appropriate_slot

Place I into the first slot it fits in the order of slots_by_priority, returning the slot or falsy.

equip_to_slot

UNSAFELY place I into this mob's inventory at slot if existentially possible. Generally, use the _if_possible version.

equip_to_slot_if_possible

Attempt to place I into this mob's inventory at slot. See TRYEQUIP_* flags for behavior modifiers.

get_attack_speed

Used to get how fast a mob should attack, and influences click delay. This is just for inheritance.

Parameters:

Returns a number indicating the determined attack cooldown/speed.

has_danger_grab

Checks if the target has a grab from the user

isEquipped

Returns truthy when item is in the mobs inventory slots, or in slot if specified.

is_species

Determine if the mob is the supplied species by text name, species path, or species instance name

set_see_in_dark

See In Dark Set Handling

set_see_invisible

See Invisible Set Handling

set_sight

Sight Set Handling