From d7201a987ba6cc56fda3d3ea69275307385f7c3e Mon Sep 17 00:00:00 2001 From: salmonik Date: Wed, 4 Nov 2026 18:43:28 +0100 Subject: Chams: preload style materials outside the model draw FindMaterial inside DrawModelExecute did not load the style VMTs, so every style fell back to the solid material. Preload the six style materials from outer_draw (throttled) and have the render hook use the cached pointers only. world_find_material now returns only the exact requested material; the caller falls back to the solid style. Add a vgui/white probe and per-style preload logs. --- src/menu.cpp | 1 + 1 file changed, 1 insertion(+) (limited to 'src/menu.cpp') diff --git a/src/menu.cpp b/src/menu.cpp index 376a779..6a3c607 100644 --- a/src/menu.cpp +++ b/src/menu.cpp @@ -999,6 +999,7 @@ void outer_draw() { world_tint_update(); prop_tint_update(); fog_update(); + chams_preload(); gui_handle_input(); // HL2H_DRAW_TEST=1 draws a probe rect without needing the GUI open static bool draw_test = getenv("HL2H_DRAW_TEST") != nullptr; -- cgit v1.2.3