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
Show Time
Macromedia Licensing
XTRA dmmXSC - a client for XML Socket Server
Shockwave Safe Xtras
TetonPop Xtra
RGB Hex Module
Math
Director 8.5 Shockwave Studio: The Complete Reference
Moving MIAWs with lingo
Windows for Shockwave 4.5
 

 

 

Behavior moving buttons

Added on 4/27/2004

 

Compatibilities:
D8_5

This item has not yet been rated

Author: spiderman3388

shifts the sprite to some distance

property mydistance
property mysprite
property f
property tsteps
property icastnum
property myloch



on beginsprite me
  mysprite=sprite(me.spritenum)
  icastnum=the castnum of mysprite +1
  myloch=mysprite.loch
end beginsprite me



on mousewithin me
  put 1 into f
end


on mouseleave me
  put(0) into f

end


on exitframe me
  if f=1 then
    if the loch of mysprite      set the loch of mysprite to the loch of mysprite+5
      set the castnum of mysprite to icastnum
    end if
  end if
  
  if f=0 then
    if the loch of mysprite>myloch then
      set the loch of mysprite to the loch of mysprite-5
       set the castnum of mysprite to icastnum-1
    end if
  end if
end


on getPropertyDescriptionList
  description = [:]
  addProp description,#tstep, [#default:5, #format:#integer, #comment:"speed"]
  addProp description,#mydistace, [#default:60, #format:#integer, #comment:"distance coverred"]
  
  return description
end  

 


Contact

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

Send e-mail