mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-26 06:29:23 +01:00
Ticker subsystem cleanup (#40649)
* Removes unused vars from ticker. * More ticker cleanup * This too.
This commit is contained in:
@@ -422,9 +422,9 @@ or shoot a gun to move around via Newton's 3rd Law of Motion."
|
||||
if(C && C.clock_team)
|
||||
textlist += "[C.clock_team.eminence ? "There is an Eminence." : "<b>There is no Eminence! Get one ASAP!</b>"]<br>"
|
||||
textlist += "There are currently <b>[servants]</b> servant[servants > 1 ? "s" : ""] of Ratvar.<br>"
|
||||
for(var/i in SSticker.scripture_states)
|
||||
for(var/i in GLOB.scripture_states)
|
||||
if(i != SCRIPTURE_DRIVER) //ignore the always-unlocked stuff
|
||||
textlist += "[i] Scripture: <b>[SSticker.scripture_states[i] ? "UNLOCKED":"LOCKED"]</b><br>"
|
||||
textlist += "[i] Scripture: <b>[GLOB.scripture_states[i] ? "UNLOCKED":"LOCKED"]</b><br>"
|
||||
var/obj/structure/destructible/clockwork/massive/celestial_gateway/G = GLOB.ark_of_the_clockwork_justiciar
|
||||
if(G)
|
||||
var/time_info = G.get_arrival_time(FALSE)
|
||||
|
||||
@@ -16,8 +16,6 @@ SUBSYSTEM_DEF(ticker)
|
||||
|
||||
var/hide_mode = 0
|
||||
var/datum/game_mode/mode = null
|
||||
var/event_time = null
|
||||
var/event = 0
|
||||
|
||||
var/login_music //music played in pregame lobby
|
||||
var/round_end_sound //music/jingle played when the world reboots
|
||||
@@ -25,13 +23,6 @@ SUBSYSTEM_DEF(ticker)
|
||||
|
||||
var/list/datum/mind/minds = list() //The characters in the game. Used for objective tracking.
|
||||
|
||||
var/list/syndicate_coalition = list() //list of traitor-compatible factions
|
||||
var/list/factions = list() //list of all factions
|
||||
var/list/availablefactions = list() //list of factions with openings
|
||||
var/list/scripture_states = list(SCRIPTURE_DRIVER = TRUE, \
|
||||
SCRIPTURE_SCRIPT = FALSE, \
|
||||
SCRIPTURE_APPLICATION = FALSE) //list of clockcult scripture states for announcements
|
||||
|
||||
var/delay_end = 0 //if set true, the round will not restart on it's own
|
||||
var/admin_delay_notice = "" //a message to display to anyone who tries to restart the world after a delay
|
||||
var/ready_for_reboot = FALSE //all roundend preparation done with, all that's left is reboot
|
||||
@@ -190,7 +181,6 @@ SUBSYSTEM_DEF(ticker)
|
||||
mode.process(wait * 0.1)
|
||||
check_queue()
|
||||
check_maprotate()
|
||||
scripture_states = scripture_unlock_alert(scripture_states)
|
||||
|
||||
if(!roundend_check_paused && mode.check_finished(force_ending) || force_ending)
|
||||
current_state = GAME_STATE_FINISHED
|
||||
@@ -457,18 +447,12 @@ SUBSYSTEM_DEF(ticker)
|
||||
force_ending = SSticker.force_ending
|
||||
hide_mode = SSticker.hide_mode
|
||||
mode = SSticker.mode
|
||||
event_time = SSticker.event_time
|
||||
event = SSticker.event
|
||||
|
||||
login_music = SSticker.login_music
|
||||
round_end_sound = SSticker.round_end_sound
|
||||
|
||||
minds = SSticker.minds
|
||||
|
||||
syndicate_coalition = SSticker.syndicate_coalition
|
||||
factions = SSticker.factions
|
||||
availablefactions = SSticker.availablefactions
|
||||
|
||||
delay_end = SSticker.delay_end
|
||||
|
||||
triai = SSticker.triai
|
||||
|
||||
@@ -58,12 +58,6 @@
|
||||
return TRUE
|
||||
return ..()
|
||||
|
||||
/datum/game_mode/proc/are_operatives_dead()
|
||||
for(var/datum/mind/operative_mind in get_antag_minds(/datum/antagonist/nukeop))
|
||||
if(ishuman(operative_mind.current) && (operative_mind.current.stat != DEAD))
|
||||
return FALSE
|
||||
return TRUE
|
||||
|
||||
/datum/game_mode/nuclear/check_finished()
|
||||
//Keep the round going if ops are dead but bomb is ticking.
|
||||
if(nuke_team.operatives_dead())
|
||||
|
||||
@@ -187,7 +187,7 @@
|
||||
return FALSE
|
||||
var/initial_tier = initial(scripture.tier)
|
||||
if(initial_tier != SCRIPTURE_PERIPHERAL)
|
||||
if(!GLOB.ratvar_awakens && !no_cost && !SSticker.scripture_states[initial_tier])
|
||||
if(!GLOB.ratvar_awakens && !no_cost && !GLOB.scripture_states[initial_tier])
|
||||
to_chat(user, "<span class='warning'>That scripture is not unlocked, and cannot be recited!</span>")
|
||||
return FALSE
|
||||
var/datum/clockwork_scripture/scripture_to_recite = new scripture
|
||||
@@ -411,12 +411,12 @@
|
||||
if(SCRIPTURE_DRIVER)
|
||||
data["tier_info"] = "<font color=#B18B25><b>These scriptures are permanently unlocked.</b></font>"
|
||||
if(SCRIPTURE_SCRIPT)
|
||||
if(SSticker.scripture_states[SCRIPTURE_SCRIPT])
|
||||
if(GLOB.scripture_states[SCRIPTURE_SCRIPT])
|
||||
data["tier_info"] = "<font color=#B18B25><b>These scriptures are permanently unlocked.</b></font>"
|
||||
else
|
||||
data["tier_info"] = "<font color=#B18B25><i>These scriptures will automatically unlock when the Ark is halfway ready or if [DisplayPower(SCRIPT_UNLOCK_THRESHOLD)] of power is reached.</i></font>"
|
||||
if(SCRIPTURE_APPLICATION)
|
||||
if(SSticker.scripture_states[SCRIPTURE_APPLICATION])
|
||||
if(GLOB.scripture_states[SCRIPTURE_APPLICATION])
|
||||
data["tier_info"] = "<font color=#B18B25><b>These scriptures are permanently unlocked.</b></font>"
|
||||
else
|
||||
data["tier_info"] = "<font color=#B18B25><i>Unlock these optional scriptures by converting another servant or if [DisplayPower(APPLICATION_UNLOCK_THRESHOLD)] of power is reached..</i></font>"
|
||||
|
||||
@@ -7,6 +7,11 @@ Scripts: 5 servants and a cache
|
||||
Applications: 8 servants, 3 caches, and 100 CV
|
||||
*/
|
||||
|
||||
GLOBAL_LIST_INIT(scripture_states,scripture_states_init_value()) //list of clockcult scripture states for announcements
|
||||
|
||||
/proc/scripture_states_init_value()
|
||||
return list(SCRIPTURE_DRIVER = TRUE, SCRIPTURE_SCRIPT = FALSE, SCRIPTURE_APPLICATION = FALSE)
|
||||
|
||||
/datum/clockwork_scripture
|
||||
var/descname = "useless" //a simple name for the scripture's effect
|
||||
var/name = "scripture"
|
||||
|
||||
@@ -193,6 +193,17 @@
|
||||
var/list/objective
|
||||
var/datum/mind/eminence
|
||||
|
||||
/datum/team/clockcult/New(starting_members)
|
||||
. = ..()
|
||||
START_PROCESSING(SSobj,src)
|
||||
|
||||
/datum/team/clockcult/process()
|
||||
GLOB.scripture_states = scripture_unlock_alert(GLOB.scripture_states)
|
||||
|
||||
/datum/team/clockcult/Destroy(force, ...)
|
||||
STOP_PROCESSING(SSobj,src)
|
||||
. = ..()
|
||||
|
||||
/datum/team/clockcult/proc/check_clockwork_victory()
|
||||
if(GLOB.clockwork_gateway_activated)
|
||||
return TRUE
|
||||
@@ -208,9 +219,9 @@
|
||||
parts += " "
|
||||
parts += "<b>The servants' objective was:</b> [CLOCKCULT_OBJECTIVE]."
|
||||
parts += "<b>Construction Value(CV)</b> was: <b>[GLOB.clockwork_construction_value]</b>"
|
||||
for(var/i in SSticker.scripture_states)
|
||||
for(var/i in GLOB.scripture_states)
|
||||
if(i != SCRIPTURE_DRIVER)
|
||||
parts += "<b>[i] scripture</b> was: <b>[SSticker.scripture_states[i] ? "UN":""]LOCKED</b>"
|
||||
parts += "<b>[i] scripture</b> was: <b>[GLOB.scripture_states[i] ? "UN":""]LOCKED</b>"
|
||||
if(eminence)
|
||||
parts += "<span class='header'>The Eminence was:</span> [printplayer(eminence)]"
|
||||
if(members.len)
|
||||
|
||||
Reference in New Issue
Block a user