From 29fcf2d5aac633302b8446090231c17875e0de5f Mon Sep 17 00:00:00 2001 From: Spirono Date: Sun, 8 Apr 2018 22:59:50 +0100 Subject: [PATCH 1/2] Wrench Supermatter Shard to the ground (#36991) * Temporary concept code for PR I doubt this code is the standard method of doing things, but trying to understand this code is a bit AIDS * Using wrench_act() and default_unfasten_wrench() instead It actually works this time --- code/modules/power/supermatter/supermatter.dm | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/code/modules/power/supermatter/supermatter.dm b/code/modules/power/supermatter/supermatter.dm index 5ed6b84a18..1662316447 100644 --- a/code/modules/power/supermatter/supermatter.dm +++ b/code/modules/power/supermatter/supermatter.dm @@ -137,6 +137,8 @@ GLOBAL_DATUM(main_supermatter_engine, /obj/machinery/power/supermatter_shard) var/datum/looping_sound/supermatter/soundloop + var/moveable = TRUE + /obj/machinery/power/supermatter_shard/Initialize() . = ..() uid = gl_uid++ @@ -549,6 +551,10 @@ GLOBAL_DATUM(main_supermatter_engine, /obj/machinery/power/supermatter_shard) radiation_pulse(src, 150, 4) +/obj/machinery/power/supermatter_shard/wrench_act(mob/user, obj/item/tool) + if (moveable) + default_unfasten_wrench(user, tool, time = 20) + return TRUE /obj/machinery/power/supermatter_shard/CollidedWith(atom/movable/AM) if(isliving(AM)) @@ -610,6 +616,7 @@ GLOBAL_DATUM(main_supermatter_engine, /obj/machinery/power/supermatter_shard) anchored = TRUE gasefficency = 0.15 explosion_power = 35 + moveable = FALSE /obj/machinery/power/supermatter_shard/crystal/engine is_main_engine = TRUE