02-21-2005, 03:08 PM
Lillo, this one's for you
I was tinkering around after the last little problem I had (you know, with the pointers and PUT, which by the way, your suggestion worked, but it's not as pretty as @variable) Anyway, I was playing with bload, since it's a nice way of doing a background image.
I had a loop of code, which basically exits on ESC
Anyway, I compile this. No problems here.
However, when I run it, I get a nasty little error. I couldn't tell you what it is, because WinXP doesn't just come out and say "tried to write to 0x0000" or whatever.
I included the thing just before the DO loop starts because I wonder if that has to do with the problem, but it might not. Anyway, try to ignore the syntax if I screwed up (I just typed it from memory)
In short, it seems like repeatedly using BLOAD to load the same image file at the screen's address causes a runtime error.
I was tinkering around after the last little problem I had (you know, with the pointers and PUT, which by the way, your suggestion worked, but it's not as pretty as @variable) Anyway, I was playing with bload, since it's a nice way of doing a background image.
I had a loop of code, which basically exits on ESC
Quote:''This is to load the file into a sprite array.
BLOAD "image.raw", spritearray
DO
''Do stuff
BLOAD "image.raw", 0 ''This is essential a call to load a background onto the screen. Works properly if called only once.
''Do more stuff, like sprite placement
''Check the keyboard for ESC
LOOP UNTIL keyboard = chr$(27)
Anyway, I compile this. No problems here.
However, when I run it, I get a nasty little error. I couldn't tell you what it is, because WinXP doesn't just come out and say "tried to write to 0x0000" or whatever.
I included the thing just before the DO loop starts because I wonder if that has to do with the problem, but it might not. Anyway, try to ignore the syntax if I screwed up (I just typed it from memory)
In short, it seems like repeatedly using BLOAD to load the same image file at the screen's address causes a runtime error.