summaryrefslogtreecommitdiff
path: root/extras
diff options
context:
space:
mode:
authorBryan Bishop <kanzure@gmail.com>2012-01-25 22:33:42 -0600
committerBryan Bishop <kanzure@gmail.com>2012-01-25 22:33:42 -0600
commit4f7a07efa9e93d491c6efcc14994b19cd794d3f6 (patch)
tree7dd66a02ea4993c4bfce1499d68ee2f192822a05 /extras
parent8cf4620deb07e53d7a419016080b8c10ed253733 (diff)
rename common.asm -> main.asm
hg-commit-id: adec8319c54b
Diffstat (limited to 'extras')
-rw-r--r--extras/analyze_incbins.py14
-rw-r--r--extras/insert_texts.py2
-rw-r--r--extras/make_map_size_constants.py4
-rw-r--r--extras/replace_dimensions.py2
-rw-r--r--extras/romvisualizer.py6
5 files changed, 14 insertions, 14 deletions
diff --git a/extras/analyze_incbins.py b/extras/analyze_incbins.py
index ef5405ef..3f0f9093 100644
--- a/extras/analyze_incbins.py
+++ b/extras/analyze_incbins.py
@@ -27,7 +27,7 @@ def offset_to_pointer(offset):
if type(offset) == str: offset = int(offset, base)
return int(offset) % 0x4000 + 0x4000
-def load_asm(filename="../common.asm"):
+def load_asm(filename="../main.asm"):
"loads the asm source code into memory"
global asm
asm = open(filename, "r").read().split("\n")
@@ -86,7 +86,7 @@ def process_incbins():
def find_incbin_to_replace_for(address):
"""returns a line number for which incbin to edit
- if you were to insert bytes into common.asm"""
+ if you were to insert bytes into main.asm"""
if type(address) == str: address = int(address, 16)
for incbin_key in processed_incbins.keys():
@@ -155,7 +155,7 @@ def generate_diff_insert(line_number, newline):
newfile_fh.close()
try:
- diffcontent = subprocess.check_output("diff -u ../common.asm " + newfile_filename, shell=True)
+ diffcontent = subprocess.check_output("diff -u ../main.asm " + newfile_filename, shell=True)
except AttributeError, exc:
raise exc
except Exception, exc:
@@ -195,7 +195,7 @@ def insert_map_header_asm(map_id):
fh.close()
#apply the patch
- os.system("patch ../common.asm temp.patch")
+ os.system("patch ../main.asm temp.patch")
#remove the patch
os.system("rm temp.patch")
@@ -230,8 +230,8 @@ def apply_diff(diff, try_fixing=True):
fh.close()
#apply the patch
- os.system("cp ../common.asm ../common1.asm")
- os.system("patch ../common.asm temp.patch")
+ os.system("cp ../main.asm ../main1.asm")
+ os.system("patch ../main.asm temp.patch")
#remove the patch
os.system("rm temp.patch")
@@ -242,7 +242,7 @@ def apply_diff(diff, try_fixing=True):
return True
except Exception, exc:
if try_fixing:
- os.system("mv ../common1.asm ../common.asm")
+ os.system("mv ../main1.asm ../main.asm")
return False
def index(seq, f):
diff --git a/extras/insert_texts.py b/extras/insert_texts.py
index 30163b4d..c3133bf8 100644
--- a/extras/insert_texts.py
+++ b/extras/insert_texts.py
@@ -610,7 +610,7 @@ def scan_for_map_scripts_pointer():
def scan_rom_for_tx_fars_and_insert():
"""calls analyze_texts.scan_rom_for_tx_fars()
- looks through INCBIN'd addresses from common.asm,
+ looks through INCBIN'd addresses from main.asm,
finds TX_FARs that aren't included yet.
"""
x = 0
diff --git a/extras/make_map_size_constants.py b/extras/make_map_size_constants.py
index c40a4514..c4b13da7 100644
--- a/extras/make_map_size_constants.py
+++ b/extras/make_map_size_constants.py
@@ -23,8 +23,8 @@ def get_map_size_constants(do_sed=False):
output += constant_name + "_WIDTH EQU $%.2x\n" % (width)
output += "\n"
- sed_lines += "sed -i 's/" + base_name + "Height/" + constant_name + "_HEIGHT" + "/g' common.asm" + "\n"
- sed_lines += "sed -i 's/" + base_name + "Width/" + constant_name + "_WIDTH" + "/g' common.asm" + "\n"
+ sed_lines += "sed -i 's/" + base_name + "Height/" + constant_name + "_HEIGHT" + "/g' main.asm" + "\n"
+ sed_lines += "sed -i 's/" + base_name + "Width/" + constant_name + "_WIDTH" + "/g' main.asm" + "\n"
if do_sed:
return sed_lines
diff --git a/extras/replace_dimensions.py b/extras/replace_dimensions.py
index 9d4df895..cdd72906 100644
--- a/extras/replace_dimensions.py
+++ b/extras/replace_dimensions.py
@@ -39,7 +39,7 @@ asm = None
asm_lines = None
def load_asm():
global asm, asm_lines
- asm = open("../common.asm", "r").read()
+ asm = open("../main.asm", "r").read()
asm_lines = asm.split("\n")
def get_xy_movement_of_connection_strip(map_id, connection_id):
diff --git a/extras/romvisualizer.py b/extras/romvisualizer.py
index 7e80f786..b3fd7cd5 100644
--- a/extras/romvisualizer.py
+++ b/extras/romvisualizer.py
@@ -6,12 +6,12 @@ import os
changeset_numbers = range(266, 635)
def take_snapshot_image(changeset_number):
- "turn common.asm into an image at a certain version"
+ "turn main.asm into an image at a certain version"
- print "reverting common.asm to r" + str(changeset_number)
+ print "reverting main.asm to r" + str(changeset_number)
#revert the file
- os.system("hg revert ../common.asm -r" + str(changeset_number))
+ os.system("hg revert ../main.asm -r" + str(changeset_number))
print "generating the image.."