mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2026-08-31 01:00:59 +01:00
Canisters detach from ports if they get destroyed (#7967)
This commit is contained in:
@@ -168,8 +168,13 @@ update_flag
|
||||
|
||||
if (src.health <= 10)
|
||||
var/atom/location = src.loc
|
||||
var/obj/machinery/atmospherics/portables_connector/port = locate() in location // CHOMPEdit - Finds if there's a port
|
||||
location.assume_air(air_contents)
|
||||
|
||||
if(port && anchored) // CHOMPEdit - if it blew up, frees up the port
|
||||
disconnect()
|
||||
anchored = 0
|
||||
|
||||
src.destroyed = 1
|
||||
playsound(src, 'sound/effects/spray.ogg', 10, 1, -3)
|
||||
src.density = FALSE
|
||||
|
||||
@@ -117,7 +117,7 @@
|
||||
update_icon()
|
||||
return
|
||||
|
||||
else if (W.has_tool_quality(TOOL_WRENCH))
|
||||
else if (W.has_tool_quality(TOOL_WRENCH) && !(src.destroyed)) // CHOMPEdit - Make sure it's not broken
|
||||
if(connected_port)
|
||||
disconnect()
|
||||
to_chat(user, "<span class='notice'>You disconnect \the [src] from the port.</span>")
|
||||
|
||||
Reference in New Issue
Block a user