ref: 8cfa4bee12b21f7af94bd368165b3b599d18997c
parent: ad0f365a372d227cf050b2c1016bda5f9b9f80c6
author: Bryan Bishop <[email protected]>
date: Sun Mar 11 23:17:39 EDT 2012
fix calculate_pointer again
--- a/extras/crystal.py
+++ b/extras/crystal.py
@@ -366,7 +366,7 @@
def calculate_pointer(short_pointer, bank=None):
"""calculates the full address given a 4-byte pointer and bank byte"""
short_pointer = int(short_pointer)
- if short_pointer > 0x4000:
+ if 0x4000 <= short_pointer <= 0x7fff:
short_pointer -= 0x4000
bank = int(bank)
else:
@@ -2885,7 +2885,7 @@
script = parse_script_engine_script_at(ptr_address, map_group=map_group, map_id=map_id)
extra_portion = {
"script_address": ptr_address,
- #"script": script,
+ "script": script,
"event_type": "script",
}
if is_give_item: