grenade
Base class for all grenades.
Vars | |
active | Is this grenade currently armed? |
---|---|
clumsy_check | Used in botch_check to determine how a user's clumsiness affects that user's ability to prime a grenade correctly. |
det_time | How long it takes for a grenade to explode after being armed |
display_timer | Will this state what its det_time is when examined? |
dud_flags | Bitfields which prevent the grenade from detonating if set. Includes (GRENADE_DUD|GRENADE_USED) |
ex_dev | how big of a devastation explosion radius on prime |
ex_flame | how big of a flame explosion radius on prime |
ex_heavy | how big of a heavy explosion radius on prime |
ex_light | how big of a light explosion radius on prime |
possible_fuse_time | Possible timers that can be assigned for detonation. Values are strings in SECONDS |
shrapnel_initialized | Did we add the component responsible for spawning shrapnel to this? |
shrapnel_radius | the higher this number, the more projectiles are created as shrapnel |
shrapnel_type | if set, will spew out projectiles of this type |
sticky | Was sticky tape used to make this sticky? |
type_cluster | Is it a cluster grenade? We don't wanna spam admin logs with these. |
Procs | |
arm_grenade | arm_grenade (formerly preprime) refers to when a grenade with a standard time fuze is activated, making it go beepbeepbeep and then detonate a few seconds later. Grenades with other triggers like remote igniters probably skip this step and go straight to /obj/item/grenade/proc/detonate |
botch_check | Checks for various ways to botch priming a grenade. |
change_det_time | Sets det_time to a number in SECONDS |
detonate | detonate (formerly prime) refers to when the grenade actually delivers its payload (whether or not a boom/bang/detonation is involved) |
ingredient_detonation | Signal sent by someone eating food this is an ingredient in "used_in". Makes the grenade go kerblooey, destroying the food. |
on_used_as_ingredient | Signal sent by someone putting the grenade in as an ingredient. Registers signals onto what it was put into so it can explode. |
Var Details
active
Is this grenade currently armed?
clumsy_check
Used in botch_check to determine how a user's clumsiness affects that user's ability to prime a grenade correctly.
det_time
How long it takes for a grenade to explode after being armed
display_timer
Will this state what its det_time is when examined?
dud_flags
Bitfields which prevent the grenade from detonating if set. Includes (GRENADE_DUD|GRENADE_USED)
ex_dev
how big of a devastation explosion radius on prime
ex_flame
how big of a flame explosion radius on prime
ex_heavy
how big of a heavy explosion radius on prime
ex_light
how big of a light explosion radius on prime
possible_fuse_time
Possible timers that can be assigned for detonation. Values are strings in SECONDS
shrapnel_initialized
Did we add the component responsible for spawning shrapnel to this?
shrapnel_radius
the higher this number, the more projectiles are created as shrapnel
shrapnel_type
if set, will spew out projectiles of this type
sticky
Was sticky tape used to make this sticky?
type_cluster
Is it a cluster grenade? We don't wanna spam admin logs with these.
Proc Details
arm_grenade
arm_grenade (formerly preprime) refers to when a grenade with a standard time fuze is activated, making it go beepbeepbeep and then detonate a few seconds later. Grenades with other triggers like remote igniters probably skip this step and go straight to /obj/item/grenade/proc/detonate
botch_check
Checks for various ways to botch priming a grenade.
Arguments:
- mob/living/carbon/human/user - who is priming our grenade?
change_det_time
Sets det_time to a number in SECONDS
if time is passed as an argument, det_time
will be time SECONDS
Cycles the duration of the fuse of the grenade det_time
based on the options provided in list/possible_fuse_time
detonate
detonate (formerly prime) refers to when the grenade actually delivers its payload (whether or not a boom/bang/detonation is involved)
Arguments:
- lanced_by- If this grenade was detonated by an elance, we need to pass that along with the COMSIG_GRENADE_DETONATE signal for pellet clouds
ingredient_detonation
Signal sent by someone eating food this is an ingredient in "used_in". Makes the grenade go kerblooey, destroying the food.
on_used_as_ingredient
Signal sent by someone putting the grenade in as an ingredient. Registers signals onto what it was put into so it can explode.