CBT Cafe Logo  

CBT Cafe > Flash > ActionScript

Flash: Mouse.Hide meets With

Source Files: Download
Level: Medium
Version:
5
This Flash tutorial will show you how to use the mouse.hide action to create a custom mouse cursor. While I feel this often confuses the viewer more than enhances the experience, there are times when it might really be a good effect. In any event, this is a good lesson to go through if for no other reason than you get another look at using ActionScript.

Step 1: Creating the New Cursor

  1. Create a new Movie Clip
  2. Name it newCursor
  3. Edit the newCursor MC by double clicking it
  4. Create 3 Layers and name them: Actions, Labels, Cursor
  5. On the Actions Layer, create a Stop Action at both frames 1 and 10
  6. On the Labels Layer, create a Frame Label named normal at Frame 1 and a Frame Label named over at Frame 10
  7. On the Cursor Layer, create Blank Keyframes (F7) at both Frames 1 and 10
  8. Place a graphic or movie clip on the Cursor Layer at Frame 1. This will be the Up State or normal state of the cursor
  9. Place another graphic or movie clip on Frame 10. This will be the Mouse Over state for the cursor when someone mouses over a button

Step 2: Set up your stage elements

  1. Create 3 layers: Actions, Buttons, Cursor MC.
  2. On the Button Layer, create a new button
  3. Make sure the Cursor MC you created earlier is placed on the Cursor MC Layer. Give the MC an Instance name of newCursor by going to the Instance Panel and typing in newCursor in the Name field.

 

Step 3: Add the Mouse.Hide action for Frame 1 on the Actions Layer

  1. In the Actions Panel, select Objects>Mouse>Hide
  2. Actions>Start Drag
  3. For Target, specify the Instance name you gave the Cursor MC in the previous step: newCursor
  4. Check Lock mouse to center

Step 4: Add the following button actions

Test your movie by pressing Command-Return/Control-Enter

 

transSpacer

We've added 4 New Movies to our Flash 5 source files cd! These include detailed videos on:

1. Tell Target/With
2. Dynamic Text 1
3. Dynamic Text 2
4. Animated Fly Out menu Part 2

-------
About the CDROM:
These movies are the SAME content found in our Flash 5 tutorials, but the quality is clearly better than the streaming, web-compressed format we have online with Frame Rates up to 20 TIMES FASTER and CD-ROM quality AUDIO!


More Info...

 

 

Home | Dreamweaver | Fireworks | Flash | Photoshop | Elements | PowerPoint| Ebay | QuickTime Pro | Flash 5 CD | Fireworks MX CD | QuickTime Support | Contact

Copyright © 1999-2011 CBT Cafe, All rights reserved

Flash®, Fireworks™, and Dreamweaver® are registered trademarks of Macromedia, Inc. in the United States and/or other countries
Photoshop®, Photoshop Elements® and Illustrator® are registered trademarks of Adobe Systems, Inc.
QuickTime® is a registered trademark of Apple Computer, Inc.
Ebay® is a registered trademark

CBT Cafe | Multimedia Learning | Interactive Graphics