mirror of
https://github.com/VOREStation/VOREStation.git
synced 2026-08-22 11:38:12 +01:00
Update autotransfer.dm
This commit is contained in:
@@ -3,6 +3,7 @@ var/datum/controller/transfer_controller/transfer_controller
|
||||
datum/controller/transfer_controller
|
||||
var/timerbuffer = 0 //buffer for time check
|
||||
var/currenttick = 0
|
||||
var/shift_hard_end = vote_autotransfer_initial + vote_autotransfer_interval //VOREStation Edit
|
||||
datum/controller/transfer_controller/New()
|
||||
timerbuffer = config.vote_autotransfer_initial
|
||||
processing_objects += src
|
||||
@@ -12,6 +13,11 @@ datum/controller/transfer_controller/Destroy()
|
||||
|
||||
datum/controller/transfer_controller/proc/process()
|
||||
currenttick = currenttick + 1
|
||||
if (round_duration_in_ticks >= timerbuffer - 1 MINUTE)
|
||||
if (round_duration_in_ticks >= shift_hard_end - 1 MINUTE)//VOREStation Edit START
|
||||
init_shift_change(null, 1)
|
||||
shift_hard_end = timerbuffer + config.vote_autotransfer_interval //If shuttle somehow gets recalled, let's do this.
|
||||
timerbuffer = timerbuffer + config.vote_autotransfer_interval //Just to make sure a vote doesn't occur immediately afterwords.
|
||||
else if (round_duration_in_ticks >= timerbuffer - 1 MINUTE) //VOREStation Edit END
|
||||
vote.autotransfer()
|
||||
timerbuffer = timerbuffer + config.vote_autotransfer_interval
|
||||
|
||||
|
||||
Reference in New Issue
Block a user