Darendor wrote:Well...I overwrote the text string for 1N, 1E at the location on the disk, but...it ignored what I put and loaded the original code...
How is that possible?
I put:
Code: Select all
0008e20: 6dfd 98fd 20fd 20fd 20fd 20fd 20fd d4e8 m... . . . . ...
0008e30: e5ao c2e1 f2e4 a7f3 aod4 e1ec e500 c2ef ................
You've accidentally got an 'o' (OH) in that line instead of a 0 (ZERO).
There is no other occurrance of the Wine cellar special text on the disk so I'm a little confused and frustrated right now.
That's weird. It should at least crash or something.
I managed to change the word 'This' to 'Here' (c8e5 f2e5) successfully, and got it to run.
Below is a quicky Python program I wrote that will either dump the "Bard's Tale Text" from a d64 disk image, or will convert a string of text into the hex codes for "Bard's Tale Text".
Code: Select all
import sys
Bytes_At_A_Time = 65
Min_Message_Len = 4
try:
fname = sys.argv[1]
except:
print >> sys.stderr, "usage: bttext.py d64_disk_file OR text"
sys.exit(1)
def to_str(byte):
o = byte - 128
if o >= ord(' ') and o < 127:
c = chr(o)
if c in "%=/~{}|@\\*^`":
return None
else:
return c
else:
return None
fp = 0
try:
data = file(fname, "rb")
message = []
bytes = data.read(Bytes_At_A_Time)
while bytes != '':
for byte in bytes:
fp += 1
c = to_str(ord(byte))
if c:
message.append(c)
else:
if len(message) >= Min_Message_Len:
print ''.join(message)
message = ['$%x: ' % fp]
bytes = data.read(Bytes_At_A_Time)
except IOError:
space = ''
for b in ''.join(sys.argv[1:]):
sys.stdout.write('%x%s' % (ord(b) + 128, space))
if space == ' ':
space = ''
else:
space = ' '
print
sys.exit(0)
Copy that program, and save it as bttext.py.
To dump all the text from the file BT1_dung.d64, you'd do:
c:\> python bttext.py bt1_dung.d64
To find out the correct hex codes for "IRKM DESMET DAEM", you'd do:
c:\> python byttext.py IRKM DESMET DAEM
Note that the last will not work if there's a file in the current directory named IRKM.