Meta: Add files to repository

This commit is contained in:
Alec Murphy 2025-03-25 07:32:23 -04:00
parent 80a0428b66
commit 39198164cd
1029 changed files with 78311 additions and 0 deletions

View file

@ -0,0 +1,28 @@
U0 @function_insert_call(U32 from, U32 to)
{
*(from(U8*)) = 0xE8;
*((from + 1)(I32*)) = to - from - 5;
}
U0 @function_patch(U32 from, U32 to)
{
*(from(U8*)) = 0xE9;
*((from + 1)(I32*)) = to - from - 5;
}
class @function
{
U0(*InsertCall)
(U32 from, U32 to);
U0(*Patch)
(U32 from, U32 to);
};
@function Function;
Function.InsertCall = &@function_insert_call;
Function.Patch = &@function_patch;
// usage: Function.InsertCall(addr, &func);
// usage: Function.Patch(&old_func, &new_func);
"function ";