home *** CD-ROM | disk | FTP | other *** search
/ Chip 1998 July / Chip_1998-07_cd.bin / zkuste / mazda / Sedan311.dxr / Internal_14_Go to Frame.ls < prev    next >
Encoding:
Text File  |  1998-05-12  |  1.5 KB  |  41 lines

  1. property WhichFrame, whichevent, playMode
  2.  
  3. on initGotoFrame me
  4.   init(me)
  5. end
  6.  
  7. on mouseUp me
  8.   if whichevent = #mouseUp then
  9.     init(me)
  10.   end if
  11. end
  12.  
  13. on prepareFrame me
  14.   if whichevent = #prepareFrame then
  15.     init(me)
  16.   end if
  17. end
  18.  
  19. on exitFrame me
  20.   if whichevent = #exitFrame then
  21.     init(me)
  22.   end if
  23. end
  24.  
  25. on init me
  26.   if the playMode of me = "Play and Return" then
  27.     play frame the WhichFrame of me
  28.   else
  29.     go(the WhichFrame of me)
  30.   end if
  31. end
  32.  
  33. on getPropertyDescriptionList
  34.   set p_list to [#WhichFrame: [#comment: "Destination Frame:", #format: #integer, #default: 1], #whichevent: [#comment: "Initializing Event:", #format: #symbol, #range: [#mouseUp, #prepareFrame, #exitFrame, #initGotoFrame], #default: #mouseUp], #playMode: [#comment: "Play Mode:", #format: #symbol, #range: ["Go to", "Play and Return"], #default: "Go to"]]
  35.   return p_list
  36. end
  37.  
  38. on getBehaviorDescription
  39.   return "Moves the Playback Head to the designated frame when the specified event occurs.  Drag to a sprite or frame in the script channel." && RETURN & "PARAMETERS:" && RETURN & "ΓÇó Destination Frame - Enter the number of the desired frame." && RETURN & "ΓÇó Initializing Event - Choose the event that triggers the behavior." && RETURN & "ΓÇó Play Mode - Choose Play and Return to make the Playback Head return to the current location when the Play Done behavior is encountered. Choose Go To to make the Playback Head continue from the specified frame until explicitly sent to a new location."
  40. end
  41.