Improves Geiger Counters; Allows Toggle (#15366)

* Improves Geiger Counters; Allows Toggle

* no arg

* spelling

* tweaks
This commit is contained in:
Fox McCloud
2021-01-30 23:22:21 +00:00
committed by GitHub
parent 17424b786e
commit 82f1d2ce59
5 changed files with 57 additions and 37 deletions
+8
View File
@@ -369,6 +369,14 @@
return FALSE
return ..()
/datum/action/item_action/toggle_geiger_counter
name = "Toggle Geiger Counter"
/datum/action/item_action/toggle_geiger_counter/Trigger()
var/obj/item/clothing/head/helmet/space/hardsuit/H = target
if(istype(H))
H.toggle_geiger_counter()
/datum/action/item_action/hands_free
check_flags = AB_CHECK_CONSCIOUS
+1 -1
View File
@@ -6,7 +6,7 @@
/datum/element/rad_insulation/Attach(datum/target, _amount = RAD_MEDIUM_INSULATION, protects = TRUE, contamination_proof = TRUE)
. = ..()
if(!isatom(target))
return COMPONENT_INCOMPATIBLE
return ELEMENT_INCOMPATIBLE
if(protects) // Does this protect things in its contents from being affected?
RegisterSignal(target, COMSIG_ATOM_RAD_PROBE, .proc/rad_probe_react)
+2 -2
View File
@@ -4,7 +4,7 @@
/// The center of the wave
var/turf/master_turf
/// How far we've moved
var/steps=0
var/steps = 0
/// How strong it was originaly
var/intensity
/// How much contaminated material it still has
@@ -101,7 +101,7 @@
/datum/radiation_wave/proc/radiate(list/atoms, strength)
var/can_contam = strength >= RAD_MINIMUM_CONTAMINATION
var/contamination_strength = (strength-RAD_MINIMUM_CONTAMINATION) * RAD_CONTAMINATION_STR_COEFFICIENT
var/contamination_strength = (strength - RAD_MINIMUM_CONTAMINATION) * RAD_CONTAMINATION_STR_COEFFICIENT
contamination_strength = max(contamination_strength, RAD_BACKGROUND_RADIATION)
// It'll never reach 100% chance but the further out it gets the more likely it'll contaminate
var/contamination_chance = 100 - (90 / (1 + steps * 0.1))