item
Vars | |
_base_attack_force | Base force value; generally, the damage output if used one-handed by a medium mob (human) and made of steel. |
---|---|
_cached_attack_force | Tracking var for base attack value with material modifiers, to save recalculating 200 times. |
_hardness_force_factor | How much of our overall damage is influenced by material hardness? |
_thrown_force_multiplier | Multiplier to the base thrown force based on the material per above. |
_weight_force_factor | How much of our overall damage is influenced by material weight? |
_wielded_force_multiplier | Multiplier to total base damage from weapon and material if the weapon is wieldable and held in two hands. |
can_be_twohanded | Vars relating to wielding the item with two or more hands. |
contaminated | Flag for ZAS based contamination (chlorine etc) |
decorations | Assoc list of decoration instances to metadata, ie. decorations[GET_DECL(/decl/item_decoration/inset)] = list("color" = COLOR_RED, "material" = GET_DECL(/decl/material/foo)) |
draw_on_mob_when_equipped | Set to false to skip state checking and never draw an icon on the mob (except when held) |
drop_sound | Sound uses when dropping the item, or when its thrown. |
equip_sound | Sound used when equipping the item into a valid slot |
material_alteration | Will apply the flagged modifications to the object |
name_prefix | Set to prefix name with this string ('woven' for 'woven basket' etc) |
needs_attack_dexterity | What dexterity is required to attack with this item? |
no_attack_log | If it's an item we don't want to log attack_logs with, set this to TRUE |
pickup_sound | Sound uses when picking the item up (into your hands) |
replaced_in_loadout | Used when this item is replaced by a loadout item. If TRUE, loadout places src in wearer's storage. If FALSE, src is deleted. |
slot_flags | This is used to determine on which slots an item can fit. |
watertight | Can this object leak into water sources? |
weapon_can_knock_prone | Can this item knock someone out if used as a weapon? Overridden for natural weapons as a nerf to simplemobs. |
Procs | |
can_be_picked_up | Whether this item can be picked up. Primarily exists to be overridden to prevent, e.g. accessories from being removed by clicking on them while worn. |
can_take_wear_damage | Whether the object will take wear damage when used as a weapon. |
get_reagents_overlay | @params: |
get_striking_material | What material are we using when we hit things? Params: mob/user (the mob striking something with src) atom/target (the atom being struck with src) |
get_tool_property | Returns the property's value for a givent archetype. |
loadout_should_keep | Used to handle equipped icons overwritten by custom loadout. If TRUE, loadout places src in wearer's storage. If FALSE, src is deleted by loadout. |
set_tool_property | Set the property for the given tool archetype to the specified value. |
take_damage | Basic damage handling for items. Returns the amount of damage taken after armor if the item was damaged. |
Var Details
_base_attack_force
Base force value; generally, the damage output if used one-handed by a medium mob (human) and made of steel.
_cached_attack_force
Tracking var for base attack value with material modifiers, to save recalculating 200 times.
_hardness_force_factor
How much of our overall damage is influenced by material hardness?
_thrown_force_multiplier
Multiplier to the base thrown force based on the material per above.
_weight_force_factor
How much of our overall damage is influenced by material weight?
_wielded_force_multiplier
Multiplier to total base damage from weapon and material if the weapon is wieldable and held in two hands.
can_be_twohanded
Vars relating to wielding the item with two or more hands.
contaminated
Flag for ZAS based contamination (chlorine etc)
decorations
Assoc list of decoration instances to metadata, ie. decorations[GET_DECL(/decl/item_decoration/inset)] = list("color" = COLOR_RED, "material" = GET_DECL(/decl/material/foo))
draw_on_mob_when_equipped
Set to false to skip state checking and never draw an icon on the mob (except when held)
drop_sound
Sound uses when dropping the item, or when its thrown.
equip_sound
Sound used when equipping the item into a valid slot
material_alteration
Will apply the flagged modifications to the object
name_prefix
Set to prefix name with this string ('woven' for 'woven basket' etc)
needs_attack_dexterity
What dexterity is required to attack with this item?
no_attack_log
If it's an item we don't want to log attack_logs with, set this to TRUE
pickup_sound
Sound uses when picking the item up (into your hands)
replaced_in_loadout
Used when this item is replaced by a loadout item. If TRUE, loadout places src in wearer's storage. If FALSE, src is deleted.
slot_flags
This is used to determine on which slots an item can fit.
watertight
Can this object leak into water sources?
weapon_can_knock_prone
Can this item knock someone out if used as a weapon? Overridden for natural weapons as a nerf to simplemobs.
Proc Details
can_be_picked_up
Whether this item can be picked up. Primarily exists to be overridden to prevent, e.g. accessories from being removed by clicking on them while worn.
can_take_wear_damage
Whether the object will take wear damage when used as a weapon.
get_reagents_overlay
@params:
- state_prefix as text: if non-null, this string is prepended to the reagent overlay state, typically world/inventory/etc @returns:
- reagent_overlay as /image|null - the overlay image representing the reagents in this object
get_striking_material
What material are we using when we hit things? Params: mob/user (the mob striking something with src) atom/target (the atom being struck with src)
get_tool_property
Returns the property's value for a givent archetype.
loadout_should_keep
Used to handle equipped icons overwritten by custom loadout. If TRUE, loadout places src in wearer's storage. If FALSE, src is deleted by loadout.
set_tool_property
Set the property for the given tool archetype to the specified value.
take_damage
Basic damage handling for items. Returns the amount of damage taken after armor if the item was damaged.