mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-11 18:53:06 +00:00
Merge branch 'release' of https://github.com/VOREStation/VOREStation # Conflicts: # code/controllers/autotransfer.dm # code/controllers/subsystems/inactivity.dm # code/game/area/Away Mission areas.dm # code/game/area/Space Station 13 areas.dm # code/game/jobs/job/captain.dm # code/game/jobs/job/civilian.dm # code/game/jobs/job/security.dm # code/game/jobs/jobs.dm # code/game/machinery/air_alarm.dm # code/game/machinery/suit_storage_unit.dm # code/game/machinery/suit_storage_unit_vr.dm # code/game/mecha/combat/gorilla.dm # code/game/turfs/simulated/dungeon/wall.dm # code/game/turfs/simulated/wall_types.dm # code/modules/client/preference_setup/loadout/loadout_utility_vr.dm # code/modules/clothing/glasses/glasses.dm # code/modules/clothing/spacesuits/rig/rig_pieces_vr.dm # code/modules/clothing/spacesuits/void/void_vr.dm # code/modules/clothing/under/accessories/holster.dm # code/modules/mob/language/station_vr.dm # code/modules/mob/living/carbon/human/emote_vr.dm # code/modules/mob/living/carbon/human/species/station/station_vr.dm # code/modules/mob/living/carbon/human/species/station/traits_vr/positive.dm # code/modules/mob/new_player/sprite_accessories_vr.dm # code/modules/power/apc.dm # code/modules/power/lighting.dm # code/modules/resleeving/machines.dm # config/jobwhitelist.txt # icons/mob/species/seromi/head.dmi # icons/mob/species/seromi/suit.dmi # icons/mob/species/vulpkanin/helmet.dmi # icons/mob/species/vulpkanin/suit.dmi # maps/tether/submaps/_tether_submaps.dm # maps/tether/tether_areas2.dm # maps/tether/tether_defines.dm # maps/tether/tether_shuttles.dm # nano/templates/apc.tmpl # vorestation.dme
31 lines
1.8 KiB
Plaintext
31 lines
1.8 KiB
Plaintext
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 = 0 //VOREStation Edit
|
|
var/shift_last_vote = 0 //VOREStation Edit
|
|
datum/controller/transfer_controller/New()
|
|
timerbuffer = config.vote_autotransfer_initial
|
|
shift_hard_end = config.vote_autotransfer_initial + (config.vote_autotransfer_interval * config.vote_autotransfer_amount) //YW Edit: made that '1' a config //VOREStation Edit //Change this "1" to how many extend votes you want there to be.
|
|
shift_last_vote = shift_hard_end - config.vote_autotransfer_interval //VOREStation Edit
|
|
START_PROCESSING(SSprocessing, src)
|
|
|
|
datum/controller/transfer_controller/Destroy()
|
|
STOP_PROCESSING(SSprocessing, src)
|
|
|
|
datum/controller/transfer_controller/process()
|
|
currenttick = currenttick + 1
|
|
//VOREStation Edit START
|
|
if (round_duration_in_ticks >= shift_last_vote - 2 MINUTES)
|
|
shift_last_vote = 999999999999 //Setting to a stupidly high number since it'll be not used again.
|
|
to_world("Warning: This upcoming round-extend vote will be your ONLY extend vote. Wrap up your scenes in the next 4 fuckin hours if the round is extended.") //YAWN EDIT NIGGA VOREStation Edit
|
|
if (round_duration_in_ticks >= shift_hard_end - 1 MINUTE)
|
|
init_shift_change(null, 1)
|
|
shift_hard_end = timerbuffer + config.vote_autotransfer_interval //If shuttle somehow gets recalled, let's force it to call again next time a vote would occur.
|
|
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)
|
|
SSvote.autotransfer()
|
|
//VOREStation Edit END
|
|
timerbuffer = timerbuffer + config.vote_autotransfer_interval
|