[MIRROR] Tesla Corona Analyzers (#5726)
* Tesla Corona Analyzers (#35965) * Tesla Corona Analyzers Generate points to make up for no bomb production on maps like Pubby * Silly me, not Aurora, but Corona * Adds sprites to the new mode * new sprites! credit to... me! * Further sprite tweaks. * Tesla Corona Analyzers
This commit is contained in:
committed by
Poojawa
parent
ef864d109b
commit
a53e395606
@@ -515,10 +515,53 @@
|
||||
def_components = list(/obj/item/stock_parts/cell = /obj/item/stock_parts/cell/high/empty)
|
||||
|
||||
/obj/item/circuitboard/machine/tesla_coil
|
||||
name = "Tesla Coil (Machine Board)"
|
||||
name = "Tesla Controller (Machine Board)"
|
||||
desc = "You can use a screwdriver to switch between Research and Power Generation"
|
||||
build_path = /obj/machinery/power/tesla_coil
|
||||
req_components = list(/obj/item/stock_parts/capacitor = 1)
|
||||
|
||||
#define PATH_POWERCOIL /obj/item/circuitboard/machine/tesla_coil/power
|
||||
#define PATH_RPCOIL /obj/item/circuitboard/machine/tesla_coil/research
|
||||
|
||||
/obj/item/circuitboard/machine/tesla_coil/Initialize()
|
||||
. = ..()
|
||||
if(!build_path)
|
||||
if(prob(50))
|
||||
name = "Tesla Coil (Machine Board)"
|
||||
build_path = PATH_POWERCOIL
|
||||
else
|
||||
name = "Tesla Corona Researcher (Machine Board)"
|
||||
build_path = PATH_RPCOIL
|
||||
|
||||
/obj/item/circuitboard/machine/tesla_coil/attackby(obj/item/I, mob/user, params)
|
||||
if(istype(I, /obj/item/screwdriver))
|
||||
var/obj/item/circuitboard/new_type
|
||||
var/new_setting
|
||||
switch(build_path)
|
||||
if(PATH_POWERCOIL)
|
||||
new_type = /obj/item/circuitboard/machine/tesla_coil/research
|
||||
new_setting = "Research"
|
||||
if(PATH_RPCOIL)
|
||||
new_type = /obj/item/circuitboard/machine/tesla_coil/power
|
||||
new_setting = "Power"
|
||||
name = initial(new_type.name)
|
||||
build_path = initial(new_type.build_path)
|
||||
I.play_tool_sound(src)
|
||||
to_chat(user, "<span class='notice'>You change the circuitboard setting to \"[new_setting]\".</span>")
|
||||
else
|
||||
return ..()
|
||||
|
||||
/obj/item/circuitboard/machine/tesla_coil/power
|
||||
name = "Tesla Coil (Machine Board)"
|
||||
build_path = PATH_POWERCOIL
|
||||
|
||||
/obj/item/circuitboard/machine/tesla_coil/research
|
||||
name = "Tesla Corona Researcher (Machine Board)"
|
||||
build_path = PATH_RPCOIL
|
||||
|
||||
#undef PATH_POWERCOIL
|
||||
#undef PATH_RPCOIL
|
||||
|
||||
/obj/item/circuitboard/machine/grounding_rod
|
||||
name = "Grounding Rod (Machine Board)"
|
||||
build_path = /obj/machinery/power/grounding_rod
|
||||
|
||||
Reference in New Issue
Block a user