From 094ca894efd59ad68431a35b3ff7757f8e2c49f4 Mon Sep 17 00:00:00 2001
From: FloFluoro <3611705+FloFluoro@users.noreply.github.com>
Date: Sun, 2 Oct 2022 23:13:36 -0400
Subject: [PATCH] Having a facehugger on your face muffles your speech (#19145)
* Having a facehugger on your face muffles your speech
* Scoped to living
* Yes.
---
code/game/dna/mutations/disabilities.dm | 4 ++--
code/modules/mob/living/carbon/carbon.dm | 7 +++++++
code/modules/mob/living/living.dm | 3 +++
code/modules/mob/living/say.dm | 8 ++++++++
code/modules/mob/mob.dm | 2 +-
5 files changed, 21 insertions(+), 3 deletions(-)
diff --git a/code/game/dna/mutations/disabilities.dm b/code/game/dna/mutations/disabilities.dm
index 8eb704bd590..e590b393824 100644
--- a/code/game/dna/mutations/disabilities.dm
+++ b/code/game/dna/mutations/disabilities.dm
@@ -393,7 +393,7 @@
..()
block = GLOB.swedeblock
-/datum/mutation/disability/speech/swedish/on_say(mob/M, message)
+/datum/mutation/disability/speech/swedish/on_say(mob/living/M, message)
// svedish
message = replacetextEx(message,"W","V")
message = replacetextEx(message,"w","v")
@@ -406,7 +406,7 @@
message = replacetextEx(message,"bo","bjo")
message = replacetextEx(message,"O",pick("Ö","Ø","O"))
message = replacetextEx(message,"o",pick("ö","ø","o"))
- if(prob(30) && !M.is_muzzled())
+ if(prob(30) && !M.is_muzzled() && !M.is_facehugged())
message += " Bork[pick("",", bork",", bork, bork")]!"
return message
diff --git a/code/modules/mob/living/carbon/carbon.dm b/code/modules/mob/living/carbon/carbon.dm
index f1e5352b76b..f0e19783ce7 100644
--- a/code/modules/mob/living/carbon/carbon.dm
+++ b/code/modules/mob/living/carbon/carbon.dm
@@ -94,6 +94,10 @@
if(message)
to_chat(src, "The muzzle prevents you from vomiting!")
return FALSE
+ if(is_facehugged())
+ if(message)
+ to_chat(src, "You try to throw up, but the alien's proboscis obstructs your throat!") //Sorry
+ return FALSE
if(stun)
Stun(8 SECONDS)
if(nutrition < 100 && !blood)
@@ -848,6 +852,9 @@ GLOBAL_LIST_INIT(ventcrawl_machinery, list(/obj/machinery/atmospherics/unary/ven
/mob/living/carbon/is_muzzled()
return(istype(wear_mask, /obj/item/clothing/mask/muzzle))
+/mob/living/carbon/is_facehugged()
+ return istype(wear_mask, /obj/item/clothing/mask/facehugger)
+
/mob/living/carbon/resist_buckle()
INVOKE_ASYNC(src, .proc/resist_muzzle)
var/obj/item/I = get_restraining_item()
diff --git a/code/modules/mob/living/living.dm b/code/modules/mob/living/living.dm
index 927cbac4bcc..3225c52dfe2 100644
--- a/code/modules/mob/living/living.dm
+++ b/code/modules/mob/living/living.dm
@@ -798,6 +798,9 @@
/mob/living/proc/get_visible_name()
return name
+/mob/living/proc/is_facehugged()
+ return FALSE
+
/mob/living/update_gravity(has_gravity)
if(!SSticker)
return
diff --git a/code/modules/mob/living/say.dm b/code/modules/mob/living/say.dm
index 08dc06167bb..5959bffb525 100644
--- a/code/modules/mob/living/say.dm
+++ b/code/modules/mob/living/say.dm
@@ -174,6 +174,10 @@ GLOBAL_LIST_EMPTY(channel_to_radio_key)
muffledspeech_all(message_pieces)
verb = "mumbles"
+ if(is_facehugged())
+ muffledspeech_all(message_pieces)
+ verb = "gurgles"
+
if(!ignore_speech_problems)
var/list/hsp = handle_speech_problems(message_pieces, verb)
verb = hsp["verb"]
@@ -328,6 +332,10 @@ GLOBAL_LIST_EMPTY(channel_to_radio_key)
to_chat(src, "You're muzzled and cannot speak!")
return
+ if(is_facehugged())
+ to_chat(src, "You can't get a word out with this horrible creature on your face!")
+ return
+
var/message = multilingual_to_message(message_pieces)
say_log += "whisper: [message]"
diff --git a/code/modules/mob/mob.dm b/code/modules/mob/mob.dm
index ab713877922..b79ee84f3e9 100644
--- a/code/modules/mob/mob.dm
+++ b/code/modules/mob/mob.dm
@@ -957,7 +957,7 @@ GLOBAL_LIST_INIT(slot_equipment_priority, list( \
return gender
/mob/proc/is_muzzled()
- return 0
+ return FALSE
/mob/Stat()
..()