Skip to content

Commit

Permalink
Locking lifeboats open the docks (#5133)
Browse files Browse the repository at this point in the history
# About the pull request
Locking lifeboats open the docks.

# Explain why it's good for the game
No more lifeboats getting stuck locked when queen hijacks during launch.


# Testing Photographs and Procedure
<details>
I did test it... kinda
<summary>Screenshots & Videos</summary>

Put screenshots and videos here with an empty line between the
screenshots and the `<details>` tags.

</details>


# Changelog
:cl: ihatethisengine
add: locking lifeboats open the docks
/:cl:
  • Loading branch information
ihatethisengine authored Dec 9, 2023
1 parent b59dc15 commit 4d5b052
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 5 deletions.
19 changes: 14 additions & 5 deletions code/modules/shuttle/computer.dm
Original file line number Diff line number Diff line change
Expand Up @@ -343,14 +343,23 @@
if(lifeboat.status == LIFEBOAT_LOCKED)
to_chat(xeno, SPAN_WARNING("We already wrested away control of this metal bird."))
return XENO_NO_DELAY_ACTION
if(lifeboat.mode == SHUTTLE_CALL)
to_chat(xeno, SPAN_WARNING("Too late, you cannot stop the metal bird mid-flight."))
return XENO_NO_DELAY_ACTION

xeno_attack_delay(xeno)
if(do_after(usr, 5 SECONDS, INTERRUPT_ALL, BUSY_ICON_HOSTILE))
if(lifeboat.status != LIFEBOAT_LOCKED)
lifeboat.status = LIFEBOAT_LOCKED
lifeboat.available = FALSE
lifeboat.set_mode(SHUTTLE_IDLE)
xeno_message(SPAN_XENOANNOUNCE("We have wrested away control of one of the metal birds! They shall not escape!"), 3, xeno.hivenumber)
if(lifeboat.status == LIFEBOAT_LOCKED)
return XENO_NO_DELAY_ACTION
if(lifeboat.mode == SHUTTLE_CALL)
to_chat(xeno, SPAN_WARNING("Too late, you cannot stop the metal bird mid-flight."))
return XENO_NO_DELAY_ACTION
lifeboat.status = LIFEBOAT_LOCKED
lifeboat.available = FALSE
lifeboat.set_mode(SHUTTLE_IDLE)
var/obj/docking_port/stationary/lifeboat_dock/lifeboat_dock = lifeboat.get_docked()
lifeboat_dock.open_dock()
xeno_message(SPAN_XENOANNOUNCE("We have wrested away control of one of the metal birds! They shall not escape!"), 3, xeno.hivenumber)
return XENO_NO_DELAY_ACTION
else
return ..()
2 changes: 2 additions & 0 deletions code/modules/shuttle/shuttles/crashable/lifeboats.dm
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,8 @@

/obj/docking_port/stationary/lifeboat_dock/proc/close_dock()
var/obj/docking_port/mobile/crashable/lifeboat/docked_shuttle = get_docked()
if(docked_shuttle.status == LIFEBOAT_LOCKED)
return
if(docked_shuttle)
for(var/obj/structure/machinery/door/airlock/multi_tile/door in docked_shuttle.doors)
INVOKE_ASYNC(door, TYPE_PROC_REF(/obj/structure/machinery/door/airlock/multi_tile/almayer/dropshiprear/lifeboat, close_and_lock))
Expand Down

0 comments on commit 4d5b052

Please sign in to comment.