summaryrefslogtreecommitdiffstats
path: root/src/menu.cpp
diff options
context:
space:
mode:
authorsalmonik <salmonik@tuta.io>2026-10-28 12:42:46 +0100
committersalmonik <salmonik@tuta.io>2026-10-28 12:42:46 +0100
commit2eda18951fde7ebd803aeb48595f203c0bb2f82a (patch)
tree01b93c7ceb45c29652ccf261aa63faaa9a85fec4 /src/menu.cpp
parentLogging: per-session file and debug-gated verbose logs (diff)
downloadhl2h-2eda18951fde7ebd803aeb48595f203c0bb2f82a.tar.gz
hl2h-2eda18951fde7ebd803aeb48595f203c0bb2f82a.zip
Item ESP: make 0 = unlimited explicit and persistent
- config_load now accepts max_dist=0 instead of clamping it to 250, so the "unlimited" setting survives a restart. - The Max distance slider shows "All" at 0 and its tooltip documents 0 = unlimited; the categories log prints max=All. - Skip unclassified entities before projecting them / computing distance. - Keep the removed prop/crate debug logging and the user's rule that the distance slider applies to every tag.
Diffstat (limited to 'src/menu.cpp')
-rw-r--r--src/menu.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/menu.cpp b/src/menu.cpp
index 6d7143d..2d4c660 100644
--- a/src/menu.cpp
+++ b/src/menu.cpp
@@ -280,7 +280,7 @@ static bool config_load() {
280 g_item_distance = atoi(val) != 0; 280 g_item_distance = atoi(val) != 0;
281 else if (strcmp(key, "max_dist") == 0) { 281 else if (strcmp(key, "max_dist") == 0) {
282 int v = atoi(val); 282 int v = atoi(val);
283 if (v < 250) v = 250; 283 if (v < 0) v = 0; // 0 = unlimited
284 if (v > 10000) v = 10000; 284 if (v > 10000) v = 10000;
285 g_item_max_dist = v; 285 g_item_max_dist = v;
286 } 286 }