summaryrefslogtreecommitdiffstats
path: root/src/hl2h.cpp
diff options
context:
space:
mode:
authorsalmonik <salmonik@tuta.io>2026-10-26 17:30:29 +0100
committersalmonik <salmonik@tuta.io>2026-10-26 17:30:29 +0100
commit92d388116cc19ef728d66ac67eaa4f584e63d895 (patch)
tree5b9438cf8c2f1b4f01eef3eec4a6d91b42ac1acb /src/hl2h.cpp
parentTriggerbot: crosshair entity trace, hostile-only (diff)
downloadhl2h-92d388116cc19ef728d66ac67eaa4f584e63d895.tar.gz
hl2h-92d388116cc19ef728d66ac67eaa4f584e63d895.zip
Silent aim: exact usercmd angle + fire, restore rendered view
- new top-level Silent aim feature (Active + Bind, default Mouse3) - reuses the shared aim-target selection (bone checklist, nearest selected point, world-only MASK_VISIBLE vischeck) - writes the exact target angle into cmd->viewangles, sets IN_ATTACK for the shot, then immediately restores engine view angles to the player's input view (g_cam_view) so the camera stays where it was - shares the vischeck/bone selection with the aimbot; independent of the aimbot/triggerbot binds - config [silentaim] active/bind
Diffstat (limited to '')
-rw-r--r--src/hl2h.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/hl2h.cpp b/src/hl2h.cpp
index 7a7d32e..89d6b89 100644
--- a/src/hl2h.cpp
+++ b/src/hl2h.cpp
@@ -262,6 +262,13 @@ static void do_move(int seq) {
262 note_modified(cmd, flags, vel); 262 note_modified(cmd, flags, vel);
263 } 263 }
264 } 264 }
265
266 if (feature_active(FEAT_SILENTAIM)) {
267 if (silent_aim_apply(cmd)) {
268 const float *vel = (const float *)(e + g_net.velocity);
269 note_modified(cmd, flags, vel);
270 }
271 }
265} 272}
266 273
267// --------------------------------------------------------------------------- 274// ---------------------------------------------------------------------------