
-----------------------------------
Vertico
Thu Apr 28, 2005 6:06 pm

Illegal picture ID Problem
-----------------------------------
Not completly sure why this is happening. It will run right for a bit then it will crash with this error


Illegal picture ID number '0'. (Probable cause: picture was not successfully created).


Someone figure this out for me plz.

-----------------------------------
Token
Thu Apr 28, 2005 6:25 pm


-----------------------------------
here, give this a go. what you had to do is free the picID before you re-assigned it or else it would build up on that one variable. so just put 

            Pic.Free (picID)

before

            picID := Pic.FileNew ("verticomanStand.bmp")



but this dosent make sence for the error you were getting, make sure all the files are in the same folder. so try that and double check the location of ur files

-----------------------------------
c0bra54
Thu Apr 28, 2005 6:52 pm


-----------------------------------
no it does make sense.. what ends up happening is when you go 
Pic.FileNew ("")

and open a different pocture in  variable more then 1000 times it crashes, probly something to do with tuirng's memory componenets.. the easiest way to fix this if you are making a game or somethin, is to have a Pic.Free pocedure, that will free all the pictures in your game, and run it everytime your main loop executes.. i first ran into this problem with animation..

yeh, thats all :P

-----------------------------------
Token
Thu Apr 28, 2005 8:32 pm


-----------------------------------
yah, the code i posted fixes that problem, i never ran into the 


Illegal picture ID number '0'. (Probable cause: picture was not successfully created). 


problem of which he speaks 