aboutsummaryrefslogtreecommitdiff
path: root/VmtHook.h
diff options
context:
space:
mode:
authorBDKPlayer <fabian.stotz@yahoo.de>2020-04-01 20:57:35 +0200
committerBDKPlayer <fabian.stotz@yahoo.de>2020-04-01 20:57:35 +0200
commitd0f91aed16a1cb40df6e1ab7c19b17410888906d (patch)
tree401f2a4d5690b03f22e11212832dbe1693404536 /VmtHook.h
parent1d8b290947b6b94f75eebc72a6becf6278729925 (diff)
Removed detours dependency
Diffstat (limited to 'VmtHook.h')
-rw-r--r--VmtHook.h20
1 files changed, 20 insertions, 0 deletions
diff --git a/VmtHook.h b/VmtHook.h
new file mode 100644
index 0000000..9304602
--- /dev/null
+++ b/VmtHook.h
@@ -0,0 +1,20 @@
+#pragma once
+
+#include <Windows.h>
+#include <map>
+
+
+class VmtHook
+{
+private:
+ void** vmt;
+ std::map<int, void*> hookedfuncs;
+
+public:
+ VmtHook(void** vmt);
+
+ void* Hook(int index, void* hookedFunction);
+
+ bool Unhook(int index);
+ void Unhook();
+};