Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //0x136B7F
- typedef int(__stdcall *object_set_position)(int dataum, int a2, int a3, int a4, int a5);
- object_set_position object_set_position_method;
- DWORD afterJmpAddr;
- int dataum, upAngles, positionPtr, forwardPtr, a5;
- void cave() {
- TRACE_GAME("hooked, dataum=%d, positionPtr=%d", dataum, positionPtr);
- }
- __declspec(naked) void objectSetPosition() {
- afterJmpAddr = (DWORD)(h2mod->GetBase() + 0x136B87);
- __asm{
- mov eax, [esp+0x4]
- mov dataum, eax
- mov ecx, [esp+0x18]
- mov positionPtr, ecx
- }
- cave();
- __asm {
- mov eax, [esp+0x14]
- mov ecx, [esp+0x8]
- jmp afterJmpAddr
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement