Adds examine tips to firedoor construction/deconstruction
This commit is contained in:
@@ -30,6 +30,19 @@
|
||||
..()
|
||||
CalculateAffectingAreas()
|
||||
|
||||
/obj/machinery/door/firedoor/examine(mob/user)
|
||||
..()
|
||||
if(!density)
|
||||
to_chat(user, "<span class='notice'>It is open, but could be <b>pried</b> closed.</span>")
|
||||
else
|
||||
if(!welded)
|
||||
to_chat(user, "<span class='notice'>It is closed, but could be <i>pried</i> open. Deconstruction would require it to be <b>welded</b> shut.</span>")
|
||||
else
|
||||
if(boltslocked)
|
||||
to_chat(user, "<span class='notice'>It is <i>welded</i> shut. The floor bolt have been locked by <b>screws</b>.</span>")
|
||||
else
|
||||
to_chat(user, "<span class='notice'>The bolt locks have been <i>unscrewed</i>, but the bolts themselves are still <b>wrenched</b> to the floor.</span>")
|
||||
|
||||
/obj/machinery/door/firedoor/proc/CalculateAffectingAreas()
|
||||
remove_from_areas()
|
||||
affecting_areas = get_adjacent_open_areas(src) | get_area(src)
|
||||
@@ -64,7 +77,6 @@
|
||||
latetoggle()
|
||||
else
|
||||
stat |= NOPOWER
|
||||
return
|
||||
|
||||
/obj/machinery/door/firedoor/attack_hand(mob/user)
|
||||
if(operating || !density)
|
||||
@@ -96,8 +108,8 @@
|
||||
deconstruct(TRUE)
|
||||
return
|
||||
if(istype(C, /obj/item/weapon/screwdriver))
|
||||
user.visible_message("<span class='notice'>[user] [boltslocked ? "unlocks" : "locks"] [src]'s bolts...</span>", \
|
||||
"<span class='notice'>You [boltslocked ? "unlock" : "lock"] [src]'s floor bolts...</span>")
|
||||
user.visible_message("<span class='notice'>[user] [boltslocked ? "unlocks" : "locks"] [src]'s bolts.</span>", \
|
||||
"<span class='notice'>You [boltslocked ? "unlock" : "lock"] [src]'s floor bolts.</span>")
|
||||
playsound(get_turf(src), C.usesound, 50, 1)
|
||||
boltslocked = !boltslocked
|
||||
return
|
||||
@@ -108,10 +120,14 @@
|
||||
return
|
||||
|
||||
/obj/machinery/door/firedoor/try_to_weld(obj/item/weapon/weldingtool/W, mob/user)
|
||||
if(W.remove_fuel(0, user))
|
||||
welded = !welded
|
||||
to_chat(user, "<span class='danger'>You [welded?"welded":"unwelded"] \the [src]</span>")
|
||||
update_icon()
|
||||
if(W.remove_fuel(0, user))
|
||||
playsound(get_turf(src), W.usesound, 50, 1)
|
||||
user.visible_message("<span class='notice'>[user] starts [welded ? "unwelding" : "welding"] [src].</span>", "<span class='notice'>You start welding [src].</span>")
|
||||
if(do_after(user, 40*W.toolspeed, 1, target=src))
|
||||
playsound(get_turf(src), W.usesound, 50, 1)
|
||||
welded = !welded
|
||||
to_chat(user, "<span class='danger'>[user] [welded?"welds":"unwelds"] [src].</span>", "<span class='notice'>You [welded ? "weld" : "unweld"] [src].</span>")
|
||||
update_icon()
|
||||
|
||||
/obj/machinery/door/firedoor/try_to_crowbar(obj/item/I, mob/user)
|
||||
if(welded || operating)
|
||||
@@ -243,13 +259,15 @@
|
||||
..()
|
||||
switch(constructionStep)
|
||||
if(CONSTRUCTION_PANEL_OPEN)
|
||||
to_chat(user, "There is a small metal plate covering the wires.")
|
||||
to_chat(user, "<span class='notice'>It is <i>unbolted</i> from the floor. A small <b>loosely connected</b> metal plate is covering the wires.</span>")
|
||||
if(!reinforced)
|
||||
to_chat(user, "<span class='notice'>It could be reinforced with plasteel.</span>")
|
||||
if(CONSTRUCTION_WIRES_EXPOSED)
|
||||
to_chat(user, "Wires are trailing from the maintenance panel.")
|
||||
to_chat(user, "<span class='notice'>The maintenance plate has been <i>pried away</i>, and <b>wires</b> are trailing.</span>")
|
||||
if(CONSTRUCTION_GUTTED)
|
||||
to_chat(user, "The circuit board is visible.")
|
||||
to_chat(user, "<span class='notice'>The maintenance panel is missing <i>wires</i> and the circuit board is <b>loosely connected</b>.</span>")
|
||||
if(CONSTRUCTION_NOCIRCUIT)
|
||||
to_chat(user, "There are no electronics in the frame.")
|
||||
to_chat(user, "<span class='notice'>There are no <i>firelock electronics</i> in the frame. The frame could be <b>cut</b> apart.</span>")
|
||||
|
||||
/obj/structure/firelock_frame/update_icon()
|
||||
..()
|
||||
@@ -329,19 +347,17 @@
|
||||
constructionStep = CONSTRUCTION_GUTTED
|
||||
update_icon()
|
||||
return
|
||||
if(istype(C, /obj/item/weapon/weldingtool))
|
||||
var/obj/item/weapon/weldingtool/W = C
|
||||
if(W.remove_fuel(1, user))
|
||||
playsound(get_turf(src), W.usesound, 50, 1)
|
||||
user.visible_message("<span class='notice'>[user] starts welding a metal plate into [src]...</span>", \
|
||||
"<span class='notice'>You begin welding the cover plate back onto [src]...</span>")
|
||||
if(!do_after(user, 80*C.toolspeed, target = src))
|
||||
return
|
||||
if(constructionStep != CONSTRUCTION_WIRES_EXPOSED)
|
||||
return
|
||||
playsound(get_turf(src), 'sound/items/Welder2.ogg', 50, 1)
|
||||
user.visible_message("<span class='notice'>[user] welds the metal plate into [src].</span>", \
|
||||
"<span class='notice'>You weld [src]'s cover plate into place, hiding the wires.</span>")
|
||||
if(istype(C, /obj/item/weapon/crowbar))
|
||||
playsound(get_turf(src), C.usesound, 50, 1)
|
||||
user.visible_message("<span class='notice'>[user] starts prying a metal plate into [src]...</span>", \
|
||||
"<span class='notice'>You begin prying the cover plate back onto [src]...</span>")
|
||||
if(!do_after(user, 80*C.toolspeed, target = src))
|
||||
return
|
||||
if(constructionStep != CONSTRUCTION_WIRES_EXPOSED)
|
||||
return
|
||||
playsound(get_turf(src), 'sound/items/Deconstruct.ogg', 50, 1)
|
||||
user.visible_message("<span class='notice'>[user] pries the metal plate into [src].</span>", \
|
||||
"<span class='notice'>You pry [src]'s cover plate into place, hiding the wires.</span>")
|
||||
constructionStep = CONSTRUCTION_PANEL_OPEN
|
||||
update_icon()
|
||||
return
|
||||
@@ -419,4 +435,10 @@
|
||||
|
||||
/obj/structure/firelock_frame/heavy
|
||||
name = "heavy firelock frame"
|
||||
reinforced = 1
|
||||
reinforced = 1
|
||||
|
||||
#undef CONSTRUCTION_COMPLETE
|
||||
#undef CONSTRUCTION_PANEL_OPEN
|
||||
#undef CONSTRUCTION_WIRES_EXPOSED
|
||||
#undef CONSTRUCTION_GUTTED
|
||||
#undef CONSTRUCTION_NOCIRCUIT
|
||||
|
||||
Reference in New Issue
Block a user