Skip to content

Commit

Permalink
Allows Xenomorphs to turn off the dropship's launch alarm (#5210)
Browse files Browse the repository at this point in the history
# About the pull request

Allows Xenomorphs to turn off the dropship's launch alarm without the
queen needing to launch.

# Explain why it's good for the game

Occasionally (2-3 times that I can think of, at least) someone turns on
the dropship's launch alarm after the queen calls it down, resulting in
a situation where if the queen wants to wait for evolutions or something
else, the entire hive has to listen to a beeping noise for multiple
minutes.

# Testing Photographs and Procedure
<details>
<summary>Screenshots & Videos</summary>


https://github.com/cmss13-devs/cmss13/assets/57483089/9014b2bb-a68a-4ef8-b7ee-1f3e03ce2575

</details>


# Changelog
:cl:
add: Allowed Xenomorphs to turn off the dropship's launch alarm by
hitting the nav computer.
/:cl:
  • Loading branch information
SabreML authored Dec 23, 2023
1 parent cddeb3e commit bc2f096
Showing 1 changed file with 19 additions and 11 deletions.
30 changes: 19 additions & 11 deletions code/modules/shuttle/computers/dropship_computer.dm
Original file line number Diff line number Diff line change
Expand Up @@ -211,21 +211,31 @@


/obj/structure/machinery/computer/shuttle/dropship/flight/attack_alien(mob/living/carbon/xenomorph/xeno)
if(!is_ground_level(z))
to_chat(xeno, SPAN_NOTICE("Lights flash from the terminal but we can't comprehend their meaning."))
playsound(loc, 'sound/machines/terminal_error.ogg', KEYBOARD_SOUND_VOLUME, 1)
return
var/obj/docking_port/mobile/marine_dropship/dropship = SSshuttle.getShuttle(shuttleId)

// If the attacking xeno isn't the queen.
if(xeno.hive_pos != XENO_QUEEN)
to_chat(xeno, SPAN_NOTICE("Lights flash from the terminal but we can't comprehend their meaning."))
playsound(loc, 'sound/machines/terminal_error.ogg', KEYBOARD_SOUND_VOLUME, 1)
return
// If the 'about to launch' alarm is playing, a xeno can whack the computer to stop it.
if(dropship.playing_launch_announcement_alarm)
stop_playing_launch_announcement_alarm()
xeno.animation_attack_on(src)
to_chat(xeno, SPAN_XENONOTICE("We slash at [src], silencing its squawking!"))
playsound(loc, 'sound/machines/terminal_shutdown.ogg', 20)
else
to_chat(xeno, SPAN_NOTICE("Lights flash from the terminal but we can't comprehend their meaning."))
playsound(loc, 'sound/machines/terminal_error.ogg', KEYBOARD_SOUND_VOLUME, TRUE)
return XENO_NONCOMBAT_ACTION

if(!is_ground_level(z))
// "you" rather than "we" for this one since non-queen castes will have returned above.
to_chat(xeno, SPAN_NOTICE("Lights flash from the terminal but you can't comprehend their meaning."))
playsound(loc, 'sound/machines/terminal_error.ogg', KEYBOARD_SOUND_VOLUME, TRUE)
return XENO_NONCOMBAT_ACTION

if(is_remote)
groundside_alien_action(xeno)
return

var/obj/docking_port/mobile/marine_dropship/dropship = SSshuttle.getShuttle(shuttleId)
if(dropship.is_hijacked)
return

Expand All @@ -239,6 +249,7 @@
addtimer(CALLBACK(GLOB.almayer_orbital_cannon, TYPE_PROC_REF(/obj/structure/orbital_cannon, enable)), 10 MINUTES, TIMER_UNIQUE)
if(!GLOB.resin_lz_allowed)
set_lz_resin_allowed(TRUE)
stop_playing_launch_announcement_alarm()

to_chat(xeno, SPAN_XENONOTICE("You override the doors."))
xeno_message(SPAN_XENOANNOUNCE("The doors of the metal bird have been overridden! Rejoice!"), 3, xeno.hivenumber)
Expand Down Expand Up @@ -287,9 +298,6 @@
hijack.fire()
GLOB.alt_ctrl_disabled = TRUE

dropship.alarm_sound_loop.stop()
dropship.playing_launch_announcement_alarm = FALSE

marine_announcement("Unscheduled dropship departure detected from operational area. Hijack likely. Shutting down autopilot.", "Dropship Alert", 'sound/AI/hijack.ogg', logging = ARES_LOG_SECURITY)
log_ares_flight("Unknown", "Unscheduled dropship departure detected from operational area. Hijack likely. Shutting down autopilot.")

Expand Down

0 comments on commit bc2f096

Please sign in to comment.