mirror of
https://github.com/thornAvery/kep-hack.git
synced 2026-02-06 15:45:24 +13:00
insert labels for map texts pointer lists
hg-commit-id: f374e6e126d7
This commit is contained in:
parent
be26f828bd
commit
dc0af17185
3 changed files with 130 additions and 44 deletions
|
|
@ -223,13 +223,17 @@ def apply_diff(diff):
|
|||
fh.close()
|
||||
|
||||
#apply the patch
|
||||
os.system("cp ../pokered.asm ../pokered1.asm")
|
||||
os.system("patch ../pokered.asm temp.patch")
|
||||
|
||||
#remove the patch
|
||||
os.system("rm temp.patch")
|
||||
|
||||
#confirm it's working
|
||||
subprocess.check_call("cd ../; make clean; LC_CTYPE=UTF-8 make", shell=True)
|
||||
try:
|
||||
subprocess.check_call("cd ../; make clean; LC_CTYPE=UTF-8 make", shell=True)
|
||||
except Exception, exc:
|
||||
os.system("mv ../pokered1.asm ../pokered.asm")
|
||||
|
||||
if __name__ == "__main__":
|
||||
#load map headers
|
||||
|
|
|
|||
|
|
@ -174,7 +174,7 @@ def insert_texts_label(map_id):
|
|||
diff = generate_diff_insert(line_number, newlines)
|
||||
print "working on map_id=" + str(map_id) + " texts_pointer=" + hex(texts_pointer)
|
||||
print diff
|
||||
#apply_diff(diff)
|
||||
apply_diff(diff)
|
||||
|
||||
#untested as of 2012-01-07
|
||||
def insert_all_texts_labels():
|
||||
|
|
@ -305,7 +305,7 @@ if __name__ == "__main__":
|
|||
# texts_label_pretty_printer(map_id)
|
||||
|
||||
#insert_texts_label(240)
|
||||
#insert_all_texts_label()
|
||||
insert_all_texts_labels()
|
||||
|
||||
#insert_text_label_tx_far(240, 1)
|
||||
insert_all_text_labels()
|
||||
#insert_all_text_labels()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue