Merge pull request #6170 from mwerezak/shuttle-fixes

Fixes shuttle ETA being given before arrive_time is set
This commit is contained in:
Chinsky
2014-08-27 04:24:03 +04:00
2 changed files with 6 additions and 4 deletions
+2 -1
View File
@@ -34,10 +34,11 @@
if (moving_status == SHUTTLE_IDLE)
return //someone cancelled the launch
arrive_time = world.time + travel_time*10
moving_status = SHUTTLE_INTRANSIT
move(departing, interim, direction)
arrive_time = world.time + travel_time*10
while (world.time < arrive_time)
sleep(5)
+4 -3
View File
@@ -16,12 +16,15 @@
else
travel_time = SHUTTLE_TRANSIT_DURATION
//update move_time so we get correct ETAs
//update move_time and launch_time so we get correct ETAs
move_time = travel_time
emergency_shuttle.launch_time = world.time
..()
/datum/shuttle/ferry/emergency/move(var/area/origin,var/area/destination)
..(origin, destination)
if (origin == area_station) //leaving the station
emergency_shuttle.departed = 1
@@ -30,8 +33,6 @@
else
captain_announce("The Crew Transfer Shuttle has left the station. Estimate [round(emergency_shuttle.estimate_arrival_time()/60,1)] minutes until the shuttle docks at Central Command.")
..(origin, destination)
/datum/shuttle/ferry/emergency/can_launch(var/user)
if (istype(user, /obj/machinery/computer/shuttle_control/emergency))
var/obj/machinery/computer/shuttle_control/emergency/C = user