[MIRROR] Gives engineering cyborgs an item they can use in place of circuits for basic construction (#2875)

* Gives engineering cyborgs an item they can use in place of circuits for basic construction

* fixes
This commit is contained in:
CitadelStationBot
2017-09-22 23:35:54 -05:00
committed by Poojawa
parent eb36f34267
commit a286d0c313
8 changed files with 126 additions and 1 deletions
+29
View File
@@ -546,6 +546,35 @@
to_chat(user, "<span class='notice'>You place the power control board inside the frame.</span>")
qdel(W)
else if(istype(W, /obj/item/device/electroadaptive_pseudocircuit) && opened)
var/obj/item/device/electroadaptive_pseudocircuit/P = W
if(!has_electronics)
if(stat & BROKEN)
to_chat(user, "<span class='warning'>[src]'s frame is too damaged to support a circuit.</span>")
return
if(!P.adapt_circuit(user, 50))
return
user.visible_message("<span class='notice'>[user] fabricates a circuit and places it into [src].</span>", \
"<span class='notice'>You adapt a power control board and click it into place in [src]'s guts.</span>")
has_electronics = TRUE
locked = TRUE
else if(!cell)
if(stat & MAINT)
to_chat(user, "<span class='warning'>There's no connector for a power cell.</span>")
return
if(!P.adapt_circuit(user, 500))
return
var/obj/item/stock_parts/cell/crap/empty/C = new(src)
C.forceMove(src)
cell = C
chargecount = 0
user.visible_message("<span class='notice'>[user] fabricates a weak power cell and places it into [src].</span>", \
"<span class='warning'>Your [P.name] whirrs with strain as you create a weak power cell and place it into [src]!</span>")
update_icon()
else
to_chat(user, "<span class='warning'>[src] has both electronics and a cell.</span>")
return
else if (istype(W, /obj/item/weldingtool) && opened && has_electronics==0 && !terminal)
var/obj/item/weldingtool/WT = W
if (WT.get_fuel() < 3)