Coding a Game

Balloons

Now there's not much left to do on our simple game. Otto will get a bit bored bouncing about with no purpose in life. If you were a yellow ball-like object, what better thing to do than burst some colourful balloons. Okay, maybe a better thing would be hanging around Wimbledon in June and hope you end up in Anna Kournikova's pocket. Sorry Otto, it's balloons for you.

Here's the code to put some balloons up on the Stage, this is in our init frame (frame 5):

( categories: )

Otto Lives!

We need to modify the frame we named as init to load our Otto movieclip and place him somewhere on the screen:

( categories: )

Get Things Moving

Now we need to code our init frame, this will be where we initialise all our variables, and place the movieclips on the screen. In the timeline, right-click on frame 5 and select Add Blank Keyframe. Do this on both the Action layer and the Screen layer. Change the name in the frame label to init. Any time you need to add some new ActionScript code to a frame, you have to create a keyframe. If you simply add a frame (ie. NOT a keyframe) then the ActionScript code from the previous keyframe will be run when the playhead reaches that frame.

( categories: )

Graphics and Start Screen

AssetsStart Flash, and create a new Flash document from the File menu. Keep the stage settings to their default settings of 550x400px, increase the frame rate to 30fps, background white.

( categories: )

Game Design and Gameplay

One thing is for sure, you'll be spending a big chunk of your valuable time with your next game project. So with that in mind, better make sure this is a game you will like playing yourself. Hopefully, you'll start enjoying it right away...that way you'll have an incentive to continue until the end. They say the last 20% of a coding project takes 80% of the time. I would correct this for games programming, and say the last 10% takes 90% of the time!

( categories: )

Creating a Simple Flash Game

So you want to impress your friends and get all the girls by creating your own game, do you? Well, read on, because I am going to show you how. This article assumes a few things, so let's get these out of the way right away.

( categories: )