Contents
Articles
Behaviors
Books
Director News
Director Web Sites
FAQ
Games
Mailing Lists
News Groups
Project Examples
Reviews
Software
Tools
Useful Web Sites
Utilities
Xtras

Don't miss these
Set Linked Property of a Animated Gif Cast member
Generic behavior to get Key State.
Risk
Volume Control-Slider
Sound shifting
cXtraStringGrid
Golden Gate
cXtraRTF
W3D Texture Extractor
ProMix
 

 

 

Behavior Send to Top

Added on 6/10/1999

 

Compatibilities:
behavior D6_5 Mac PC

This item has not yet been rated

Author: JohnDowdell

Simple example which will bring any clicked sprite to the top. Useful if you have a bunch of overlaid photographs, etc. Will also put the clicked sprite with this behavior atop other sprites which don"t have this behavior. Image will go back to original layer when another sprite with this behavior is clicked, or if you wipe another sprite above it, or do a full-screen transiton (these erase trails).

property spriteNum

on mouseUp me
  sendAllSprites(#SendToTop_ToggleTrails, #off)
  SendToTop_ToggleTrails me, #on
end

on SendToTop_ToggleTrails me, onOrOff
  case (onOrOff) of
    #on: set the trails of sprite spriteNum to TRUE
    #off: set the trails of sprite spriteNum to FALSE
    otherwise: put "Wadda you, a wise guy or sumpin"?"
  end case
end

 


Contact

MMI
36 South Court Sq
Suite 300
Newnan, GA 30263
USA

Send e-mail