mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-22 12:41:09 +01:00
[MIRROR] Cleans up signal use in bitrunning [NO GBP] [MDB IGNORE] (#24738)
* Cleans up signal use in bitrunning [NO GBP] * Update avatar_connection.dm --------- Co-authored-by: Jeremiah <42397676+jlsnow301@users.noreply.github.com> Co-authored-by: Bloop <13398309+vinylspiders@users.noreply.github.com>
This commit is contained in:
co-authored by
Jeremiah
Bloop
parent
347d9f9f0e
commit
8495b00be9
@@ -7,19 +7,6 @@
|
||||
update_appearance()
|
||||
radio.talk_into(src, "Thermal systems within operational parameters. Proceeding to domain configuration.", RADIO_CHANNEL_SUPPLY)
|
||||
|
||||
/// Attempts to connect to a quantum console
|
||||
/obj/machinery/quantum_server/proc/find_console()
|
||||
var/obj/machinery/computer/quantum_console/console = console_ref?.resolve()
|
||||
if(console)
|
||||
return console
|
||||
|
||||
for(var/direction in GLOB.cardinals)
|
||||
var/obj/machinery/computer/quantum_console/nearby_console = locate(/obj/machinery/computer/quantum_console, get_step(src, direction))
|
||||
if(nearby_console)
|
||||
console_ref = WEAKREF(nearby_console)
|
||||
nearby_console.server_ref = WEAKREF(src)
|
||||
return nearby_console
|
||||
|
||||
/// Compiles a list of available domains.
|
||||
/obj/machinery/quantum_server/proc/get_available_domains()
|
||||
var/list/levels = list()
|
||||
@@ -91,6 +78,15 @@
|
||||
domain_randomized = TRUE
|
||||
return available["id"]
|
||||
|
||||
/// Locates any turfs with forges on them, returns a random one
|
||||
/obj/machinery/quantum_server/proc/get_random_nearby_forge()
|
||||
var/list/nearby_forges = list()
|
||||
|
||||
for(var/obj/machinery/byteforge/forge in oview(MAX_DISTANCE, src))
|
||||
nearby_forges += forge
|
||||
|
||||
return pick(nearby_forges)
|
||||
|
||||
/// Gets all mobs originally generated by the loaded domain and returns a list that are capable of being antagged
|
||||
/obj/machinery/quantum_server/proc/get_valid_domain_targets()
|
||||
// A: No one is playing
|
||||
@@ -116,20 +112,12 @@
|
||||
|
||||
return nearby_forges
|
||||
|
||||
/// Finds any mobs with minds in the zones and gives them the bad news
|
||||
/obj/machinery/quantum_server/proc/notify_spawned_threats()
|
||||
for(var/datum/weakref/baddie_ref as anything in spawned_threat_refs)
|
||||
var/mob/living/baddie = baddie_ref.resolve()
|
||||
if(isnull(baddie) || baddie.stat >= UNCONSCIOUS || isnull(baddie.mind))
|
||||
continue
|
||||
/// Severs any connected users
|
||||
/obj/machinery/quantum_server/proc/sever_connections()
|
||||
if(isnull(generated_domain) || !length(avatar_connection_refs))
|
||||
return
|
||||
|
||||
baddie.throw_alert(
|
||||
ALERT_BITRUNNER_RESET,
|
||||
/atom/movable/screen/alert/bitrunning/qserver_threat_deletion,
|
||||
new_master = src,
|
||||
)
|
||||
|
||||
to_chat(baddie, span_userdanger("You have been flagged for deletion! Thank you for your service."))
|
||||
SEND_SIGNAL(src, COMSIG_BITRUNNER_QSRV_SEVER)
|
||||
|
||||
/// Do some magic teleport sparks
|
||||
/obj/machinery/quantum_server/proc/spark_at_location(obj/cache)
|
||||
|
||||
Reference in New Issue
Block a user