diff --git a/code/datums/components/fullauto.dm b/code/datums/components/fullauto.dm index 4495a271a3f..6b6aef7a7a1 100644 --- a/code/datums/components/fullauto.dm +++ b/code/datums/components/fullauto.dm @@ -240,7 +240,7 @@ // Gun procs. /obj/item/gun/proc/on_autofire_start(mob/living/shooter) - if(semicd || shooter.stat || !can_trigger_gun(shooter)) + if(semicd || shooter.incapacitated() || !can_trigger_gun(shooter)) return FALSE if(!can_shoot()) shoot_with_empty_chamber(shooter) @@ -260,7 +260,7 @@ /obj/item/gun/proc/do_autofire(datum/source, atom/target, mob/living/shooter, params) SIGNAL_HANDLER - if(semicd || shooter.stat) + if(semicd || shooter.incapacitated()) return NONE if(!can_shoot()) shoot_with_empty_chamber(shooter) diff --git a/modular_skyrat/master_files/code/datums/components/fullauto.dm b/modular_skyrat/master_files/code/datums/components/fullauto.dm index 63240755cef..8617ae64c54 100644 --- a/modular_skyrat/master_files/code/datums/components/fullauto.dm +++ b/modular_skyrat/master_files/code/datums/components/fullauto.dm @@ -249,7 +249,7 @@ // Gun procs. /obj/item/gun/proc/on_autofire_start(mob/living/shooter) - if(!can_shoot(shooter) || !can_trigger_gun(shooter) || semicd) + if(!can_shoot(shooter) || !can_trigger_gun(shooter) || shooter.incapacitated() || semicd) return FALSE var/obj/item/bodypart/other_hand = shooter.has_hand_for_held_index(shooter.get_inactive_hand_index()) if(weapon_weight == WEAPON_HEAVY && (shooter.get_inactive_held_item() || !other_hand)) @@ -264,12 +264,14 @@ return COMPONENT_AUTOFIRE_ONMOUSEDOWN_BYPASS /obj/item/gun/proc/do_autofire(datum/source, atom/target, mob/living/shooter, params) - SIGNAL_HANDLER - if(!can_shoot()) - shoot_with_empty_chamber(shooter) - return FALSE - INVOKE_ASYNC(src, .proc/do_autofire_shot, source, target, shooter, params) - return COMPONENT_AUTOFIRE_SHOT_SUCCESS + SIGNAL_HANDLER + if(shooter.incapacitated()) + return FALSE + if(!can_shoot()) + shoot_with_empty_chamber(shooter) + return FALSE + INVOKE_ASYNC(src, .proc/do_autofire_shot, source, target, shooter, params) + return COMPONENT_AUTOFIRE_SHOT_SUCCESS /obj/item/gun/proc/do_autofire_shot(datum/source, atom/target, mob/living/shooter, params) var/obj/item/gun/akimbo_gun = shooter.get_inactive_held_item()