How to Make Drag & Drop Flash Games

Written by willa dunn
  • Share
  • Tweet
  • Share
  • Pin
  • Email
How to Make Drag & Drop Flash Games
Create an interactive game using Flash drag and drop. (3d tic tac toe game board image by Brent Walker from

Adobe Flash makes it possible for you to produce multimedia projects including animation and games. Flash's drag and drop methods provide you with the basis for creating an interactive game in which your users can move objects around. Use the following example to understand these methods, and as a foundation which you can build upon to make your own drag and drop games.

Skill level:

Other People Are Reading


  1. 1

    Open Adobe Flash and create a new file. Select "File" and then "New" from the menu at the top. In the resulting window, choose "Flash File (Actionscript 2.0)." Click "OK." The following example will output "CORRECT!" when the user places the ball within the box.

  2. 2

    Create a movie clip of a blue box. Change the "Fill" colour to blue, using the "Tools" panel. Draw a box using the "Rectangle" tool. Use the "Selection" tool (arrow) and double-click the box to select it. Press "F8" and then "OK." Set the "<Instance Name>" field of the "Properties" panel to "blueBox."

  3. 3

    Create a movie clip of a red ball. Change the "Fill" colour to red. Draw a ball using the "Oval" tool. Double-click the ball to select it. Press "F8" and then "OK." Set the "<Instance Name>" to "redBall."

  4. 4

    Press "F9" to open the "Actions" window and type the following data:

    redBall.onPress = function() {



    redBall.onReleaseOutside = redBall.onRelease = function() {


    // if red Ball is dragged onto blueBox

    if(this._droptarget == "/blueBox") {




  5. 5

    Test the animation by pressing "Ctrl" and "Enter" simultaneously.

Don't Miss

  • All types
  • Articles
  • Slideshows
  • Videos
  • Most relevant
  • Most popular
  • Most recent

No articles available

No slideshows available

No videos available

By using the site, you consent to the use of cookies. For more information, please see our Cookie policy.