Following the advice of many people, I've decided to try and implement BSave/Bload in my mapping technique (read my last post if you're not sure). Anyway, to get straight to the point...I wrote a program to BSave. Then I tried BLoading it in another program. However my 10x10 sprite only loaded 10x3. So I tried BLoading in the same program, and it loaded the entire sprite. What's up w/ this? I included the code for both programs.
Program 1:
DIM floor(50)
CHDIR "C:\qbasic\GFXFiles"
ON ERROR GOTO Handler
SCREEN 13
FOR y = 1 TO 10
FOR x = 1 TO 10
READ clr
PSET (x, y), clr
NEXT: NEXT
GET (0, 0)-(10, 10), floor
CLS
DEF SEG = VARSEG(floor(0))
CHDIR "gfx"
BSAVE "floor.gfx", 0, 50
DEF SEG
DATA 07,08,08,08,08,08,08,08,08,08
DATA 08,07,07,07,07,07,07,07,07,07
DATA 08,07,07,01,07,07,07,07,07,07
DATA 08,07,07,02,07,07,07,07,07,07
DATA 08,07,07,03,07,07,07,07,07,07
DATA 08,07,07,04,07,07,07,07,07,07
DATA 08,07,07,05,07,07,07,07,07,07
DATA 08,07,07,06,07,07,07,07,07,07
DATA 08,07,07,08,07,07,07,07,07,07
DATA 08,07,07,09,07,07,07,07,07,07
Handler:
SELECT CASE ERR
CASE 76
MKDIR "gfx"
RESUME
END SELECT
Program 2:
DIM floor(50)
SCREEN 13
DEF SEG = VARSEG(floor(0))
CHDIR "C:\qbasic\GFXFiles\gfx"
BLOAD "floor.gfx", 0
DEF SEG
PUT (0, 0), floor, PSET
Please help -Mike
Program 1:
DIM floor(50)
CHDIR "C:\qbasic\GFXFiles"
ON ERROR GOTO Handler
SCREEN 13
FOR y = 1 TO 10
FOR x = 1 TO 10
READ clr
PSET (x, y), clr
NEXT: NEXT
GET (0, 0)-(10, 10), floor
CLS
DEF SEG = VARSEG(floor(0))
CHDIR "gfx"
BSAVE "floor.gfx", 0, 50
DEF SEG
DATA 07,08,08,08,08,08,08,08,08,08
DATA 08,07,07,07,07,07,07,07,07,07
DATA 08,07,07,01,07,07,07,07,07,07
DATA 08,07,07,02,07,07,07,07,07,07
DATA 08,07,07,03,07,07,07,07,07,07
DATA 08,07,07,04,07,07,07,07,07,07
DATA 08,07,07,05,07,07,07,07,07,07
DATA 08,07,07,06,07,07,07,07,07,07
DATA 08,07,07,08,07,07,07,07,07,07
DATA 08,07,07,09,07,07,07,07,07,07
Handler:
SELECT CASE ERR
CASE 76
MKDIR "gfx"
RESUME
END SELECT
Program 2:
DIM floor(50)
SCREEN 13
DEF SEG = VARSEG(floor(0))
CHDIR "C:\qbasic\GFXFiles\gfx"
BLOAD "floor.gfx", 0
DEF SEG
PUT (0, 0), floor, PSET
Please help -Mike