summaryrefslogtreecommitdiff
path: root/cheat/gmod/prediction.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'cheat/gmod/prediction.hpp')
-rw-r--r--cheat/gmod/prediction.hpp27
1 files changed, 27 insertions, 0 deletions
diff --git a/cheat/gmod/prediction.hpp b/cheat/gmod/prediction.hpp
new file mode 100644
index 0000000..ca0fb93
--- /dev/null
+++ b/cheat/gmod/prediction.hpp
@@ -0,0 +1,27 @@
+#pragma once
+#include "util.hpp"
+
+class user_cmd_t;
+class c_base_player;
+
+NAMESPACE_REGION( features )
+
+class c_prediction {
+ user_cmd_t* m_ucmd{ };
+ int m_predicted_flags{ };
+
+ void run( user_cmd_t* ucmd );
+public:
+ void operator()( user_cmd_t* ucmd ) {
+ m_ucmd = ucmd;
+ run( m_ucmd );
+ }
+
+ int get_predicted_flags( ) const {
+ return m_predicted_flags;
+ }
+
+ void predict_player( c_base_player* player );
+};
+
+END_REGION \ No newline at end of file