Fix SM (and some other) follow links (#20554)

* hoopefully fix SM message tracking being really weird

* update some more follow targets

* Apply suggestions from code review

hehe

Co-authored-by: Contrabang <91113370+Contrabang@users.noreply.github.com>

* Cleans up some loose ends, implements for arrivals announcer too

* Changes target to the new deactivated core

---------

Co-authored-by: Contrabang <91113370+Contrabang@users.noreply.github.com>
This commit is contained in:
Luc
2023-03-26 07:17:37 -04:00
committed by GitHub
parent 148d1275c3
commit 6bf5172bec
10 changed files with 17 additions and 7 deletions
+1
View File
@@ -67,6 +67,7 @@
var/area/pet_death_area = get_area(M)
var/obj/item/radio/headset/pet_death_announcer = new /obj/item/radio/headset(src)
pet_death_announcer.follow_target = src
if(istype(pet_death_area, /area/syndicate_mothership) || istype(pet_death_area, /area/shuttle/syndicate_elite))
//give the syndicats a bit of stealth
pet_death_announcer.autosay("[M] has been vandalized in Space!", "[M]'s Death Alarm")
@@ -253,7 +253,7 @@ GLOBAL_LIST_INIT(default_medbay_channels, list(
/obj/item/radio/proc/ToggleReception()
listening = !listening && !(wires.is_cut(WIRE_RADIO_RECEIVER) || wires.is_cut(WIRE_RADIO_SIGNAL))
/obj/item/radio/proc/autosay(message, from, channel, role = "Unknown") //BS12 EDIT
/obj/item/radio/proc/autosay(message, from, channel, role = "Unknown", follow_target_override) //BS12 EDIT
var/datum/radio_frequency/connection = null
if(channel && channels && channels.len > 0)
if(channel == "department")
@@ -295,7 +295,10 @@ GLOBAL_LIST_INIT(default_medbay_channels, list(
else
tcm.source_level = level_name_to_num(MAIN_STATION) // Assume station level if we dont have an actual Z level available to us.
tcm.freq = connection.frequency
tcm.follow_target = follow_target
if(follow_target_override)
tcm.follow_target = follow_target_override
else
tcm.follow_target = follow_target
// Now put that through the stuff
for(var/obj/machinery/tcomms/core/C in GLOB.tcomms_machines)