Anomaly Core Rigging (#19361)

* Funky

* More evil zaps

* fix :)

* This one too
This commit is contained in:
Guti
2026-04-06 01:40:53 -04:00
committed by GitHub
parent ab419c9ce3
commit 2ba9e84702
11 changed files with 212 additions and 20 deletions
+5 -8
View File
@@ -27,16 +27,12 @@
///var used for attack_self chain
var/special_handling = FALSE
COOLDOWN_DECLARE(next_activate)
var/activation_cooldown = 3 SECONDS
/obj/item/assembly/proc/holder_movement()
return
/obj/item/assembly/proc/process_cooldown()
if(cooldown)
return FALSE
cooldown = TRUE
VARSET_IN(src, cooldown, FALSE, 2 SECONDS)
return TRUE
/obj/item/assembly/proc/pulsed(var/radio = 0)
if(holder && (wires & WIRE_RECEIVE))
activate()
@@ -52,8 +48,9 @@
return 1
/obj/item/assembly/proc/activate()
if(!secured || !process_cooldown())
if(QDELETED(src) || !secured || !COOLDOWN_FINISHED(src, next_activate))
return FALSE
COOLDOWN_START(src, next_activate, activation_cooldown)
return TRUE
/obj/item/assembly/proc/toggle_secure()
+1 -1
View File
@@ -97,7 +97,7 @@
return TRUE
/obj/item/assembly/infra/proc/trigger_beam()
if(!process_cooldown())
if(!COOLDOWN_FINISHED(src, next_activate))
return FALSE
pulse(0)
QDEL_LIST_NULL(i_beams) //They will get recreated next process() if the situation is still appropriate
+1 -1
View File
@@ -45,7 +45,7 @@
sense()
/obj/item/assembly/prox_sensor/proc/sense()
if((!holder && !secured) || !scanning || !process_cooldown())
if((!holder && !secured) || !scanning || !COOLDOWN_FINISHED(src, next_activate))
return FALSE
var/turf/mainloc = get_turf(src)
pulse(0)
+4 -1
View File
@@ -22,7 +22,7 @@
set_frequency(frequency)
/obj/item/assembly/signaler/activate()
if(!process_cooldown())
if(!COOLDOWN_FINISHED(src, next_activate))
return FALSE
signal()
return TRUE
@@ -82,6 +82,8 @@
..()
/obj/item/assembly/signaler/proc/signal()
if(!COOLDOWN_FINISHED(src, next_activate))
return FALSE
if(!radio_connection)
return
if(is_jammed(src))
@@ -92,6 +94,7 @@
signal.encryption = code
signal.data["message"] = "ACTIVATE"
radio_connection.post_signal(src, signal)
COOLDOWN_START(src, next_activate, activation_cooldown)
/obj/item/assembly/signaler/pulse(var/radio = 0)
if(is_jammed(src))