mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-08-24 05:23:22 +01:00
machinery_process() & auto_use_power efficiency tweaks (#2657)
changes: Machinery now uses machinery_process() instead of process(), allowing machines to be put into SSprocessing-style lists in addition to the machinery list. Automatic power calculations now involve less proc-calls.
This commit is contained in:
@@ -25,7 +25,7 @@ var/global/list/rad_collectors = list()
|
||||
rad_collectors -= src
|
||||
return ..()
|
||||
|
||||
/obj/machinery/power/rad_collector/process()
|
||||
/obj/machinery/power/rad_collector/machinery_process()
|
||||
//so that we don't zero out the meter if the SM is processed first.
|
||||
last_power = last_power_new
|
||||
last_power_new = 0
|
||||
|
||||
@@ -107,7 +107,7 @@
|
||||
src.use_power = 1 */
|
||||
return 1
|
||||
|
||||
/obj/machinery/power/emitter/process()
|
||||
/obj/machinery/power/emitter/machinery_process()
|
||||
if(stat & (BROKEN))
|
||||
return
|
||||
if(src.state != 2 || (!powernet && active_power_usage))
|
||||
|
||||
@@ -58,7 +58,7 @@ field_generator power level display
|
||||
connected_gens = list()
|
||||
return
|
||||
|
||||
/obj/machinery/field_generator/process()
|
||||
/obj/machinery/field_generator/machinery_process()
|
||||
if(Varedit_start == 1)
|
||||
if(active == 0)
|
||||
active = 1
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
var/energy = 0
|
||||
var/creation_type = /obj/singularity
|
||||
|
||||
/obj/machinery/the_singularitygen/process()
|
||||
/obj/machinery/the_singularitygen/machinery_process()
|
||||
var/turf/T = get_turf(src)
|
||||
if(src.energy >= 200)
|
||||
new creation_type(T, 50)
|
||||
|
||||
@@ -149,7 +149,7 @@
|
||||
return
|
||||
|
||||
|
||||
/obj/machinery/particle_accelerator/control_box/process()
|
||||
/obj/machinery/particle_accelerator/control_box/machinery_process()
|
||||
if(src.active)
|
||||
//a part is missing!
|
||||
if( length(connected_parts) < 6 )
|
||||
|
||||
Reference in New Issue
Block a user