From 49df428d95a7c443d418d5b7e2a93af599b54f76 Mon Sep 17 00:00:00 2001 From: salmonik Date: Wed, 4 Nov 2026 17:51:20 +0100 Subject: Add chams - Hook IVModelRender::DrawModelExecute (VEngineModel016 slot 19) and force models/debug/debugwhite for NPC models, identified by ModelRenderInfo_t::entity_index. - Two passes: MATERIAL_VAR_IGNOREZ through walls, then normal depth, with IMaterial::ColorModulate for the configured colour; restore the shared material's flag/colour afterwards. - Material lookup via the IMaterialSystem list, FindMaterial fallback. - New Chams feature/card with Through walls and colour; [chams] config. - Remove the temporary ammo/projectile/fuse diagnostics. --- src/hl2h.h | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'src/hl2h.h') diff --git a/src/hl2h.h b/src/hl2h.h index d8927c7..55fac0d 100644 --- a/src/hl2h.h +++ b/src/hl2h.h @@ -68,6 +68,7 @@ struct GameInterfaces { void *debugoverlay = nullptr; // IVDebugOverlay003 (engine-accurate world->screen) void *enginetrace = nullptr; // EngineTraceClient003 (world vischeck) void *cvar = nullptr; // VEngineCvar004 (mat_fullbright etc.) + void *modelrender = nullptr; // VEngineModel016 (chams) }; extern GameInterfaces g_iface; @@ -189,7 +190,8 @@ enum FeatureId { FEAT_FOG = 12, FEAT_SKYBOX = 13, FEAT_PROJECTILES = 14, - FEAT_COUNT = 15 + FEAT_CHAMS = 15, + FEAT_COUNT = 16 }; enum EspOption { ESP_OPT_SHOW_NEUTRAL = 0, @@ -226,8 +228,10 @@ struct FeatureState { extern FeatureState g_bhop, g_abh, g_jumpbug, g_melee, g_spread, g_esp, g_aimbot, g_triggerbot, g_silentaim, g_item_esp, g_fullbright, - g_world_tint, g_fog, g_skybox, g_projectiles; + g_world_tint, g_fog, g_skybox, g_projectiles, g_chams; extern bool g_proj_fuse, g_proj_radius; +extern bool g_chams_walls; +extern int g_chams_rgb[3]; extern bool g_tint_world_on, g_tint_sky_on, g_tint_prop_on; extern int g_tint_world_rgb[3], g_tint_sky_rgb[3], g_tint_prop_rgb[3]; extern bool g_fog_skybox, g_fog_disable; @@ -329,6 +333,9 @@ bool aimbot_fov_circle(); void aimbot_reset_lock(); void silentaim_reset_lock(); void *entitylist_get(int idx); +bool esp_is_npc_index(int idx); +void *world_find_material(const char *name); +void chams_init(); int engine_get_local_player(); void draw_text_col(int x, int y, const char *s, int r, int g, int b); void draw_text_small_col(int x, int y, const char *s, int r, int g, int b); -- cgit v1.2.3