Can you Store more than one Bsaved sprite per file, if so how do you put it/retrive it using BSAVE/BLOAD. Also how do you find the sprite size needed for loading by using the LOF() command...Any source would be helpful too. Thanks.
The reason I want this because I don't want 50 .mit files (my BSAVE/BLOAD file type) in my .zip with my .exe program and my .txt files. Wow that's a rainbow of files! He he!
PP256 stores more than one pic per file,.. but how I don't know... You could have the pics put in a dir file,. and load from there givin the dir file is in the same dir as the .EXE... great way to organize tell you get the info you need..
screen 13
dim array(104) ' enough for 2 gets
'GFX STUFF HERE
get(0, 0)-(9, 9), array(0)
'SECOND PIC GFX STUFF HERE
get(0, 0)-(9, 9), array(53)
'bsave like you always do
Thats how to save. To load, do the same. To put the first pic, though, you do
Grumble Grumble, Ya I guess I did...just kidding lol ...
Now for the bonus points and all the crackers in the cracker jacks...answer me this one question HOW THE HECK TO YOU KNOW WHAT ELEMENT IN THE ARRAY BEGINS ONE PIC AND WHAT ELEMENT DOES ANOTHER PIC?!
ie. image(0) = first pic
image(53) = second pic
How do you calculate the 53? I what I'm asking....if its not too much trouble...
For a single sprite, L * H / 2 + 1 works fine. But when you need to do exact offsets for multiple sprites, L * W / 2 + 2 is the value you use for the offset. That method only works for arrays with all the same sized images though...for arrays with sprites of multiple sizes, you'd be better off making a seperate array, one element per image in your sprite array, that keeps track of the indexes of each image. Of course, to get the indexes, you have to scan through the array and determine how large each image is, then figure out the offset for each one.