fixes ghost role eligibility delay (#12379)

This commit is contained in:
Putnam3145
2020-05-28 05:11:42 -07:00
committed by GitHub
parent 55a58ba76c
commit 811b801569

View File

@@ -287,12 +287,12 @@ Works together with spawning an observer, noted above.
var/maximumRoundEnd = SSautotransfer.starttime + SSautotransfer.voteinterval * SSautotransfer.maxvotes
if(penalty - SSshuttle.realtimeofstart > maximumRoundEnd + SSshuttle.emergencyCallTime + SSshuttle.emergencyDockTime + SSshuttle.emergencyEscapeTime)
penalty = CANT_REENTER_ROUND
if(!(ckey in GLOB.client_ghost_timeouts))
GLOB.client_ghost_timeouts += ckey
GLOB.client_ghost_timeouts[ckey] = 0
else if(GLOB.client_ghost_timeouts[ckey] == CANT_REENTER_ROUND)
if(!(ghost.ckey in GLOB.client_ghost_timeouts))
GLOB.client_ghost_timeouts += ghost.ckey
GLOB.client_ghost_timeouts[ghost.ckey] = 0
else if(GLOB.client_ghost_timeouts[ghost.ckey] == CANT_REENTER_ROUND)
return
GLOB.client_ghost_timeouts[ckey] = max(GLOB.client_ghost_timeouts[ckey],penalty)
GLOB.client_ghost_timeouts[ghost.ckey] = max(GLOB.client_ghost_timeouts[ghost.ckey],penalty)
// needs to be done AFTER the ckey transfer, too
return ghost