Fixes fusion power text to make sense.

This commit is contained in:
Putnam
2020-08-30 02:53:46 -07:00
parent 282f292347
commit 5ba883bfe5
2 changed files with 10 additions and 12 deletions
+8 -10
View File
@@ -462,16 +462,14 @@
else
. = max(0, min(255, 138.5177312231 * log(temp - 10) - 305.0447927307))
/proc/fusionpower2text(power) //used when displaying fusion power on analyzers
switch(power)
if(0 to 5)
return "low"
if(5 to 20)
return "mid"
if(20 to 50)
return "high"
if(50 to INFINITY)
return "super"
/proc/instability2text(instability) //used when displaying fusion power on analyzers
switch(instability)
if(0 to 2)
return "stable, meaning that its heat will always increase."
if(2 to 3)
return "metastable, meaning that its heat tend upwards."
if (3 to INFINITY)
return "unstable, meaning that its heat will tend downwards."
/proc/color2hex(color) //web colors
if(!color)
+2 -2
View File
@@ -732,7 +732,7 @@ GENETICS SCANNER
var/fusion_power = round(cached_scan_results["fusion"], 0.01)
var/tier = fusionpower2text(fusion_power)
to_chat(user, "<span class='boldnotice'>Large amounts of free neutrons detected in the air indicate that a fusion reaction took place.</span>")
to_chat(user, "<span class='notice'>Power of the last fusion reaction: [fusion_power]\n This power indicates it was a [tier]-tier fusion reaction.</span>")
to_chat(user, "<span class='notice'>Instability of the last fusion reaction: [fusion_power]\n This power indicates it was a [tier] reaction.</span>")
return
/obj/item/analyzer/proc/scan_turf(mob/user, turf/location)
@@ -992,4 +992,4 @@ GENETICS SCANNER
#undef SCANMODE_CHEMICAL
#undef SCANMODE_WOUND
#undef SCANNER_CONDENSED
#undef SCANNER_VERBOSE
#undef SCANNER_VERBOSE