From 10094e06655629404bbbc8b89ded0282eaa42e06 Mon Sep 17 00:00:00 2001 From: SkyratBot <59378654+SkyratBot@users.noreply.github.com> Date: Mon, 13 Mar 2023 05:40:57 +0100 Subject: [PATCH] [MIRROR] Elevator doors open if called from same z-level [MDB IGNORE] (#19815) * Elevator doors open if called from same z-level (#73921) ## About The Pull Request Fixes oversight where button doesn't open doors if the elevator is on the same z-level. ## Why It's Good For The Game The lower floor elevators will work properly on Tramstation and wherever else. ## Changelog :cl: LT3 fix: Tramstation lower floor elevator buttons work properly at roundstart /:cl: * Elevator doors open if called from same z-level --------- Co-authored-by: lessthanthree <83487515+lessthnthree@users.noreply.github.com> --- code/modules/industrial_lift/elevator_button.dm | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/code/modules/industrial_lift/elevator_button.dm b/code/modules/industrial_lift/elevator_button.dm index 465f42fee5c..0dc83dcbc90 100644 --- a/code/modules/industrial_lift/elevator_button.dm +++ b/code/modules/industrial_lift/elevator_button.dm @@ -92,11 +92,12 @@ loc.balloon_alert(activator, "elevator is moving!") return FALSE - // We can't call an elevator if it's already at this destination + // If the elevator is already here, open the doors. var/obj/structure/industrial_lift/prime_lift = lift.return_closest_platform_to_z(loc.z) if(prime_lift.z == loc.z) + INVOKE_ASYNC(lift, TYPE_PROC_REF(/datum/lift_master, open_lift_doors_callback)) loc.balloon_alert(activator, "elevator is here!") - return FALSE + return TRUE // At this point, we can start moving.