My game runs fine at 60 fps on ipad 2 and likely 4th gen devices, but is unlikely to be a stable 60 fps on 34d gens, or worse, android devices 
What I’d like is the ability to have it run at a fixed 30 fps on some devices and 60 fps on others (the game would ‘feel’ the same as I’d simply update the game engine twice per frame on the 30 fps setups, but with only 1 cycle of the costly graphical updates and associated code per enterFrame callback).
Problem is - how?
config.lua allows for just a single value, so that is apparently not possible.
For now the only thing I can think of is I set the config to 60 fps, then for 30 fps systems I just skip the redrawing code every other enterframe, but this is not perfect because:
- certain things in the game engine ARE graphically updated every time (IE 60 fps). I could code around this however
- rather than have the entire 30th of a second to call the game engine twice and draw it once, it will be split into 2 lots of 60ths of a second. While it may be possible to balance this somewhat (eg the 2 game engine updates in one, then the visual update in the second), it will undoubtedly be less efficient, and will almost certainly result in inbalanced frame durations, or wasted processor powers (as you’d be unable to balance the load exactly 50/50 between the two frames).
- there may well be some overheads in the enterFrame regardless of whether I change things onscreen or not (any help here if this is true or not?)
So umm… suggestions?
I have options that disable various graphical features like layers of parallax on the slower devices to help up framerates, but even then, a solid 60 fps is basically going to be impossible to achieve, and I’d much rather have a stable 30 fps game than one that varies unexpectedly between (say) 40 and 60 fps.
Barry [import]uid: 46639 topic_id: 23393 reply_id: 323393[/import]