Things I learned about making Flash Games in MMF
So, I just completed my first Flash game, and got it up on Mochi: Santa's Magic Sack
The first thing I learned about Flash is that you can go from having a fully functioning 50FPS game to having something that drops to a snails pace really easy.
The best solution I've found so far is to create your game to run at 30FPS. (30 fps looks just fine as long as you adjust the speed your objects move)
Also, my game used "paste object to background" frequently. While this worked great for a while, after a few minutes everything slowed down.
Solution: create active objects instead of paste to background. (this may or may not work as well for your game)
Why this worked for me: My game scrolls in only one direction, and I can then destroy the active objects when they get out of frame. It seems that pasting objects just kept adding to the memory usage, with no way to clear the objects from memory, and eventually affected performance.
I've also noticed that music sounds fairly good at the lowest bitrate and frequency, but sound effects will have a short delay when you play them. Is there a solution for this?
Feel free to add your own flash tips.
Re: Things I learned about making Flash Games in MMF
Pinapple. Were you destroying the actives once you pasted them?
Marv
Re: Things I learned about making Flash Games in MMF
It was just one active object that constantly pasted itself into the background.
After about 2 minutes (3500-4000 times being pasted into the BG), it would slow down
Re: Things I learned about making Flash Games in MMF
I don't think settling for 30fps is quite necessary, I've finished some reasonably complex games and while, yes, I have had to battle to keep a high framerate, my projects all run at 50fps for the most part. You have to be quite conservative with loops and employ the occasional ForEach loop (which is dangerous, the ForEach object still has many problems in Flash) but it can be done.
Re: Things I learned about making Flash Games in MMF
ForEach did not work for me in Flash, unfortunately. This extension definitely needs some fixes.
Re: Things I learned about making Flash Games in MMF
Yeah, implementing no fast loops of any description seems to speed things up an awful lot, it's just incredibly inconvinient :P
Re: Things I learned about making Flash Games in MMF
Is all the music in the game out of copyright? The opening song sounds like "Santa Clause is Coming to Town" which I think is still in copyright.
Re: Things I learned about making Flash Games in MMF
All the music is "creative commons"
Re: Things I learned about making Flash Games in MMF
Quote:
Originally Posted by Pineapple
All the music is "creative commons"
Which Creative Commons license? Some you can use, some you can't use for commercial purposes, some you can't use at all.
Re: Things I learned about making Flash Games in MMF
Going to have to agree about ForEach. I've had an awful experience with it. It just completely ruined my game in flash, and the one time it didn't, it ended up being slower than fast loops. This extension definitely needs a lot more work.