ref: 3cf6603b455530fa0c17e946118484a0126e2bf9
parent: 82d723840b14fc6b55c00f107a453bc0b0d80772
author: yenatch <[email protected]>
date: Tue May 14 17:50:43 EDT 2013
gbz80disasm: space out blocks of asm
--- a/extras/gbz80disasm.py
+++ b/extras/gbz80disasm.py
@@ -635,6 +635,7 @@
if offset in byte_labels.keys():
line_label = byte_labels[offset]["name"]
byte_labels[offset]["usage"] += 1
+ output += "\n"
else:
line_label = asm_label(offset)
byte_labels[offset] = {}
@@ -819,6 +820,9 @@
#offset += 1
#current_byte_number += 1
+ if current_byte in relative_unconditional_jumps + end_08_scripts_with:
+ output += "\n"
+
first_loop = False
#clean up unused labels
@@ -827,6 +831,9 @@
label_line = byte_labels[label_line]
if label_line["usage"] == 0:
output = output.replace((label_line["name"] + "\n").lower(), "")
+
+ #tone down excessive spacing
+ output = output.replace("\n\n\n","\n\n")
#add the offset of the final location
if include_last_address: