Okay, I've been working on my optimizations for the 1945 demo project and I 've achieved a lot better performance on my 312 and 624Mhz Pocket PC's.
Originally I was only getting about 4-6 FPS on these devices but by using various omptimizing techniques, I'm now getting an average on my Axim X50v of over 16 FPS and on my HW6515 it can get up to 15 FPS with an average of about 12.
The game is much smoother on both devices which is great since it was unplayable on the HW6515 and barely playable on the X50v.
So, here's what I've done so far to make it faster:
- Removed all unnecessary actors from the game
- Removed all alpha images
- Set transparency off on all actors except where it was essential.
- Simplified the animations. Made them shorter, smaller and changed them so that they didn't use alpha transparency.
- Removed any unnecessary Draw Actor scripts
- Simplified the code and made use of If Else conditionals in order to speed up execution. Especially on Draw Actor events which improved it 50 percent.
- Actors are now dynamically generated so that don't exist in the game until needed
- All Actors are destroyed after they are no longer needed
- Timers are destroyed when no longer required
- Used many seperate Activation Regions
This last tip added 3 FPS to the game alone and made the FPS more consistent throughout the whole game.
Here's a screenshot to give you an idea of what I did.
http://240x240.com/Treo700/InGame.jpg
Activation regions seem to be very efficient at keeping actors in memory only when needed.
Makslane, it would be interesting to know how it accomplishes this exactly. Just for the sake of understanding. Is it using buffers or what?
Anyway, do these things if they apply to your game and it will work much faster.
--Steve