Convert a fuck ton of machines to Initialize() (#2985)

Needs testing, but shouldn't break anything. Also adds Destroy() to the SMES base class.
This commit is contained in:
Lohikar
2017-07-14 20:08:59 +03:00
committed by skull132
parent 12ccc4e7a7
commit b5472e50f4
43 changed files with 104 additions and 116 deletions
+2 -1
View File
@@ -176,7 +176,8 @@ var/obj/machinery/blackbox_recorder/blackbox
// Note: actual logging has been moved to SSfeedback.
//Only one can exist in the world!
/obj/machinery/blackbox_recorder/New()
/obj/machinery/blackbox_recorder/Initialize()
. = ..()
if(blackbox)
if(istype(blackbox,/obj/machinery/blackbox_recorder))
qdel(src)
@@ -15,8 +15,8 @@
active_power_usage = 2000
idle_power_usage = 1000
/obj/machinery/auto_cloner/New()
..()
/obj/machinery/auto_cloner/Initialize()
. = ..()
time_per_spawn = rand(1200,3600)
@@ -20,8 +20,8 @@
var/fail_message
/obj/machinery/replicator/New()
..()
/obj/machinery/replicator/Initialize()
. = ..()
var/list/viables = list(\
/obj/item/roller,\
@@ -30,8 +30,8 @@
var/datum/artifact_effect/secondary_effect
var/being_used = 0
/obj/machinery/artifact/New()
..()
/obj/machinery/artifact/Initialize()
. = ..()
//setup primary effect - these are the main ones (mixed)
var/effecttype = pick(typesof(/datum/artifact_effect) - /datum/artifact_effect)
@@ -7,6 +7,7 @@
icon = 'icons/obj/mining.dmi'
icon_state = "crystal"
/obj/machinery/crystal/New()
/obj/machinery/crystal/Initialize()
. = ..()
if(prob(50))
icon_state = "crystal2"
@@ -15,8 +15,8 @@
var/obj/scanned_object
var/report_num = 0
/obj/machinery/artifact_analyser/New()
..()
/obj/machinery/artifact_analyser/Initialize()
. = ..()
reconnect_scanner()
/obj/machinery/artifact_analyser/proc/reconnect_scanner()
@@ -14,8 +14,8 @@
var/obj/machinery/artifact_scanpad/owned_scanner = null
var/last_process = 0
/obj/machinery/artifact_harvester/New()
..()
/obj/machinery/artifact_harvester/Initialize()
. = ..()
//connect to a nearby scanner pad
owned_scanner = locate(/obj/machinery/artifact_scanpad) in get_step(src, dir)
if(!owned_scanner)
@@ -45,8 +45,8 @@
var/t_left_radspike = 0
var/rad_shield = 0
/obj/machinery/radiocarbon_spectrometer/New()
..()
/obj/machinery/radiocarbon_spectrometer/Initialize()
. = ..()
create_reagents(500)
coolant_reagents_purity["water"] = 0.5
coolant_reagents_purity["icecoffee"] = 0.6
@@ -15,9 +15,9 @@
var/obj/effect/suspension_field/suspension_field
var/list/secured_mobs = list()
/obj/machinery/suspension_gen/New()
src.cell = new/obj/item/weapon/cell/high(src)
..()
/obj/machinery/suspension_gen/Initialize()
. = ..()
cell = new/obj/item/weapon/cell/high(src)
/obj/machinery/suspension_gen/machinery_process()
set background = 1