From ea4b9d1f6de4c0c781a48999e793a5bf976c2b38 Mon Sep 17 00:00:00 2001 From: salmonik Date: Wed, 4 Nov 2026 19:17:12 +0100 Subject: Chams: keep additive viewmodel visible on bright backgrounds Viewmodels are collated as RENDER_GROUP_VIEW_MODEL_OPAQUE, so an additive forced material can vanish against a bright sky/wall (additive adds nothing to an already-bright surface). Draw a dim opaque solid base before the additive viewmodel pass so the first-person model always has a visible silhouette; the additive layer still provides the glow. --- CONTEXT.md | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'CONTEXT.md') diff --git a/CONTEXT.md b/CONTEXT.md index ad9ce2d..c75e36c 100644 --- a/CONTEXT.md +++ b/CONTEXT.md @@ -307,6 +307,11 @@ vocabulary / decisions. VGUI additive material was invisible on NPCs. - Style materials are preloaded from `outer_draw` (throttled) and cached; the render hook never calls FindMaterial itself. A missing style uses solid. +- Viewmodels are collated by the engine as `RENDER_GROUP_VIEW_MODEL_OPAQUE`, + so an additive forced material can wash out against a bright sky or wall + (and the engine may not treat the draw as translucent). Additive styles on + the viewmodel therefore draw a dim opaque solid base first, then the + additive pass; the first-person model never disappears. - Feature is off by default. Config sections: `[chams]` (active/bind), `[chams_hostile|neutral|friendly]` (`vis`, `vis_mat`, `vis_r/g/b`, `inv`, `inv_mat`, `inv_r/g/b`) and `[chams_vm]` (`on`, `mat`, `r/g/b`). The GUI has -- cgit v1.2.3