04-02-2005, 01:36 PM
i'm opening a file for binary, and i've been having troubles for a few days. I think i'm a step closer, and i'm wondering if this is maybe a compiler bug instead of a problem with my own code.
Basically, my code works fine up to here:
til is supposed to return the tileset label, templength the length of the name of the tileset. However, it seems that templength doesn't seem to return the right number... instead of 7, it returns 1, or 0 probably, since it won't be printed. I thought it might be a faulty map, but after i replaced it with a new one, it still had troubles. I thoroughly tested it on qb, and it works perfectly, and so it should work thereotically with fb as well, after i change all the variables to short. thereotically. I and several other people looked at the code, and we all agree that there's nothing wrong with it.
To see what kind of problem is being produced in the first place, please go to my map loader problems thread a few stories down. here's a link...
http://forum.qbasicnews.com/viewtopic.php?t=9021
plus here is alot more information on the problem, including several more things i found but i'm too tired to type up... it's 2:30 here...
thanks in advance.
Basically, my code works fine up to here:
Code:
FOR y = 1 TO activetilesets
GET #filenum,, til
GET #filenum,, templength
tileset(til) = SPACE$(templength)
GET #filenum,, tileset(til)
numsets(til) = 1
NEXT
til is supposed to return the tileset label, templength the length of the name of the tileset. However, it seems that templength doesn't seem to return the right number... instead of 7, it returns 1, or 0 probably, since it won't be printed. I thought it might be a faulty map, but after i replaced it with a new one, it still had troubles. I thoroughly tested it on qb, and it works perfectly, and so it should work thereotically with fb as well, after i change all the variables to short. thereotically. I and several other people looked at the code, and we all agree that there's nothing wrong with it.
To see what kind of problem is being produced in the first place, please go to my map loader problems thread a few stories down. here's a link...
http://forum.qbasicnews.com/viewtopic.php?t=9021
plus here is alot more information on the problem, including several more things i found but i'm too tired to type up... it's 2:30 here...
thanks in advance.