diff --git a/code/__DEFINES/obj_flags.dm b/code/__DEFINES/obj_flags.dm index 8530bf63cad..5b9553e66fc 100644 --- a/code/__DEFINES/obj_flags.dm +++ b/code/__DEFINES/obj_flags.dm @@ -54,6 +54,8 @@ #define ANTI_TINFOIL_MANEUVER (1<<12) //Hats with negative effects when worn (i.e the tinfoil hat). #define DANGEROUS_OBJECT (1<<13) //Clothes that cause a larger notification when placed on a person. #define LARGE_WORN_ICON (1<<14) //Clothes that use large icons, for applying the proper overlays like blood +/// Clothes that block speech (i.e the muzzle). Can be applied to any clothing piece. +#define BLOCKS_SPEECH (1<<15) /// Flags for the organ_flags var on /obj/item/organ diff --git a/code/_globalvars/bitfields.dm b/code/_globalvars/bitfields.dm index 1f852f2a4ca..e257abed530 100644 --- a/code/_globalvars/bitfields.dm +++ b/code/_globalvars/bitfields.dm @@ -79,6 +79,7 @@ DEFINE_BITFIELD(car_traits, list( DEFINE_BITFIELD(clothing_flags, list( "ANTI_TINFOIL_MANEUVER" = ANTI_TINFOIL_MANEUVER, "BLOCKS_SHOVE_KNOCKDOWN" = BLOCKS_SHOVE_KNOCKDOWN, + "BLOCKS_SPEECH" = BLOCKS_SPEECH, "BLOCK_GAS_SMOKE_EFFECT" = BLOCK_GAS_SMOKE_EFFECT, "LAVAPROTECT" = LAVAPROTECT, "MASKINTERNALS" = MASKINTERNALS, diff --git a/code/game/objects/structures/crates_lockers/closets/secure/medical.dm b/code/game/objects/structures/crates_lockers/closets/secure/medical.dm index 2894c30e242..3921d2d2d9d 100644 --- a/code/game/objects/structures/crates_lockers/closets/secure/medical.dm +++ b/code/game/objects/structures/crates_lockers/closets/secure/medical.dm @@ -28,7 +28,7 @@ for(var/i in 1 to 3) new /obj/item/tank/internals/anesthetic(src) for(var/i in 1 to 3) - new /obj/item/clothing/mask/breath/medical(src) + new /obj/item/clothing/mask/breathmuzzle(src) /obj/structure/closet/secure_closet/medical3 name = "medical doctor's locker" diff --git a/code/modules/clothing/masks/miscellaneous.dm b/code/modules/clothing/masks/miscellaneous.dm index b85f95fce52..162bb5beb96 100644 --- a/code/modules/clothing/masks/miscellaneous.dm +++ b/code/modules/clothing/masks/miscellaneous.dm @@ -3,6 +3,7 @@ desc = "To stop that awful noise." icon_state = "muzzle" inhand_icon_state = "blindfold" + clothing_flags = BLOCKS_SPEECH flags_cover = MASKCOVERSMOUTH w_class = WEIGHT_CLASS_SMALL gas_transfer_coefficient = 0.9 @@ -16,6 +17,25 @@ return ..() +/obj/item/clothing/mask/breathmuzzle + name = "surgery mask" + desc = "To silence those pesky patients before putting them under." + icon_state = "breathmuzzle" + inhand_icon_state = "breathmuzzle" + clothing_flags = MASKINTERNALS | BLOCKS_SPEECH + gas_transfer_coefficient = 0.1 + permeability_coefficient = 0.01 + equip_delay_other = 25 // my sprite has 4 straps, a-la a head harness. takes a while to equip, longer than a muzzle + +/obj/item/clothing/mask/breathmuzzle/attack_paw(mob/user, list/modifiers) + // The breathmuzzle is similar enough to a regular muzzle that similar rules would apply to both. + if(iscarbon(user)) + var/mob/living/carbon/carbon_user = user + if(src == carbon_user.wear_mask) + to_chat(user, "You need help taking this off!") + return + ..() + /obj/item/clothing/mask/surgical name = "sterile mask" desc = "A sterile mask designed to help prevent the spread of diseases." diff --git a/code/modules/mob/living/carbon/carbon.dm b/code/modules/mob/living/carbon/carbon.dm index 31eb21cf8f1..40a4dabc5c5 100644 --- a/code/modules/mob/living/carbon/carbon.dm +++ b/code/modules/mob/living/carbon/carbon.dm @@ -210,7 +210,10 @@ loc.handle_fall(src)//it's loc so it doesn't call the mob's handle_fall which does nothing /mob/living/carbon/is_muzzled() - return(istype(src.wear_mask, /obj/item/clothing/mask/muzzle)) + for (var/obj/item/clothing/clothing in get_equipped_items()) + if(clothing.clothing_flags & BLOCKS_SPEECH) + return TRUE + return FALSE /mob/living/carbon/hallucinating() if(hallucination) diff --git a/icons/mob/clothing/mask.dmi b/icons/mob/clothing/mask.dmi index 66524e6d5c3..aaeff29704a 100644 Binary files a/icons/mob/clothing/mask.dmi and b/icons/mob/clothing/mask.dmi differ diff --git a/icons/mob/inhands/clothing_lefthand.dmi b/icons/mob/inhands/clothing_lefthand.dmi index 1324bc555af..4e83b053a94 100644 Binary files a/icons/mob/inhands/clothing_lefthand.dmi and b/icons/mob/inhands/clothing_lefthand.dmi differ diff --git a/icons/mob/inhands/clothing_righthand.dmi b/icons/mob/inhands/clothing_righthand.dmi index e4445618832..1825c18f727 100644 Binary files a/icons/mob/inhands/clothing_righthand.dmi and b/icons/mob/inhands/clothing_righthand.dmi differ diff --git a/icons/obj/clothing/masks.dmi b/icons/obj/clothing/masks.dmi index b28f808041a..64ccef9d720 100644 Binary files a/icons/obj/clothing/masks.dmi and b/icons/obj/clothing/masks.dmi differ