SM speaks on engineering channel, now with 100% less freeze (#984)
This commit is contained in:
committed by
Poojawa
parent
946013ac22
commit
f2c83f8ced
@@ -48,9 +48,6 @@
|
||||
#define FLUX_ANOMALY "flux_anomaly"
|
||||
#define PYRO_ANOMALY "pyro_anomaly"
|
||||
|
||||
#define SPEAK(message) radio.talk_into(src, message, null, get_spans(), get_default_language())
|
||||
|
||||
|
||||
/obj/machinery/power/supermatter_shard
|
||||
name = "supermatter shard"
|
||||
desc = "A strangely translucent and iridescent crystal that looks like it used to be part of a larger structure."
|
||||
@@ -114,6 +111,9 @@
|
||||
var/config_hallucination_power = 0.1
|
||||
|
||||
var/obj/item/device/radio/radio
|
||||
var/radio_key = /obj/item/device/encryptionkey/headset_eng
|
||||
var/engineering_channel = "Engineering"
|
||||
var/common_channel = null
|
||||
|
||||
//for logging
|
||||
var/has_been_powered = 0
|
||||
@@ -134,7 +134,9 @@
|
||||
countdown.start()
|
||||
GLOB.poi_list |= src
|
||||
radio = new(src)
|
||||
radio.keyslot = new radio_key
|
||||
radio.listening = 0
|
||||
radio.recalculateChannels()
|
||||
investigate_log("has been created.", "supermatter")
|
||||
|
||||
|
||||
@@ -340,27 +342,27 @@
|
||||
var/stability = num2text(round((damage / explosion_point) * 100))
|
||||
|
||||
if(damage > emergency_point)
|
||||
SPEAK("[emergency_alert] Instability: [stability]%")
|
||||
radio.talk_into(src, "[emergency_alert] Instability: [stability]%", common_channel, get_spans(), get_default_language())
|
||||
lastwarning = REALTIMEOFDAY
|
||||
if(!has_reached_emergency)
|
||||
investigate_log("has reached the emergency point for the first time.", "supermatter")
|
||||
message_admins("[src] has reached the emergency point [ADMIN_JMP(src)].")
|
||||
has_reached_emergency = 1
|
||||
else if(damage >= damage_archived) // The damage is still going up
|
||||
SPEAK("[warning_alert] Instability: [stability]%")
|
||||
radio.talk_into(src, "[warning_alert] Instability: [stability]%", engineering_channel, get_spans(), get_default_language())
|
||||
lastwarning = REALTIMEOFDAY - (WARNING_DELAY * 5)
|
||||
|
||||
else // Phew, we're safe
|
||||
SPEAK("[safe_alert] Instability: [stability]%")
|
||||
radio.talk_into(src, "[safe_alert] Instability: [stability]%", engineering_channel, get_spans(), get_default_language())
|
||||
lastwarning = REALTIMEOFDAY
|
||||
|
||||
if(power > POWER_PENALTY_THRESHOLD)
|
||||
SPEAK("Warning: Hyperstructure has reached dangerous power level.")
|
||||
radio.talk_into(src, "Warning: Hyperstructure has reached dangerous power level.", engineering_channel, get_spans(), get_default_language())
|
||||
if(powerloss_inhibitor < 0.5)
|
||||
SPEAK("DANGER: CHARGE INERTIA CHAIN REACTION IN PROGRESS.")
|
||||
radio.talk_into(src, "DANGER: CHARGE INERTIA CHAIN REACTION IN PROGRESS.", engineering_channel, get_spans(), get_default_language())
|
||||
|
||||
if(combined_gas > MOLE_PENALTY_THRESHOLD)
|
||||
SPEAK("Warning: Critical coolant mass reached.")
|
||||
radio.talk_into(src, "Warning: Critical coolant mass reached.", engineering_channel, get_spans(), get_default_language())
|
||||
|
||||
if(damage > explosion_point)
|
||||
for(var/mob in GLOB.living_mob_list)
|
||||
|
||||
Reference in New Issue
Block a user