Publishers of technology books, eBooks, and videos for creative people

Home > Articles > Design > Adobe Creative Suite

  • Print
  • + Share This
Like this article? We recommend

Creating the Graphics

The first step in creating your scrolling-screen environment is to create the sprites and graphics for your game.

As we've mentioned, a sprite is a character, such as Mario in Mario Bros, that you can control in the game. The scrolling-screen game that you will create here has the foundation tools that you need to build a game similar to Mario Bros.

  1. Begin by creating a new movie in Flash MX. Size your new screen to 400 x 300 pixels. (See Figure 2).

    Figure 2Figure 2 The movie is set to 400 x 300 pixels.

  2. Create five layers in the Timeline panel. Name the layers as follows: scripts, logic, character, level data, and background (see Figure 3). Select all five layers and then press F6 to add a new keyframe. Your movie will be two frames long.

    Figure 3Figure 3 Five layers were used to create this movie.

  3. Select Frame 1 of the background layer. The background layer is the visual placeholder for the background of the game. As you move through the game, the background will move with you.

  4. Select the Rectangle tool and draw a rectangle the size of the screen. In Figure 4, have filled the screen with a radial gradient color that goes from orange to red. You can use any color combination you like.

  5. Select the new background rectangle and select Edit, Copy. Move to Frame 2 of the background layer and select Edit, Paste. You now have the background in both frames. This is important because Frame 1 is the frame where you will be adding your gameplay instructions, and Frame 2 is the frame in which you will be playing the game.

    Figure 4Figure 4 The opening sequence to the game.

  6. In Frame 1, you will need to add a button that will allow a user to move to the next screen. I Figure 5, I have used one of the buttons in Window, Common Libraries, Buttons. I have also added some instruction that explains how to play.

    Figure 5Figure 5 You can find the button used for the opening scene in the Common Libraries menu.


  7. Go to the Library panel and create a new instance. Name the instance bar and select the behavior type Graphic.

  8. Open the new bar graphic in Edit view. With the Rectangle tool, draw a rectangle 300 pixels wide by 15 pixels high.

  9. Create a new movie clip in the library and name it platforms. Open the background movie clip in Edit mode.

  10. From the Library panel, drag the bar graphic onto the background movie clip. This will be the space in which you will move. Drag on several of these clips to form an environment similar to the one in Figure 6.

    Figure 6Figure 6 The layout gives you a generic view of how a scene may appear.

  11. Move to the far right of the screen. Above the highest bar graphic, use the Rectangle tool to draw an exit screen. Select the drawing you just created and convert the drawing into a movie clip.

  12. Finally, draw a second small rectangle on the screen (see Figure 7). Convert the square into a movie clip named controller.

    Figure 7Figure 7 This is the controller movie clip; the controller manages much of the interaction between movie clips on the stage.

The next phase is to develop the game sprite—the main character—for the game. Later, you will add some ActionScript that will allow you to control the movement of the sprite.

Create a new movie and name it Sprite. The sprite looks very similar to a famous droid. The droid does not have many moving parts, which makes it easier to animate.

Now follow these steps:

  1. Every five frames, a keyframe needs to be added. Do this 13 times.

  2. Add a new layer across the top of the movie. Call this layer scripts. Add keyframes at Frames 5, 55, 60, and 65. At each of these keyframes, add a stop(); action. These four sections will be used as placeholders. The four different styles of animation needed to bring the droid to life are created between these keyframes.

  3. In Frame 1, the droid is standing still.

  4. The next nine keyframes change the position of the droid to show him leaning forward as if he is moving.

  5. Move the playback head to Frame 55.

  6. The droid needs to be able to jump and fall. For each, the same movement is used. Frame 65 should have the droid leaning back to make him look like he is jumping.

  7. Go to Frame 2 of the movie and select the character layer. Drag an instance of the droid onto the layer. Name this clip ball.

  8. Select Frame 2 of the level data layer. Drag the platform movie clip onto the stage. Name the clip ground.

  • + Share This
  • 🔖 Save To Your Account