diff --git a/code/__DEFINES/misc.dm b/code/__DEFINES/misc.dm index 3e51b97ba44..3813a5ed941 100644 --- a/code/__DEFINES/misc.dm +++ b/code/__DEFINES/misc.dm @@ -309,7 +309,7 @@ #define ROUND_TIME (SSticker.round_start_time ? (world.time - SSticker.round_start_time) : 0) // Macro that returns true if it's too early in a round to freely ghost out -#define TOO_EARLY_TO_GHOST (ROUND_TIME < (GLOB.configuration.general.cryo_penalty_period)) +#define TOO_EARLY_TO_GHOST (ROUND_TIME < GLOB.configuration.general.cryo_penalty_period) // Used by radios to indicate that they have sent a message via something other than subspace #define RADIO_CONNECTION_FAIL 0 diff --git a/code/controllers/configuration/__config_defines.dm b/code/controllers/configuration/__config_defines.dm index 03d7622edd1..f5262401107 100644 --- a/code/controllers/configuration/__config_defines.dm +++ b/code/controllers/configuration/__config_defines.dm @@ -34,9 +34,7 @@ /// Wrapper to not overwrite a variable if a list key doesnt exist. Ensures target is a list. #define CONFIG_LOAD_LIST(target, input) \ - if(!isnull(input)) {\ - if(islist(input)) {\ - target = input\ - }\ + if(islist(input)) {\ + target = input\ } diff --git a/code/controllers/configuration/sections/gamemode_configuration.dm b/code/controllers/configuration/sections/gamemode_configuration.dm index 49ea008867e..9d7fb57858b 100644 --- a/code/controllers/configuration/sections/gamemode_configuration.dm +++ b/code/controllers/configuration/sections/gamemode_configuration.dm @@ -69,6 +69,7 @@ return new T() // Default to extended if it didnt work + stack_trace("Could not pick a gamemode. Defaulting to extended. (Attempted mode: [mode_name])") return new /datum/game_mode/extended() /datum/configuration_section/gamemode_configuration/proc/get_runnable_modes() @@ -80,7 +81,7 @@ qdel(M) continue - if(probabilities[M.config_tag]<=0) + if(probabilities[M.config_tag] <= 0) qdel(M) continue diff --git a/code/controllers/configuration/sections/ipintel_configuration.dm b/code/controllers/configuration/sections/ipintel_configuration.dm index 42bd988b818..89fa23d5307 100644 --- a/code/controllers/configuration/sections/ipintel_configuration.dm +++ b/code/controllers/configuration/sections/ipintel_configuration.dm @@ -2,7 +2,7 @@ /datum/configuration_section/ipintel_configuration /// Is IPIntel enabled var/enabled = FALSE - /// Arew we in whitelist mode (Auto-kick people who are on proxies/VPNs) + /// Are we in whitelist mode (Auto-kick people who are on proxies/VPNs) var/whitelist_mode = TRUE /// 0-1 float for percentage threshold to kick people out var/bad_rating = 0.9 diff --git a/code/controllers/configuration/sections/mc_configuration.dm b/code/controllers/configuration/sections/mc_configuration.dm index d8011587b6a..0a047b6ac4d 100644 --- a/code/controllers/configuration/sections/mc_configuration.dm +++ b/code/controllers/configuration/sections/mc_configuration.dm @@ -5,19 +5,19 @@ /// Tick limit % during world Init var/world_init_tick_limit = TICK_LIMIT_MC_INIT_DEFAULT /// Base MC tick rate - var/mc_base_tickrate = 1 + var/base_tickrate = 1 /// Highpop MC tickrate - var/mc_highpop_tickrate = 1.1 + var/highpop_tickrate = 1.1 /// MC Highpop enable threshold - var/mc_highpop_enable_threshold = 65 + var/highpop_enable_threshold = 65 /// MC Highpop disable threshold - var/mc_highpop_disable_threshold = 60 + var/highpop_disable_threshold = 60 /datum/configuration_section/mc_configuration/load_data(list/data) // Use the load wrappers here. That way the default isnt made 'null' if you comment out the config line CONFIG_LOAD_NUM(ticklag, data["ticklag"]) CONFIG_LOAD_NUM(world_init_tick_limit, data["world_init_mc_tick_limit"]) - CONFIG_LOAD_NUM(mc_base_tickrate, data["base_mc_tick_rate"]) - CONFIG_LOAD_NUM(mc_highpop_tickrate, data["highpop_mc_tick_rate"]) - CONFIG_LOAD_NUM(mc_highpop_enable_threshold, data["mc_highpop_threshold_enable"]) - CONFIG_LOAD_NUM(mc_highpop_disable_threshold, data["mc_highpop_threshold_disable"]) + CONFIG_LOAD_NUM(base_tickrate, data["base_mc_tick_rate"]) + CONFIG_LOAD_NUM(highpop_tickrate, data["highpop_mc_tick_rate"]) + CONFIG_LOAD_NUM(highpop_enable_threshold, data["mc_highpop_threshold_enable"]) + CONFIG_LOAD_NUM(highpop_disable_threshold, data["mc_highpop_threshold_disable"]) diff --git a/code/controllers/configuration/sections/vote_configuration.dm b/code/controllers/configuration/sections/vote_configuration.dm index ad9d458d970..92edd5abbb2 100644 --- a/code/controllers/configuration/sections/vote_configuration.dm +++ b/code/controllers/configuration/sections/vote_configuration.dm @@ -10,7 +10,7 @@ var/vote_time = 600 // 60 seconds /// Time before the first shuttle vote (deciseconds) var/autotransfer_initial_time = 72000 // 2 hours - /// Time between subsequent shuttle votes if the first one is not successful (dedicseconds) + /// Time between subsequent shuttle votes if the first one is not successful (deciseconds) var/autotransfer_interval_time = 18000 // 30 mins /// Prevent dead players from voting var/prevent_dead_voting = FALSE diff --git a/code/controllers/master.dm b/code/controllers/master.dm index 133b26dcbf0..d445cf6f3b6 100644 --- a/code/controllers/master.dm +++ b/code/controllers/master.dm @@ -626,10 +626,10 @@ GLOBAL_REAL(Master, /datum/controller/master) = new if(!processing) return var/client_count = length(GLOB.clients) - if(client_count < GLOB.configuration.mc.mc_highpop_disable_threshold) - processing = GLOB.configuration.mc.mc_base_tickrate - else if(client_count > GLOB.configuration.mc.mc_highpop_enable_threshold) - processing = GLOB.configuration.mc.mc_highpop_tickrate + if(client_count < GLOB.configuration.mc.highpop_disable_threshold) + processing = GLOB.configuration.mc.base_tickrate + else if(client_count > GLOB.configuration.mc.highpop_enable_threshold) + processing = GLOB.configuration.mc.highpop_tickrate /datum/controller/master/proc/formatcpu() switch(world.cpu) diff --git a/code/controllers/subsystem/shuttles.dm b/code/controllers/subsystem/shuttles.dm index 94267596ee0..dd308d9e7b1 100644 --- a/code/controllers/subsystem/shuttles.dm +++ b/code/controllers/subsystem/shuttles.dm @@ -1,7 +1,4 @@ #define CALL_SHUTTLE_REASON_LENGTH 12 -/// Time elapsed from roundstart before shuttle calls are allowed -#define SHUTTLE_REFUEL_DELAY 20 MINUTES - SUBSYSTEM_DEF(shuttle) name = "Shuttle" wait = 10 @@ -45,7 +42,7 @@ SUBSYSTEM_DEF(shuttle) var/list/hidden_shuttle_turfs = list() //all turfs hidden from navigation computers associated with a list containing the image hiding them and the type of the turf they are pretending to be var/list/hidden_shuttle_turf_images = list() //only the images from the above list /// Default refuel delay - var/refuel_delay = SHUTTLE_REFUEL_DELAY + var/refuel_delay = 20 MINUTES /datum/controller/subsystem/shuttle/Initialize(start_timeofday) ordernum = rand(1,9000) diff --git a/code/game/objects/explosion.dm b/code/game/objects/explosion.dm index 69074e479a9..8be822219c1 100644 --- a/code/game/objects/explosion.dm +++ b/code/game/objects/explosion.dm @@ -24,11 +24,11 @@ if(!ignorecap) // Clamp all values to MAX_EXPLOSION_RANGE - devastation_range = min (GLOB.configuration.general.bomb_cap / 4, devastation_range) - heavy_impact_range = min (GLOB.configuration.general.bomb_cap / 2, heavy_impact_range) - light_impact_range = min (GLOB.configuration.general.bomb_cap, light_impact_range) - flash_range = min (GLOB.configuration.general.bomb_cap, flash_range) - flame_range = min (GLOB.configuration.general.bomb_cap, flame_range) + devastation_range = min(GLOB.configuration.general.bomb_cap / 4, devastation_range) + heavy_impact_range = min(GLOB.configuration.general.bomb_cap / 2, heavy_impact_range) + light_impact_range = min(GLOB.configuration.general.bomb_cap, light_impact_range) + flash_range = min(GLOB.configuration.general.bomb_cap, flash_range) + flame_range = min(GLOB.configuration.general.bomb_cap, flame_range) var/max_range = max(devastation_range, heavy_impact_range, light_impact_range, flame_range) diff --git a/code/game/objects/structures/mirror.dm b/code/game/objects/structures/mirror.dm index 2873ac2a293..6efbb726cff 100644 --- a/code/game/objects/structures/mirror.dm +++ b/code/game/objects/structures/mirror.dm @@ -114,9 +114,9 @@ if("Body") var/list/race_list = list("Human", "Tajaran", "Skrell", "Unathi", "Diona", "Vulpkanin") - for(var/Spec in GLOB.whitelisted_species) - if(is_alien_whitelisted(H, Spec)) - race_list += Spec + for(var/species in GLOB.whitelisted_species) + if(is_alien_whitelisted(H, species)) + race_list += species var/datum/ui_module/appearance_changer/AC = ui_users[user] if(!AC) diff --git a/code/modules/admin/permissionverbs/permissionedit.dm b/code/modules/admin/permissionverbs/permissionedit.dm index 17d3e2c0fa3..86491bce349 100644 --- a/code/modules/admin/permissionverbs/permissionedit.dm +++ b/code/modules/admin/permissionverbs/permissionedit.dm @@ -52,7 +52,8 @@ usr << browse(output,"window=editrights;size=600x500") /datum/admins/proc/log_admin_rank_modification(adm_ckey, new_rank) - if(!GLOB.configuration.admin.use_database_admins) return + if(!GLOB.configuration.admin.use_database_admins) + return if(!usr.client) return diff --git a/code/modules/client/preference/preferences.dm b/code/modules/client/preference/preferences.dm index 1f23556f1ef..cd1d16ad196 100644 --- a/code/modules/client/preference/preferences.dm +++ b/code/modules/client/preference/preferences.dm @@ -1319,9 +1319,9 @@ GLOBAL_LIST_INIT(special_role_times, list( //minimum age (in days) for accounts var/list/new_species = list("Human", "Tajaran", "Skrell", "Unathi", "Diona", "Vulpkanin") var/prev_species = species - for(var/Spec in GLOB.whitelisted_species) - if(is_alien_whitelisted(user,Spec)) - new_species += Spec + for(var/species in GLOB.whitelisted_species) + if(is_alien_whitelisted(user, species)) + new_species += species species = input("Please select a species", "Character Generation", null) in sortTim(new_species, /proc/cmp_text_asc) var/datum/species/NS = GLOB.all_species[species] diff --git a/code/modules/mob/living/carbon/human/human.dm b/code/modules/mob/living/carbon/human/human.dm index b994d686b4e..a65d063d956 100644 --- a/code/modules/mob/living/carbon/human/human.dm +++ b/code/modules/mob/living/carbon/human/human.dm @@ -1936,5 +1936,3 @@ Eyes need to have significantly high darksight to shine unless the mob has the X to_chat(usr, "[src] does not have any stored infomation!") else to_chat(usr, "OOC Metadata is not supported by this server!") - - return