Headache with LoadAnimImage

BlitzMax Forums/BlitzMax Beginners Area/Headache with LoadAnimImage

The forum is locked. These are the original blitzbasic.com forums, kept so they can still be read. No new topics, replies or edits can be made here. To join in, head over to the Blitz3D+ forums.

Have you checked the contents of the array? Do you still have 52s in there?

Every value in the array should be between 0 and 51, otherwise (in the event of a 52) you're trying to draw an image frame that simply isn't there.

Try changing it to this:
Local r:int
DebugStop
For e=1 To 13
  For f=1 To 8
    r = board[e,f]
    DrawImage cards,e*52,f*70,r
  Next
Next
Step through the loop, checking the value of 'r' each time. You'll probably find that it works right up to the point where it comes across a 52, when it will throw an error.