Configuration Controller (#7857)

This commit is contained in:
Selis
2024-04-05 07:44:20 +02:00
committed by GitHub
parent c542e3bac0
commit e1a987c25c
235 changed files with 3294 additions and 989 deletions
@@ -65,10 +65,10 @@ var/list/gear_datums = list()
for(var/gear_name in gear_datums)
var/datum/gear/G = gear_datums[gear_name]
if(G.whitelisted && config.loadout_whitelist != LOADOUT_WHITELIST_OFF && pref.client) //VOREStation Edit.
if(config.loadout_whitelist == LOADOUT_WHITELIST_STRICT && G.whitelisted != pref.species)
if(G.whitelisted && CONFIG_GET(flag/loadout_whitelist) != LOADOUT_WHITELIST_OFF && pref.client) //VOREStation Edit. // CHOMPEdit
if(CONFIG_GET(flag/loadout_whitelist) == LOADOUT_WHITELIST_STRICT && G.whitelisted != pref.species) // CHOMPEdit
continue
if(config.loadout_whitelist == LOADOUT_WHITELIST_LAX && !is_alien_whitelisted(preference_mob(), GLOB.all_species[G.whitelisted]))
if(CONFIG_GET(flag/loadout_whitelist) == LOADOUT_WHITELIST_LAX && !is_alien_whitelisted(preference_mob(), GLOB.all_species[G.whitelisted])) // CHOMPEdit
continue
if(max_cost && G.cost > max_cost)
@@ -222,14 +222,14 @@ var/list/gear_datums = list()
if(href_list["next_slot"])
//change the current slot number
pref.gear_slot = pref.gear_slot+1
if(pref.gear_slot>config.loadout_slots)
if(pref.gear_slot > CONFIG_GET(number/loadout_slots)) // CHOMPEdit
pref.gear_slot = 1
//If we're moving down a slot..
else if(href_list["prev_slot"])
//change current slot one down
pref.gear_slot = pref.gear_slot-1
if(pref.gear_slot<1)
pref.gear_slot = config.loadout_slots
pref.gear_slot = CONFIG_GET(number/loadout_slots) // CHOMPEdit
// Set the currently selected gear to whatever's in the new slot
if(pref.gear_list["[pref.gear_slot]"])
pref.gear = pref.gear_list["[pref.gear_slot]"]