Merge pull request #10648 from Citadel-Station-13/kevinz000-patch-19
Sprinting in general is now a config
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
//config files
|
||||
#define CONFIG_GET(X) global.config.Get(/datum/config_entry/##X)
|
||||
#define CONFIG_SET(X, Y) global.config.Set(/datum/config_entry/##X, ##Y)
|
||||
#define CONFIG_GET_ENTRY(X) global.config.GetEntryDatum(/datum/config_entry/##X)
|
||||
|
||||
#define CONFIG_MAPS_FILE "maps.txt"
|
||||
|
||||
|
||||
@@ -193,6 +193,13 @@
|
||||
stat("[name]:", statclick)
|
||||
|
||||
/datum/controller/configuration/proc/Get(entry_type)
|
||||
var/datum/config_entry/E = GetEntryDatum(entry_type)
|
||||
if((E.protection & CONFIG_ENTRY_HIDDEN) && IsAdminAdvancedProcCall() && GLOB.LastAdminCalledProc == "Get" && GLOB.LastAdminCalledTargetRef == "[REF(src)]")
|
||||
log_admin_private("Config access of [entry_type] attempted by [key_name(usr)]")
|
||||
return
|
||||
return E.config_entry_value
|
||||
|
||||
/datum/controller/configuration/proc/GetEntryDatum(entry_type)
|
||||
var/datum/config_entry/E = entry_type
|
||||
var/entry_is_abstract = initial(E.abstract_type) == entry_type
|
||||
if(entry_is_abstract)
|
||||
@@ -200,10 +207,7 @@
|
||||
E = entries_by_type[entry_type]
|
||||
if(!E)
|
||||
CRASH("Missing config entry for [entry_type]!")
|
||||
if((E.protection & CONFIG_ENTRY_HIDDEN) && IsAdminAdvancedProcCall() && GLOB.LastAdminCalledProc == "Get" && GLOB.LastAdminCalledTargetRef == "[REF(src)]")
|
||||
log_admin_private("Config access of [entry_type] attempted by [key_name(usr)]")
|
||||
return
|
||||
return E.config_entry_value
|
||||
return E
|
||||
|
||||
/datum/controller/configuration/proc/Set(entry_type, new_val)
|
||||
var/datum/config_entry/E = entry_type
|
||||
|
||||
@@ -249,6 +249,18 @@
|
||||
|
||||
/datum/config_entry/number/movedelay/walk_delay
|
||||
|
||||
/datum/config_entry/number/movedelay/sprint_speed_increase
|
||||
config_entry_value = 1
|
||||
|
||||
/datum/config_entry/number/movedelay/sprint_buffer_max
|
||||
config_entry_value = 42
|
||||
|
||||
/datum/config_entry/number/movedelay/sprint_stamina_cost
|
||||
config_entry_value = 0.7
|
||||
|
||||
/datum/config_entry/number/movedelay/sprint_buffer_regen_per_ds
|
||||
config_entry_value = 0.3
|
||||
|
||||
/////////////////////////////////////////////////Outdated move delay
|
||||
/datum/config_entry/number/outdated_movedelay
|
||||
deprecated_by = /datum/config_entry/keyed_list/multiplicative_movespeed
|
||||
|
||||
Reference in New Issue
Block a user