Adds config for monkey cap

This commit is contained in:
Jordan Brown
2018-05-31 16:30:49 -04:00
committed by letterjay
parent 340c6d2e83
commit db20e34d76
4 changed files with 13 additions and 4 deletions

View File

@@ -288,6 +288,7 @@
/datum/config_entry/flag/shift_time_realtime
<<<<<<< HEAD
//Cit changes - Adds config options for crew objectives and miscreants
/datum/config_entry/flag/allow_crew_objectives
@@ -304,4 +305,9 @@
/datum/config_entry/number/nightshift_finish
config_entry_value = 6
//End of Cit changes
//End of Cit changes
=======
/datum/config_entry/number/monkeycap
config_entry_value = 64
min_val = 0
>>>>>>> f988a13... Adds config for monkey cap (#38165)

View File

@@ -7,7 +7,6 @@ SUBSYSTEM_DEF(mobs)
var/list/currentrun = list()
var/static/list/clients_by_zlevel[][]
var/static/list/cubemonkeys = list()
var/cubemonkeycap = 64
/datum/controller/subsystem/mobs/stat_entry()
..("P:[GLOB.mob_living_list.len]")

View File

@@ -33,9 +33,10 @@
. = ..()
if (cubespawned)
if (LAZYLEN(SSmobs.cubemonkeys) > SSmobs.cubemonkeycap)
var/cap = CONFIG_GET(number/monkeycap)
if (LAZYLEN(SSmobs.cubemonkeys) > cap)
if (spawner)
to_chat(spawner, "<span class='warning'>Bluespace harmonics prevent the spawning of more than [SSmobs.cubemonkeycap] monkeys on the station at one time!</span>")
to_chat(spawner, "<span class='warning'>Bluespace harmonics prevent the spawning of more than [cap] monkeys on the station at one time!</span>")
return INITIALIZE_HINT_QDEL
SSmobs.cubemonkeys += src

View File

@@ -551,3 +551,6 @@ ROUNDSTART_TRAITS
## Sets shift time to server time at roundstart. Overridden by RANDOMIZE_SHIFT_TIME ##
#SHIFT_TIME_REALTIME
## A cap on how many monkeys may be created via monkey cubes
MONKEYCAP 64