Merge pull request #13246 from silicons/anomaly_manufacturing

anomaly manufacturing port from tg. supermatter anomaly generation nerfed to 20% rather than removed
This commit is contained in:
BlackMajor
2020-09-06 17:53:35 +12:00
committed by GitHub
11 changed files with 332 additions and 9 deletions
+10 -4
View File
@@ -17,11 +17,15 @@
var/countdown_colour
var/obj/effect/countdown/anomaly/countdown
/obj/effect/anomaly/Initialize(mapload, new_lifespan)
/// chance we drop a core when neutralized
var/core_drop_chance = 100
/obj/effect/anomaly/Initialize(mapload, new_lifespan, core_drop_chance = 100)
. = ..()
GLOB.poi_list |= src
START_PROCESSING(SSobj, src)
impact_area = get_area(src)
src.core_drop_chance = core_drop_chance
if (!impact_area)
return INITIALIZE_HINT_QDEL
@@ -54,6 +58,8 @@
GLOB.poi_list.Remove(src)
STOP_PROCESSING(SSobj, src)
qdel(countdown)
if(aSignal)
QDEL_NULL(aSignal)
return ..()
/obj/effect/anomaly/proc/anomalyEffect()
@@ -70,12 +76,12 @@
/obj/effect/anomaly/proc/anomalyNeutralize()
new /obj/effect/particle_effect/smoke/bad(loc)
for(var/atom/movable/O in src)
O.forceMove(drop_location())
if(prob(core_drop_chance))
aSignal.forceMove(drop_location())
aSignal = null
qdel(src)
/obj/effect/anomaly/attackby(obj/item/I, mob/user, params)
if(I.tool_behaviour == TOOL_ANALYZER) //revert if runtimed
to_chat(user, "<span class='notice'>Analyzing... [src]'s unstable field is fluctuating along frequency [format_frequency(aSignal.frequency)], code [aSignal.code].</span>")
@@ -1146,3 +1146,8 @@
build_path = /obj/machinery/atmospherics/components/unary/shuttle/heater
req_components = list(/obj/item/stock_parts/micro_laser = 2,
/obj/item/stock_parts/matter_bin = 1)
/obj/item/circuitboard/machine/explosive_compressor
name = "Explosive Compressor (Machine Board)"
build_path = /obj/machinery/research/explosive_compressor
req_components = list(/obj/item/stock_parts/matter_bin = 3)
@@ -289,3 +289,9 @@
. = TRUE
update_icon()
/**
* Returns if this is ready to be detonated. Checks if both tanks are in place.
*/
/obj/item/transfer_valve/proc/ready()
return tank_one && tank_two