ScrapHacks/ScrapHacks/README.md

65 lines
1.5 KiB
Markdown
Raw Permalink Normal View History

## Features
- read and write memory
- disassemble memory (using zydis)
- change DirectX state
- Draw DirectX overlay (still need to make a useful overlay)
- Dump various data structures to the console
- Assemble and execute code on the fly (using asmtk)
- Can be controlled via keyboard shortcuts (TODO: allow defining own shortcuts for commands)
## Prerequisites
- Visual Studio 2017/2019 (others might work)
- CMake
- Python 3.6 or newer
## Building
2019-12-04 00:21:51 +00:00
Open VS 32-bit command prompt (`vcvars32.bat`) and run the following two commands
2019-02-23 21:44:33 +00:00
2019-09-01 20:45:07 +00:00
```batch
2019-12-04 00:21:51 +00:00
cmake -G"NMake Makefiles" -B build
cmake --build build --target install
2019-02-28 16:50:52 +00:00
```
2019-09-01 20:45:07 +00:00
This will find the Games's installation folder, verify that the version you have is compatible with ScrapHacks and drop the compiled `.pyd` file into the correct folder to be imported
## Getting started
2019-11-20 19:48:15 +00:00
- open the ingame console (Ctrl+^)
- type `import ScrapHack`
2019-12-04 00:21:51 +00:00
- type `$help`
## Config file keys (not yet implemented?)
- patches.asm: map of address->list of assembly instructions
- patches.hex: map of address->hex bytes
2019-11-20 19:48:15 +00:00
Example:
```json
{
"patches": {
"hex": {
"0xDEADBEEF": "BADFOODDEADFEED"
},
"asm": {
"0xBADF00D": [
"pushad",
"call 0xf00dbabe",
"popad",
"mov eax, 0x42",
"ret"
]
},
}
}
```
## Third-Party components used
- Zydis disassembler
- asmJIT/asmTK assembler
- nlohmann/json JSON-parser
- LIEF/lief