mirror of
https://github.com/PolarisSS13/Polaris.git
synced 2026-08-25 22:28:00 +01:00
Modern Modular Computers
This commit is contained in:
@@ -90,6 +90,10 @@
|
||||
|
||||
var/datum/looping_sound/supermatter/soundloop
|
||||
|
||||
/obj/machinery/power/supermatter/New()
|
||||
..()
|
||||
uid = gl_uid++
|
||||
|
||||
/obj/machinery/power/supermatter/Initialize()
|
||||
soundloop = new(list(src), TRUE)
|
||||
return ..()
|
||||
@@ -98,6 +102,34 @@
|
||||
QDEL_NULL(soundloop)
|
||||
return ..()
|
||||
|
||||
/obj/machinery/power/supermatter/proc/get_status()
|
||||
var/turf/T = get_turf(src)
|
||||
if(!T)
|
||||
return SUPERMATTER_ERROR
|
||||
var/datum/gas_mixture/air = T.return_air()
|
||||
if(!air)
|
||||
return SUPERMATTER_ERROR
|
||||
|
||||
if(grav_pulling || exploded)
|
||||
return SUPERMATTER_DELAMINATING
|
||||
|
||||
if(get_integrity() < 25)
|
||||
return SUPERMATTER_EMERGENCY
|
||||
|
||||
if(get_integrity() < 50)
|
||||
return SUPERMATTER_DANGER
|
||||
|
||||
if((get_integrity() < 100) || (air.temperature > CRITICAL_TEMPERATURE))
|
||||
return SUPERMATTER_WARNING
|
||||
|
||||
if(air.temperature > (CRITICAL_TEMPERATURE * 0.8))
|
||||
return SUPERMATTER_NOTIFY
|
||||
|
||||
if(power > 5)
|
||||
return SUPERMATTER_NORMAL
|
||||
return SUPERMATTER_INACTIVE
|
||||
|
||||
|
||||
/obj/machinery/power/supermatter/proc/explode()
|
||||
message_admins("Supermatter exploded at ([x],[y],[z] - <A HREF='?_src_=holder;adminplayerobservecoodjump=1;X=[x];Y=[y];Z=[z]'>JMP</a>)",0,1)
|
||||
log_game("SUPERMATTER([x],[y],[z]) Exploded. Power:[power], Oxygen:[oxygen], Damage:[damage], Integrity:[get_integrity()]")
|
||||
|
||||
Reference in New Issue
Block a user