In GLBasic you can use the SWAP command to swap values. You could then just use - SWAP drawlist[j],drawlist[j+1] and ignore the Val=bit completely.
You are also using "OR" 900 times every time you run this section of code - you'd be better separating them as the code reads "IF this OR that OR the other." It has to execute the whole line, whereas a standalone "IF" line terminates immediately if the IF is false. Or use CASE - pretty much of a muchness though.
I optimised this routine now, but i can test only on evening, but i will let you know the results. Many thanks.
Cloud on is now running on stable 60FPS!!
Quicksort was helping a bit, also the advices from "iprice".
But most time was wasted with very stupid fault of me (drawing sprites where not needed )
Here you will find a developement build for .
It's the first level now incl. BGM.
Push button "A" to make a drop.
With "SELECT" you can change between 3 types of button layouts:
feedback is welcome