Skip to content

Instantly share code, notes, and snippets.

@Gladuin
Last active October 31, 2020 23:55
Show Gist options
  • Save Gladuin/c9d36bff83dbc742decd320bcf2b9eaa to your computer and use it in GitHub Desktop.
Save Gladuin/c9d36bff83dbc742decd320bcf2b9eaa to your computer and use it in GitHub Desktop.
import json
import io
import sys
json = json.load(open(sys.argv[1], "r"))
for patch_info in json:
print("# " + patch_info["name"])
#print("# " + patch_info["description"])
for patches in patch_info["patches"]:
print(patches["dllName"], end=" ")
# mempatch-hook expects base address + 0xC00
print(format(int(patches["dataOffset"]) + 3072, "X"), end=" ")
print(patches["dataEnabled"], end=" ")
print(patches["dataDisabled"])
print()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment