Conquer the Universe With ActionScript 3.0 and the Flixel Game Engine: Part 1
The Flixel game engine is an opensource ActionScript 3.0 framework written by Adam Atomic. Its aim is to take the donkey work out of building AS3 games, leaving you with all the fun stuff and saving heaps of time!
In this, the first in a series of two screencasts, Shane Johnson takes you through the basics of Flixel, explaining how to build an awesome shoot ‘em up game from scratch.
View Screencast: Section One
Introduction
Get the Flash Player to see this player.
View Screencast: Section Two
Begin Coding
Get the Flash Player to see this player.
View Screencast: Section Three
Moving on; Sprites and Sounds
Get the Flash Player to see this player.
View Screencast: Section Four
Shooting, Killing and Compiling
Get the Flash Player to see this player.










Year, super old school galaga-stuff!
I like this retro arcade-shooters.
COOL!
Holy actionscript, batman.
Good stuff, complicated looking.
The final result of your tutorial is EXCELLENT! Let me try to do it! Congratulations.
Great Tutorial.
Well explained.. i’m waiting for part II
thanks
Great tut and even better that its a video. So much easier to follow than the written ones.
Just great. This is genius old school.
Keep going just like this.
Regards.
Hmm..without watching the screencasts (i don’t like screencasts much…you can’t skip “to the content”
) just by “trying” the demo i’ve noticed a problem with the movement. You can go to only one direction at a time which makes it quite harder to evade the other spaceships. If it is not intentional is it “engine” problem or else ?
Hey we wouldn’t want to make the game too easy…….
The movement of the player is controlled by an ‘else if’ statement meaning only one key can be pressed at a time but this can easily be changed to a simple group of ‘if’ statements like so:
if(FlxG.kLeft)
{
acceleration.x -= drag.x;
}
if(FlxG.kRight)
{
acceleration.x += drag.x;
}
if(FlxG.kUp)
{
acceleration.y -= drag.y;
}
if(FlxG.kDown)
{
acceleration.y += drag.y;
}
This code looks awesome as i would rather have diagonal movement….
Thanks Shane!
Wouldn’t you rather avoid glitches? if you push up & down at once, it will probably result in a waste of processor arithmetic power! =D
if(FlxG.kLeft)
{
acceleration.x -= drag.x;
}
else if(FlxG.kRight)
{
acceleration.x += drag.x;
}
if (FlxG.kUp)
{
acceleration.y -= drag.y;
}
else if(FlxG.kDown)
{
acceleration.y += drag.y;
}
^ This is prolly really incorrect formatting, but hey, you get the point…
I like
Maybe next time a game about gravity? Like a sort of flying game were you have to make sure that the object stays as long as possible in the air?
Nice job, I was looking at the PushButton Engine but this is much more fun. The only thing i found is FTD gives me trouble with mimeTypes of the assets.
yeh!!!!
)))
amazing tut
thanksss
WOW! This game is awesome……
I am making a game out of this……
will post it here once it is finished so everyone can play
its aweeesooooome!
Hi would you be able to link the source code for Flixel at the time you created the tutorial because it does not work with the latest build.
Thanks
Hi Yes this was done with flixel 1.25
you can download it from my server here: httP://ultravisual.co.uk/blog/sourceFiles/flixel_v_1_25.zip
When I have a chance I’ll up date the source files for this tute to work with the new version on github
Shane
Thank you very much
it’s not working! When i open the demo page shows only white flash box!
Great tutorial thank you !
I’m trying to find the software “sfx” you are talking about but there are so many softwares called like this and I never find the good one… Could you give me (us) the link?
sfxr?
Original version here.
Flash/AS3 port here.
“Sfxr” right, thanks a lot Micheal!
You say in your tutorial that you are creating a game “from scratch” but you’re using flixel… ?
where the FLA file in source download??
only action script what about animation and charecters?
I’ll definitely try. Thank you very much for the tutorial.