-
-
Notifications
You must be signed in to change notification settings - Fork 144
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[DRAFT] Implementing memory patches #160
Conversation
This will require change or rehaul in the future for sure, but its something we can use. |
This will be moved to managed code as we can have memory patches in managed code, I'll create a new pr later on |
I know this is already closed, but FYI I did test on my own server. it seem like the signature and patches can't be in other gamedata json file, except the main gamedata.json file |
this will be recreated in managed |
util related things and
CMemPatch
is borrowed from cs2fixesthis is a pretty wanky implementation, I think we should drop the gameconfig dependency from
CMemPatch
as thats why I made it like how it is currently.assume we have the following gamedata:
hotreloading the plugin will undo the patch, then perform it again:
also patches performed using the wrapper method is automatically reverted on unload:
Caution
Plugins that create their patches using the wrapper classes only and call
PerformPatch
are responsible for reverting the patch on unload. Creating patches withCreateMemoryPatch
will be automatically reverted.