mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-22 03:27:05 +01:00
Adds configs for hijack population minimums (#31206)
* add config for hijack pop lock * woopsie daisy * doth this please you, your lintliness? * nerd emoji * address DGL's most beauteous code review
This commit is contained in:
@@ -22,6 +22,12 @@
|
||||
var/enable_gamemode_player_limit = TRUE
|
||||
/// Should we generate random station traits at game start?
|
||||
var/add_random_station_traits = TRUE
|
||||
/// Minimum readied up players required for roundstart hijack objectives
|
||||
var/min_players_hijack_roundstart = 30
|
||||
/// Minimum alive crew required for midround hijack objectives
|
||||
var/min_players_hijack_midround = 20
|
||||
/// Minimum living security required for midround hijack objectives
|
||||
var/min_security_hijack_midround = 2
|
||||
|
||||
// Dynamically setup a list of all gamemodes
|
||||
/datum/configuration_section/gamemode_configuration/New()
|
||||
@@ -57,6 +63,10 @@
|
||||
|
||||
CONFIG_LOAD_NUM(traitor_objectives_amount, data["traitor_objective_amount"])
|
||||
|
||||
CONFIG_LOAD_NUM(min_players_hijack_roundstart, data["min_players_hijack_roundstart"])
|
||||
CONFIG_LOAD_NUM(min_players_hijack_midround, data["min_players_hijack_midround"])
|
||||
CONFIG_LOAD_NUM(min_security_hijack_midround, data["min_security_hijack_midround"])
|
||||
|
||||
// Load gamemode probabilities
|
||||
if(islist(data["gamemode_probabilities"]))
|
||||
for(var/list/assocset in data["gamemode_probabilities"])
|
||||
|
||||
@@ -276,6 +276,13 @@ SUBSYSTEM_DEF(ticker)
|
||||
|
||||
// Behold, a rough way of figuring out what takes 10 years
|
||||
var/watch = start_watch()
|
||||
|
||||
// Count ready players before we spawn them for hijack objective requirements
|
||||
GLOB.roundstart_ready_players = 0
|
||||
for(var/mob/new_player/player in GLOB.new_player_mobs)
|
||||
if(player.ready && player.client)
|
||||
GLOB.roundstart_ready_players++
|
||||
|
||||
create_characters() // Create player characters and transfer clients
|
||||
log_debug("Creating characters took [stop_watch(watch)]s")
|
||||
|
||||
|
||||
Reference in New Issue
Block a user