Search content:

 

Personal Menu
Username:
Password:
Save password

Become a member

Forgot Password?

 

Don't miss these
Sprite Drag - Confine to stage
Royalty free Music and Loops
Title Bar Color Gradient Effect Behavior
ResourceXObject
Slider behaviour v2.2
macromedia.director.lingo
Open File WIth Associated Application
Flash Member Controls
Slider puzzle (imaging lingo)
AutoCropper v1.2
MediaMacros Xtras Mall
 

 

 

Behavior Wait for Mouseclick

Added on 7/6/2000

 

Compatibilities:
behavior D7 D8 Mac PC Shockwave

This item has not yet been rated

Author: KumarK

Wait for Mouseclick

---- written for Director 8 ---
---- Kumar.K ----
---- kumark@icode.com ----

------ Custom Properties ------

property  WhereTo,whichmouseclick

------ Get Behavior Description List ------
on getPropertyDescriptionList me
  set description = [:]
  if the currentspritenum <> 0 then exit
  actionlist=["Go Next Frame","Go Next Marker","Go Previous Marker","Go Loop","Exit"]
  Mouseclicklist=["Left Mouse Up","Left Mouse Down","Right Mouse Up","Right Mouse Down"]
  addProp description, #whichmouseclick, [#comment: "wait for Which MouseClick ?",#format:#String,#range:Mouseclicklist,#default:Mouseclicklist[1]]  
  addProp description, #WhereTo, [#comment: "What Next(after a Key press or Mouse Click) ?",#format:#String,#range:actionlist,#default:actionlist[1]]
  return description
end getPropertyDescriptionList
------ Get Behavior Description List ------

-- Get Behavior description --
on getBehaviorDescription me
  return
    "Wait for a MouseClick" & RETURN & RETURN &
    "This Behavior make the playback head hold on a frame untill a MouseClick . " &
    "PARAMETERS:" & RETURN &
    "* Which MouseClick :" & RETURN &
    "* What to Do after MouseClick."
end getBehaviorDescription
-- Get Behavior description --

------ Availbale for only Frame Script ------
on isOKToAttach (me, aSpriteType, aSpriteNum)
  case aSpriteType of
    #graphic:
      return false
    #script:
      return true
  end case
end isOKToAttach
------ Availbale for only Frame Script ------

-- Events --
on ExitFrame me
  go the frame
end ExitFrame

on mouseup
  if whichmouseclick = "Left Mouse Up" then
    whatnext
  end if
end

on mousedown
  if whichmouseclick = "Left Mouse Down" then
    whatnext
  end if
end

on rightMouseUp
  if whichmouseclick = "Right Mouse Up" then
    whatnext
  end if
end

on rightMouseDown
  if whichmouseclick = "Right Mouse Down" then
    whatnext
  end if
end
------ Events ------

----custom handlers----
on whatnext
  case WhereTo of
    "Go Next Frame":Go the frame + 1
    "Go Next Marker": Go Next
    "Go Previous Marker": Go previous
    "Go Loop": Go Loop
    "Exit":quit
  end case
end

 


Upload Provided by ABCUpload ASP

Contact

MMI
22 West Court Sq
Suite 2C
Newnan, GA 30263
USA

Fax - (206) 339-5833

Send e-mail