mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-11 02:34:00 +00:00
Merge pull request #6547 from VOREStation/upstream-merge-6676
[MIRROR] Fix frame deconstruction bugs
This commit is contained in:
@@ -429,6 +429,7 @@
|
|||||||
circuit = null
|
circuit = null
|
||||||
if(frame_type.frame_class == FRAME_CLASS_MACHINE)
|
if(frame_type.frame_class == FRAME_CLASS_MACHINE)
|
||||||
req_components = null
|
req_components = null
|
||||||
|
update_desc()
|
||||||
|
|
||||||
else if(state == FRAME_WIRED)
|
else if(state == FRAME_WIRED)
|
||||||
if(frame_type.frame_class == FRAME_CLASS_MACHINE)
|
if(frame_type.frame_class == FRAME_CLASS_MACHINE)
|
||||||
@@ -498,27 +499,21 @@
|
|||||||
|
|
||||||
else if(P.is_wirecutter())
|
else if(P.is_wirecutter())
|
||||||
if(state == FRAME_WIRED)
|
if(state == FRAME_WIRED)
|
||||||
if(frame_type.frame_class == FRAME_CLASS_COMPUTER)
|
if( \
|
||||||
|
frame_type.frame_class == FRAME_CLASS_COMPUTER || \
|
||||||
|
frame_type.frame_class == FRAME_CLASS_DISPLAY || \
|
||||||
|
frame_type.frame_class == FRAME_CLASS_ALARM || \
|
||||||
|
frame_type.frame_class == FRAME_CLASS_MACHINE \
|
||||||
|
)
|
||||||
playsound(src, P.usesound, 50, 1)
|
playsound(src, P.usesound, 50, 1)
|
||||||
to_chat(user, "<span class='notice'>You remove the cables.</span>")
|
if (components.len == 0)
|
||||||
state = FRAME_FASTENED
|
to_chat(user, "<span class='notice'>You remove the cables.</span>")
|
||||||
new /obj/item/stack/cable_coil(src.loc, 5)
|
else
|
||||||
|
to_chat(user, "<span class='notice'>You remove the cables and components.</span>")
|
||||||
else if(frame_type.frame_class == FRAME_CLASS_DISPLAY)
|
for(var/obj/item/weapon/W in components)
|
||||||
playsound(src, P.usesound, 50, 1)
|
W.forceMove(src.loc)
|
||||||
to_chat(user, "<span class='notice'>You remove the cables.</span>")
|
check_components()
|
||||||
state = FRAME_FASTENED
|
update_desc()
|
||||||
new /obj/item/stack/cable_coil(src.loc, 5)
|
|
||||||
|
|
||||||
else if(frame_type.frame_class == FRAME_CLASS_ALARM)
|
|
||||||
playsound(src, P.usesound, 50, 1)
|
|
||||||
to_chat(user, "<span class='notice'>You remove the cables.</span>")
|
|
||||||
state = FRAME_FASTENED
|
|
||||||
new /obj/item/stack/cable_coil(src.loc, 5)
|
|
||||||
|
|
||||||
else if(frame_type.frame_class == FRAME_CLASS_MACHINE)
|
|
||||||
playsound(src, P.usesound, 50, 1)
|
|
||||||
to_chat(user, "<span class='notice'>You remove the cables.</span>")
|
|
||||||
state = FRAME_FASTENED
|
state = FRAME_FASTENED
|
||||||
new /obj/item/stack/cable_coil(src.loc, 5)
|
new /obj/item/stack/cable_coil(src.loc, 5)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user