harkonnen at March 8th, 2011 04:02 — #1
Do you know a very old game called Galaga ? It's a shoot'em'up in which enemy waves come from the top of the screen, and do a dance before reaching their final position.
I'm developing a clone of that game for Android, and I wonder if there's a tool or a method I could use to generate the coordinates used for the "dance" of my enemy sprites.
You can see this game here : http://jeu.info/galaga-flash.html
Thanks in advance
rouncer at March 8th, 2011 07:38 — #2
Well, that was actually a pretty classy arcade effect.
Its not easy to code... you could try a lot of different ways.
The way id do it is id start the aliens off in an entry state, where they fly into position and curve around a bit, then they go in formation state, then they would go from formation state back to exit state, which then goes to entry state then back to formation state again.
And just code it like I would a multiple state ai virtual machine.
Im sure even some movement programming / movement recording could be useful too, so you could go down that way maybe also.
thenut at March 8th, 2011 08:44 — #3
Ahh, the good old days. Fond memories.
The movement of the aliens when they are introduced is probably best done using Bezier paths. It will give you fine grained control versus trying to work with and manipulate spirals and circular curves, which I'm guessing is what the original author did.
When the aliens fly towards the ship, it looks like you could start it off with a random downward direction vector. Add a random probability the alien will swing around in a circle (using sin and cos) as it nears the ship's horizon before it disappears off the screen and returns to its normal position.
harkonnen at March 8th, 2011 10:57 — #4
Thank you for your answers, they are very interesting to read
My first idea was actually to use movement recording to generate some coordinates. But I have no idea about the tool to use for that purpose. Maybe you know such a tool I could use ?
But Bezier Curves is a good idea too, although I think that the author could have never use them in early 80's