Hi Guys,

I was looking on the forum today to try and work through some lagging issues I have with my game.

I previously had trouble with too many fastloops (so I employed the ForEach extension for some parts) and got my FPS up to 50 on my PC, but when building it to my iOS device it will not move off of 17 FPS when playing on my iPhone 5... And in fact some enemies are refusing to move?! (they do move slowly on the simulator, with the lag). The CPU useage and memory useage (60mb) are all with entirely normal parameters...

Unfortunately it could be that there may be too many problems with this project - I fear I am going to have to scrap it.The thing is I drew most of the graphics a long time ago when image optimization wasn't really an issue (not when just for PC) and now all of the animations are taking up more memory than needed. They are all sizes which end up taking 4 times the space in some cases.

I did try to resize everything to half and scale up in runtime but because many of the image dimensions are of an unequal length they resize awkwardly and to be honest the quality is poor so I don't feel that is an option. And that didn't make any impact anyway on speed anyway! Still those 17 FPS!

I do have alot of loops running and quite a few items on always events... I have a suspicion that is the issue as I have done most other optimizing I can find on the sticky threads.

Would anyone be prepared to take a look and see what they think? Be warned I have grouped events but not commented (another failing of this project )

http://www.charlie.hypermart.net/mmf...emorydrain.zip

I posted in here as I'm sure what I've done wrong here is in MMF2, not Xcode, but any ideas are appreciated.

This is highly embarrassing but I've spent over a year on this and now I feel like if I'm doomed to 17 FPS I just want to start a new game where every single blooming image and piece of programming has ultimate optimization in mind all day and all night!

SimonPieman

Game controls
(multitouch controls disabled on file)

arrows = move, shift = jump, z = attack, w = toggle weapons, r = reload shotgun