summaryrefslogtreecommitdiff
path: root/cheat/tf2/process_movement.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'cheat/tf2/process_movement.cpp')
-rw-r--r--cheat/tf2/process_movement.cpp12
1 files changed, 12 insertions, 0 deletions
diff --git a/cheat/tf2/process_movement.cpp b/cheat/tf2/process_movement.cpp
new file mode 100644
index 0000000..c6f186e
--- /dev/null
+++ b/cheat/tf2/process_movement.cpp
@@ -0,0 +1,12 @@
+#include "hooks.h"
+#include "interfaces.h"
+
+void __fastcall hooks::process_movement( void* thisptr, void* edx_, c_base_player* player, CMoveData* move ) {
+ static auto old_fn = cl.m_movement->get_old_function< decltype( hooks::process_movement )* >( 1 );
+
+ if ( cl.m_input( )->IsButtonDown( MOUSE_MIDDLE ) ) {
+ move->m_outStepHeight = -1.0f;
+ }
+
+ return old_fn( thisptr, edx_, player, move );
+} \ No newline at end of file