initial commit

This commit is contained in:
nexusverypro
2026-07-03 02:00:27 +01:00
parent 85fa958433
commit 3192afe07d
18 changed files with 1592 additions and 0 deletions

View File

@@ -0,0 +1,24 @@
#include <cassert>
#include "radhook/radhook.h"
static int fn() { return 42; }
static int detour() { return 1337; }
using Fn = int(*)();
int main() {
RadHookHandle h = nullptr;
RadHookCreate((void*)fn, (void*)detour, &h);
assert(RadHookIsEnabled(h));
RadHookDisable(h);
assert(!RadHookIsEnabled(h));
RadHookEnable(h);
assert(RadHookIsEnabled(h));
RadHookDestroy(h);
return 0;
}