mirror of
https://github.com/yogstation13/Yogstation.git
synced 2025-02-26 09:04:50 +00:00
* Refactors ear damage into ear organs 🆑 coiax add: Centcom would like to inform all employees that they have ears. add: Adds "ear" organs to all carbons. These organs store ear damage and deafness. A carbon without any ears is deaf. Genetic deafness functions as before. /🆑 - `ear_damage` and `ear_deaf` vars removed from /mob. - All mobs have a `can_hear` proc, which returns TRUE always except for carbons. - Carbons need to have an ear organ that has 0 `deaf` var. - Explanation of how ear damage works is in the code, it hasn't been changed from previously. Deafness is applied in number of Life ticks until you regain hearing, while damage is long team, heals slower, and when high enough, can cause flashbangs to make you go permamently deaf, as before. - Wearing earmuffs halves the healing time of deafness, and promotes healing long term ear damage, as before. Earmuffs now have a secondary flag HEALS_EARS, which currently only they own. * Changes how soundbang deafness works slightly * Ear organ icon * Code review I * Makes fully healing carbons not dependent on having a dna and species * Gives monkeys and aliens ears * Whoops * Split organs into seperate files * Tweaks. * Un-removes brain damage lines * Moved procs onto /mob for ear stuff * Massages things into compiling * Replacement of spam_flag with world.time tracker
61 lines
2.2 KiB
Plaintext
61 lines
2.2 KiB
Plaintext
/proc/priority_announce(text, title = "", sound = 'sound/AI/attention.ogg', type)
|
|
if(!text)
|
|
return
|
|
|
|
var/announcement
|
|
|
|
if(type == "Priority")
|
|
announcement += "<h1 class='alert'>Priority Announcement</h1>"
|
|
if (title && length(title) > 0)
|
|
announcement += "<br><h2 class='alert'>[html_encode(title)]</h2>"
|
|
else if(type == "Captain")
|
|
announcement += "<h1 class='alert'>Captain Announces</h1>"
|
|
GLOB.news_network.SubmitArticle(text, "Captain's Announcement", "Station Announcements", null)
|
|
|
|
else
|
|
announcement += "<h1 class='alert'>[command_name()] Update</h1>"
|
|
if (title && length(title) > 0)
|
|
announcement += "<br><h2 class='alert'>[html_encode(title)]</h2>"
|
|
if(title == "")
|
|
GLOB.news_network.SubmitArticle(text, "Central Command Update", "Station Announcements", null)
|
|
else
|
|
GLOB.news_network.SubmitArticle(title + "<br><br>" + text, "Central Command", "Station Announcements", null)
|
|
|
|
announcement += "<br><span class='alert'>[html_encode(text)]</span><br>"
|
|
announcement += "<br>"
|
|
|
|
for(var/mob/M in GLOB.player_list)
|
|
if(!isnewplayer(M) && M.can_hear())
|
|
to_chat(M, announcement)
|
|
if(M.client.prefs.toggles & SOUND_ANNOUNCEMENTS)
|
|
M << sound(sound)
|
|
|
|
/proc/print_command_report(text = "", title = null, announce=TRUE)
|
|
if(!title)
|
|
title = "Classified [command_name()] Update"
|
|
|
|
if(announce)
|
|
priority_announce("A report has been downloaded and printed out at all communications consoles.", "Incoming Classified Message", 'sound/AI/commandreport.ogg')
|
|
|
|
for(var/obj/machinery/computer/communications/C in GLOB.machines)
|
|
if(!(C.stat & (BROKEN|NOPOWER)) && C.z == ZLEVEL_STATION)
|
|
var/obj/item/weapon/paper/P = new /obj/item/weapon/paper(C.loc)
|
|
P.name = "paper - '[title]'"
|
|
P.info = text
|
|
C.messagetitle.Add("[title]")
|
|
C.messagetext.Add(text)
|
|
P.update_icon()
|
|
|
|
/proc/minor_announce(message, title = "Attention:", alert)
|
|
if(!message)
|
|
return
|
|
|
|
for(var/mob/M in GLOB.player_list)
|
|
if(!isnewplayer(M) && M.can_hear())
|
|
to_chat(M, "<b><font size = 3><font color = red>[title]</font color><BR>[message]</font size></b><BR>")
|
|
if(M.client.prefs.toggles & SOUND_ANNOUNCEMENTS)
|
|
if(alert)
|
|
M << sound('sound/misc/notice1.ogg')
|
|
else
|
|
M << sound('sound/misc/notice2.ogg')
|