mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-30 00:29:02 +01:00
Keep occupied custom dock (#45407)
About The Pull Request Shuttles no more ruin areas on fly off from moved custom dock. If you dock to custom dock, then move custom dock, after fly off shuttle turfs lost its areas, it replaced by space. It ok in space, but bad on lavaland. Why It's Good For The Game Gravityless and airless areas on lavalend is bad. Changelog cl fix: Shuttles no more ruin areas on fly off from moved custom dock. /cl
This commit is contained in:
@@ -135,6 +135,13 @@
|
||||
to_chat(current_user, "<span class='warning'>Unknown object detected in landing zone. Please designate another location.</span>")
|
||||
return
|
||||
|
||||
///Make one use port that deleted after fly off, to don't lose info that need on to properly fly off.
|
||||
if(my_port && my_port.get_docked())
|
||||
my_port.delete_after = TRUE
|
||||
my_port.id = null
|
||||
my_port.name = "Old [my_port.name]"
|
||||
my_port = null
|
||||
|
||||
if(!my_port)
|
||||
my_port = new()
|
||||
my_port.name = shuttlePortName
|
||||
|
||||
@@ -23,6 +23,8 @@
|
||||
var/area_type
|
||||
var/hidden = FALSE //are we invisible to shuttle navigation computers?
|
||||
|
||||
var/delete_after = FALSE ///Delete this port after ship fly off.
|
||||
|
||||
//these objects are indestructible
|
||||
/obj/docking_port/Destroy(force)
|
||||
// unless you assert that you know what you're doing. Horrible things
|
||||
@@ -432,7 +434,10 @@
|
||||
if(initiate_docking(S1) != DOCKING_SUCCESS)
|
||||
WARNING("shuttle \"[id]\" could not enter transit space. Docked at [S0 ? S0.id : "null"]. Transit dock [S1 ? S1.id : "null"].")
|
||||
else
|
||||
previous = S0
|
||||
if(S0.delete_after)
|
||||
qdel(S0, TRUE)
|
||||
else
|
||||
previous = S0
|
||||
else
|
||||
WARNING("shuttle \"[id]\" could not enter transit space. S0=[S0 ? S0.id : "null"] S1=[S1 ? S1.id : "null"]")
|
||||
|
||||
|
||||
Reference in New Issue
Block a user