So you want to make a game in Flash that is like the classic arcade game Asteroids? One of the easiest ways to start out to do that is to use the Pulado Flash Game Engine. Pulado takes care of all of the coding for you and leaves you to create the assets in Flash (and then assign them to the game sections). Consider this the first step to creating a game in Flash. After you build a few games with Pulado then you can move on if you like and start coding your own Flash games from scratch (or using the artwork you created for use in Pulado).

First create an account on Pulado and then once you are in the members area click New Game to create a new game. There are different game type templates on the left and you want to select the Rock Blaster template. You will want to create a name for your game, enter a description, and enter some tags that describe your game. The game we created is called Uberroids 9000 and gave it a description of “Shoot rocks for the win!”, and these tags “rocks,asteroids,space”. You will want to name your game something other than Asteroids because that name is trademarked by Atari and you want to be original. Click save and this will create a fully formed game similar to Asteroids. However, we are going to dive in and take a look at the settings that make the gameplay similar to Asteroids.

In a game like Asteroids you have the player as a space ship and the opponents are different shaped asteroids. The player also has a weapon that he or she can shoot at the asteroids to blast them apart. So lets talk about how you change those settings. You can click on the Player tab in the game editor and that will allow you to customize your player. The first option you will see is the Avatar option which will let you change the look of your space ship if you want to. You can also customize the style of movement for the space ship, how fast you want the space ship to move, and how many lives you want it to have.

For a game like Asteroids we are going to use the movement style of “Fire 360 Degrees”. This will allow you to use the left right arrow keys to rotate your ship and the forward button to move forward. If you want change the look of your space ship use the “select avatar” link. Below this section as an Advanced option section where you can change things like the scale of your ship, the spawn location, and other things which we won’t really need to change for a game similar to Asteroids.

If you continue scrolling down you will come to the Weapon #1 section. This is where you can customize the look for the bullets that will fire when you press CTRL or Z in your game. You can also change the type of the bullet, the velocity (speed) of each bullet, and how fast the player can fire each bullet. For this game we want the type to be set to “Bullet”. Use the “select graphic” link to customize the bullet graphic. You can customize the sound of the bullet when it fires from here as well. If you like go ahead and tweak the rate of fire and projectile velocity (lower is faster).

Once you have made the changes you want to make you can continue scrolling down where you will encounter the Weapon #2 section. Weapon #2 is controlled by the X button in your game and it is usually setup to be a screen clearing “kill everything” style weapon. You may not need this weapon in your game but it is currently setup to be an expanding bomb. Skip this section for now and scroll down. There is a Save button at the bottom and if you made any changes on this page you should click the Save button to save your changes at this point. When you Save you will be taken back to the Preview tab where you can then test the changes you just made to your game.

The next section we are going to edit is the Opponent tab where you can setup the asteroids. On the Opponents tab the first thing is the Level Difficulty slider. Lower is easier but if you want your game to be harder you can increase the slider. Next we have the Avatar section where you can customize the asteroid graphic (just like you did the player graphic). You can also select the Movement style at this point. For a game like Asteroids we want the “Random Movement / Face Forward” option. This option will make the asteroids spawn in at the edges of the screen and move directly in a random direction (usually at an angle). If they were a space ship graphic they would be pointing forwards. Customize the movement speed of the asteroids, how many asteroids you want to start the game with, and the maximum number of asteroids you want on the screen at the same time. Lastly you can choose to have the asteroids fire projectiles at your or not and in a game like Asteroids the opponents don’t fire weapons so leave that unchecked. There is also an Advanced section here where you can customize scale etc.

You can script the next two sections which are Weapon #1 and Weapon #2 for the opponent as weapons are disabled. Scroll down to the buttom and click Save if you made any changes on this page. Again you can preview your changes now. The next section which we will quickly cover is the Background tab. From here you can select what you want your background for the game to look like. There are multiple background layers but for this game you want only the very bottom one so scroll to the bottom. If you want to change the graphic for the background do so now and then click Save.

The next section we will be editing to create a game like Asteroids is the Gameplay tab. The first part of the Gameplay tab is the Gameplay section and on this section the two options that concern us for this game are the Projectiles Wrap option and the Shatter option. Projectiles Wrap will make it so that when a bullet reaches the edge of the screen it will teleport to the opposite side of the screen. The Shatter option will make it so that when you shoot one of the rocks it will split around into three smaller rocks.

The next two sections on the Gameplay tab are Player Modifiers and Opponent Modifiers. In these sections the Player Wrap option is selected so that when the player reaches the edge of the screen they teleport to the otherside (like the projectiles). You can also customize how many hits the player can take before losing a life here. Farther down in the Opponent Modifiers section the Opponent Wrap is set so that asteroids teleport around at the edges of the screen as well and then Random Opponent is also set which causes an asteroid to randomly wander the screen (separately from the movement type selected on the Opponent tab).

Farther down in the Opponent Modifiers section you can also customize how many asteroids have to be destroyed before you move on to the next level and how many hit points they have. There are all kinds of other options here but they will be left for a different tutorial. If you have made any changes on this tab scroll down and hit the Save button and then preview your changes.

Good job! This tutorial is now complete and I hope you learned how to make a game in Flash similar to Asteroids using Pulado. Now get there and start tweaking out the other settings as we can’t wait to see your take on an arcade classic.

If you haven’t done so yet visit Pulado now and start to make your own games!

Advertisements