Ahh there’s my problem… i tried BufferStrategy, but got some error… something about the window “Must have a valid peer”
i put it onto a fullscreen window, worked good, but then if i move it so that Explorer is exposed it crashes.
i have just got a demo from someone which uses BufferStrategy in a window, i just have to sit and read it and try to work it out.
If i can get the swing objects to paint themselves to the buffer in the same way they usually paint themselves to the screen (which is not using Repaint or update) it’d be a very smooth game. at the moment it runs at a max of about 80 fps but it’s capped at 50, and on a p II 450 mhz system it runs about 30-45 fps depending on the window size.
It’s frame based logic but can catch up if it drops behind
The window size is default to 500x500 (approximately) and the tile map is 14 tiles high, using 32x32 tiles, and can be up to 1000 tiles long. I’ve looked at levels with diferent lengths, gone right up to the max length and it still runs good, just flickery…
This’ll be an even bigger problem when i start introducing enemy sprites, coin sprites, block smash sprites etc…