Select Case...?

BlitzMax Forums/BlitzMax Beginners Area/Select Case...?

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.

You can separate cases with commas if you prefer

Select MapArray[x,y].frame
   Case 1,2,3,4,5,6,7,8,9,10
   Case 11,12,13,14,15,16,17,18,19,20
   ' ETC..
End Select


It's not as readable, IMO, but I think it works.

I think this would also work?

Select True
   Case MapArray[X,Y].Frame>=1 And MapArray[X,Y].Frame<=10
   Case MapArray[X,Y].Frame>=11 And MapArray[X,Y].Frame<=20
   ' ETC..
End Select