summaryrefslogtreecommitdiff
path: root/util
diff options
context:
space:
mode:
authorAjarmar <axel.jarmar@gmail.com>2019-10-08 16:42:18 +0200
committerAjarmar <axel.jarmar@gmail.com>2019-10-08 16:42:18 +0200
commit1893151ea8ebfc96f3c7bf310dee8a9640fc6972 (patch)
treec7a6e501287eef510c6cab319a7fd8874ff52156 /util
parent36f65099bd3d1f670c07df3836c69a0a147aaf22 (diff)
allow input arguments for rom byte reader
Diffstat (limited to 'util')
-rw-r--r--util/rom_byte_reader.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/util/rom_byte_reader.py b/util/rom_byte_reader.py
index ed52be6..eb6e4c3 100644
--- a/util/rom_byte_reader.py
+++ b/util/rom_byte_reader.py
@@ -2,7 +2,7 @@
"""
@author: cleartonic
"""
-import os, binascii
+import os, binascii, sys
# Variables
@@ -11,7 +11,10 @@ import os, binascii
buffer_size = 512
# Redefine input path
-input_file = os.path.join("Pokemon Black.nds")
+if len(sys.argv) >= 2:
+ input_file = sys.argv[1]
+else:
+ input_file = os.path.join("Pokemon Black.nds")
# below list corresponds to Castelia bottom shop first few items
list_of_items = [