Drag and Drop - Information

 
Index > Teachers Animation Toolkit > Drag and Drop > Information > Adapting the template for other activities

The objective here is to show some ways to take the drag and drop template and adapt it for different purposes. I have not produced completed activities, just enough to show you how you might produce your own ideas.

 

The information below explains how the movies work and how they were created without having detailed instructions on how to produce them from the template. You can use these files as more specialised templates or have a go at reading the code to find out how they work. The key thing to remember is that no code was altered from the starting template.

 

The pdf version of these pages can be downloaded here.

 

Here are the sections on this page so that you can jump to them individually:

 

True / false for interactive whiteboard

Matching pairs (text and images)

Cloze activity

Sorting things into order
Allowing different targets

 

 

True false for interactive whiteboard

 
   

The activity is based on text labels (they could also be images) that drag on to two target boxes (true and false). Since the activity is designed for the whiteboard, the scoring system has been removed (although not the code) and replaced with a tick or cross message.

 

This template can be adapted for any sorting / categorising activity - you can have any number of target boxes, the key thing is that more than one object can be dragged into each one.

   
  1. The look of the movie can be adapted in the same way as has been described earlier. Create target boxes for each category of answer and then as many text labels to drop on them as you need.

  2. You might want to have a look at the movie clip symbol called message in the library.

    The message movie clip has three states (off, correct, and wrong). The off state shows nothing on the screen. When the movie clip is told to go to correct, a simple animation called a motion tween plays producing a tick. The clip then returns to off so that it is hidden. When the clip is told to go to wrong, a cross appears for a few seconds before disappearing as the clip goes back to off.

    Each message is played with the following code:

    _root.message.gotoAndPlay("correct");

    or

    _root.message.gotoAndPlay("wrong");

  3. The key change to the code was to set the value of duplicateDrop so that the movie allows you to set more than one draggable item to each target and so that the items disappear once they are dropped.

    // this variable sets if more than one text label can be placed on the target boxes
    // 1 = no, 2 = yes
    var duplicateDrop = 2;

    and...

    answer[1] = 1;
    answer[2] = 1;
    answer[3] = 2;

 

Download fla

 
Top

Matching pairs

   

This variation shows that the draggable "labels" can be images as well as text.

 

The point to remember is that the instances of the symbols are still called word1 etc. so that the code works!

 

The basic steps to altering the word movie clips are:

  1. Delete the text box from the text layer.

  2. Import an image into the text layer and resize it if necessary.

  3. Lock the text layer and then select the background layer. resize the background shape so that it is the same as the image. It will be hidden anyway but remember that the background movie clip instance has some important code on it so you must not delete it.

  4. The options variables are set so that the movie works as you would like it.

 

Download fla

 
Top

Cloze activities

 

Half way through producing this one I decided that it is one of the slowest activities to produce using the template. You might want to look at clozemaker as an alternative.

 

Here are the steps to produce a cloze activity:

  1. Place a large static text box on the decoration layer and type in the cloze passage. Adjust the text to a suitable size and remember the font and size for later.

  2. Lock the decoration layer and then place target boxes over the words that you want hidden. Size the target boxes so that they cover the words and will be large enough to drop word labels into.

  3. Edit the text label movie clips so that they display the missing words and are the same size as the text.

  4. Edit the options code so that it behaves as you want.

  5. You can have extra "distractor" words. Make the answer for these 0 (zero) in the code so that they are always treated as wrong since there is no box0.

 

Download fla

 

Top

Sorting things into order

 

The idea of this one is that the user drags words or phrases across so that they end up in a logical order. The sequence will then for example, describe a process.

  1. The words or phrases are just text label movie clips (word1 etc.). Create them in the correct order so that word1 should end up in box1 but then mix them up when you place them on the stage. The template also includes a shuffle routine to make sure that they come up in a different order if the user tries it again.

  2. Create and place the target boxes.

  3. Add prompts to the decoration layer e.g. numbers beside or behind them. The example has numbers behind the boxes. The box movie clip was edited in the library, removing the background so the text shows through. Alternatively, if you want them to have a background, drag the decoration layer above the boxes layer but below the words layer.

  4. Edit the options code.

 

Download fla

   

Allowing different targets

 

If you want to create a grouping activity, where a number of objects can be placed in any one of a number of target boxes, you have to dispense with the show option (by deleting the button), at least in this version of the drag and drop template.

 

Edit the answer array so that each draggable object shares the same number of target but leave duplicateDrop = 1.

 

You can then use tick = 1 to confirm to the student that they have dropped correctly.

 
download
   
 
Top
Back to the menu page