From e339d1dc45b3113648552b0002e0c15f55e61cb2 Mon Sep 17 00:00:00 2001 From: salmonik Date: Fri, 6 Nov 2026 16:30:10 +0100 Subject: Config: generate save/load/reset from one settings table Every persisted setting now lives in a single descriptor table (config_table.cpp) with its section, key, type, default and clamp range. config_save(), config_load() and config_reset_defaults() iterate it, so the three functions can no longer disagree about defaults or bounds, and the old hand-written 350-line parser is gone. Section and key names are unchanged, so existing config files keep loading, and the duplicated [view] scalar clamp block is replaced by per-entry limits. --- src/features.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/features.h') diff --git a/src/features.h b/src/features.h index 6890aa6..b4616a1 100644 --- a/src/features.h +++ b/src/features.h @@ -133,4 +133,9 @@ QAngle gui_frozen_view(); void gui_config_init(); void gui_config_write(FILE *f); +// Declarative settings persistence (config_table.cpp). +void settings_save(FILE *f); +void settings_load(FILE *f); +void settings_reset_defaults(); + #endif -- cgit v1.2.3