From a MSYS2 shell, switch to the UCRT64 environment and install prerequisites
# source shell ucrt64
# pacman -Syu --needed mingw-w64-ucrt-x86_64-toolchain vimCompile standalone.cc to an object file
From a MSYS2 shell, switch to the UCRT64 environment and install prerequisites
# source shell ucrt64
# pacman -Syu --needed mingw-w64-ucrt-x86_64-toolchain vimCompile standalone.cc to an object file
| inline void**& GetVirtualTable(void* baseclass) { | |
| return *reinterpret_cast<void***>(baseclass); | |
| } | |
| inline void* GetVirtualFunction(void* vftable, size_t index) { | |
| return reinterpret_cast<void*>(GetVirtualTable(vftable)[index]); | |
| } | |
| template <typename Fn> inline Fn GetVirtualFunction(void* vftable, size_t index) { | |
| return reinterpret_cast<Fn>(GetVirtualTable(vftable)[index]); |
| #!/bin/node | |
| const fs = require("fs"); | |
| const path = require("path"); | |
| const async = require("async"); | |
| const mkdirp = require("mkdirp"); | |
| const minimist = require("minimist"); | |
| const child_process = require("child_process"); | |
| var argv = minimist(process.argv.slice(2)); |
I hereby claim:
To claim this, I am signing this object:
| // Find the pointer to 'InterfaceReg::s_pInterfaceRegs' - works on Valve game libraries. (32-bit) | |
| uintptr_t interface_list_addr = FindPattern("bin/client.so", "89 10 8B 15 ? ? ? ? A3") + 4; | |
| InterfaceReg* interface_list = **reinterpret_cast<InterfaceReg***>(interface_list_addr); | |
| for (InterfaceReg* current = interface_list; current; current = current->m_pNext) { | |
| printf("* %s => 0x%x\n", current->m_pName, current->m_CreateFn()); | |
| } |
| inline uintptr_t GetAbsoluteAddress(uintptr_t instruction_ptr, int offset, int size) { | |
| return instruction_ptr + *reinterpret_cast<int32_t*>(instruction_ptr + offset) + size; | |
| }; |