home *** CD-ROM | disk | FTP | other *** search
/ What PC? 1996 August / WPCAUG96.ISO / makers / body / bodymain.dir / 00358.ls < prev    next >
Encoding:
Text File  |  1996-06-12  |  2.7 KB  |  113 lines

  1. on SetQT
  2.   global endSection, NextFrame, CurFrame, lastFrame
  3.   set CurFrame to NextFrame
  4.   set the movieTime of sprite 15 to (marker(NextFrame) - 10) * 4
  5.   set the movieRate of sprite 15 to 1
  6.   go(NextFrame)
  7.   MyPlaySound(NextFrame)
  8.   updateStage()
  9.   set lastFrame to NextFrame
  10.   set NextFrame to EMPTY
  11.   set endSection to marker(1) - 1
  12. end
  13.  
  14. on EndDance
  15.   global NextFrame, endSection, lastFrame
  16.   if NextFrame = EMPTY then
  17.     if char 1 to 4 of lastFrame = "fall" then
  18.       set tmp to random(3)
  19.       set NextFrame to "fall" & tmp
  20.     else
  21.       set NextFrame to lastFrame
  22.     end if
  23.   end if
  24.   SetQT()
  25. end
  26.  
  27. on BodyRollover
  28.   repeat with i = 18 to 26
  29.     if rollOver(i) then
  30.       set name to the name of cast the castNum of sprite i
  31.       set the itemDelimiter to "."
  32.       set name to item 1 of name
  33.       set the itemDelimiter to ","
  34.       set nameA to name & ".down"
  35.       set the castNum of sprite i to the number of cast nameA
  36.       updateStage()
  37.       repeat while rollOver(i) and not (the mouseDown)
  38.         CheckQT()
  39.         updateStage()
  40.       end repeat
  41.       set nameB to name & ".up"
  42.       set the castNum of sprite i to the number of cast nameB
  43.       exit repeat
  44.     end if
  45.   end repeat
  46. end
  47.  
  48. on ButtonClick
  49.   set me to the clickOn
  50.   repeat with i = 18 to 21
  51.     set name to the name of cast the castNum of sprite i
  52.     set the itemDelimiter to "."
  53.     set name to item 1 of name
  54.     set the itemDelimiter to ","
  55.     if i = me then
  56.       set name to name & ".off"
  57.     end if
  58.     put name
  59.     set the castNum of sprite i to the number of cast name
  60.   end repeat
  61. end
  62.  
  63. on ButtonsUp
  64.   repeat with i = 21 down to 18
  65.     set name to the name of cast the castNum of sprite i
  66.     set the itemDelimiter to "."
  67.     set name to item 1 of name
  68.     set the itemDelimiter to ","
  69.     set name to name & ".up"
  70.     set the castNum of sprite i to the number of cast name
  71.   end repeat
  72. end
  73.  
  74. on ButtonsDown a, b, c
  75.   global NextFrame
  76.   set xx to paramCount()
  77.   repeat with j = 1 to xx
  78.     set i to param(j)
  79.     set name to the name of cast the castNum of sprite i
  80.     set the itemDelimiter to "."
  81.     set name to item 1 of name
  82.     set the itemDelimiter to ","
  83.     set name to name & ".off"
  84.     set the castNum of sprite i to the number of cast name
  85.   end repeat
  86. end
  87.  
  88. on Buttons var
  89.   global endSection
  90.   if the paramCount = 0 then
  91.     set theClick to the clickOn
  92.   else
  93.     set theClick to var
  94.   end if
  95.   set temp to the castNum of sprite theClick
  96.   set the castNum of sprite theClick to temp + 1
  97.   updateStage()
  98.   set STIcks to the ticks
  99.   repeat while (the ticks - STIcks) < 10
  100.     CheckQT()
  101.   end repeat
  102.   set the castNum of sprite theClick to temp
  103.   updateStage()
  104. end
  105.  
  106. on NamesOff
  107.   puppetSprite(14, 0)
  108.   repeat with i = 35 to 47
  109.     set the locH of sprite i to 1000
  110.     puppetSprite(i, 0)
  111.   end repeat
  112. end
  113.