From 86d28cc958e6c4592d24a582518c64116cfb06fa Mon Sep 17 00:00:00 2001 From: dearmochi <1496804+dearmochi@users.noreply.github.com> Date: Sat, 25 Nov 2023 06:47:47 +0900 Subject: [PATCH] Make CereStation eligible for random map selection on 60+ players (#23206) --- code/controllers/subsystem/SSticker.dm | 2 +- code/modules/mapping/base_map_datum.dm | 2 ++ code/modules/mapping/cerestation.dm | 1 + 3 files changed, 4 insertions(+), 1 deletion(-) diff --git a/code/controllers/subsystem/SSticker.dm b/code/controllers/subsystem/SSticker.dm index c4cef1e2390..231e8db90ab 100644 --- a/code/controllers/subsystem/SSticker.dm +++ b/code/controllers/subsystem/SSticker.dm @@ -143,7 +143,7 @@ SUBSYSTEM_DEF(ticker) var/list/pickable_types = list() for(var/x in subtypesof(/datum/map)) var/datum/map/M = x - if(initial(M.voteable)) + if(initial(M.voteable) && length(GLOB.clients) >= initial(M.min_players_random)) pickable_types += M var/datum/map/target_map = pick(pickable_types) diff --git a/code/modules/mapping/base_map_datum.dm b/code/modules/mapping/base_map_datum.dm index 8b04d0ac156..0fff760c7c0 100644 --- a/code/modules/mapping/base_map_datum.dm +++ b/code/modules/mapping/base_map_datum.dm @@ -16,3 +16,5 @@ var/webmap_url /// Is this map voteable? var/voteable = TRUE + /// Minimum amount of players required for this map to be eligible in random map picks. + var/min_players_random = 0 diff --git a/code/modules/mapping/cerestation.dm b/code/modules/mapping/cerestation.dm index 333378626b2..684fa449547 100644 --- a/code/modules/mapping/cerestation.dm +++ b/code/modules/mapping/cerestation.dm @@ -3,3 +3,4 @@ technical_name = "CereStation" map_path = "_maps/map_files/cerestation/cerestation.dmm" webmap_url = "https://affectedarc07.github.io/SS13WebMap/Paradise/CereStation/" + min_players_random = 60