Files
Aurora.3/code/modules/clothing/masks/voice.dm
LordFowl 8d436c4a03 Converts all necessary << outputs into the to_chat() macro. (#6076)
This PR will lead us towards the Promised Day, for in its wake there shall be much celebration and ecstasy as this world becomes a world suitable for developer hegemony. The first strike is thusly;

All << is converted into to_chat().
2019-03-10 23:39:03 +02:00

32 lines
1.1 KiB
Plaintext

/obj/item/voice_changer
name = "voice changer"
desc = "A voice scrambling module. If you can see this, report it as a bug on the tracker."
var/voice //If set and item is present in mask/suit, this name will be used for the wearer's speech.
var/active
/obj/item/clothing/mask/gas/voice
name = "gas mask"
desc = "A face-covering mask that can be connected to an air supply. It seems to house some odd electronics."
var/obj/item/voice_changer/changer
origin_tech = list(TECH_ILLEGAL = 4)
/obj/item/clothing/mask/gas/voice/verb/Toggle_Voice_Changer()
set category = "Object"
set src in usr
changer.active = !changer.active
to_chat(usr, "<span class='notice'>You [changer.active ? "enable" : "disable"] the voice-changing module in \the [src].</span>")
/obj/item/clothing/mask/gas/voice/verb/Set_Voice(name as text)
set category = "Object"
set src in usr
var/voice = sanitize(name, MAX_NAME_LEN)
if(!voice || !length(voice)) return
changer.voice = voice
to_chat(usr, "<span class='notice'>You are now mimicking <B>[changer.voice]</B>.</span>")
/obj/item/clothing/mask/gas/voice/Initialize()
. = ..()
changer = new(src)