home *** CD-ROM | disk | FTP | other *** search
/ PC Action 1997 February / PCA0297.ISO / demos / shine / ee.dxr / 00071.ls < prev    next >
Encoding:
Text File  |  1996-08-18  |  2.1 KB  |  94 lines

  1. on startMovie
  2.   global orgelH, stuhlH, liftH, mainH, sideH, mytempo, VentH, colorpower, kellergitter, eetermpwr, drehs
  3.   set colorpower to 1
  4.   set eetermpwr to 1
  5.   set drehs to 0
  6.   if eetermpwr = 0 then
  7.     set the visible of sprite 19 to 0
  8.   else
  9.     if colorpower = 1 then
  10.       set the visible of sprite 19 to 1
  11.     end if
  12.   end if
  13.   set the visible of sprite 20 to 0
  14.   puppetSprite(20, 1)
  15.   set the locH of sprite 20 to 320
  16.   if colorpower = 0 then
  17.     set the visible of sprite 10 to 0
  18.   else
  19.     set the visible of sprite 10 to 1
  20.   end if
  21. end
  22.  
  23. on switch me, type
  24.   global delayT
  25.   set delayT to 5
  26.   if type = 1 then
  27.     set steps to 5
  28.   else
  29.     set steps to 4
  30.   end if
  31.   set s0 to the castNum of sprite me
  32.   set s1 to s0 - steps
  33.   set s2 to s0 + steps
  34.   if the name of cast s1 = "a" then
  35.     repeat with i = s0 down to s1
  36.       set the castNum of sprite me to i
  37.       startTimer()
  38.       repeat while the timer < delayT
  39.         updateStage()
  40.       end repeat
  41.       updateStage()
  42.     end repeat
  43.   else
  44.     if the name of cast s0 = "a" then
  45.       repeat with i = s0 to s2
  46.         set the castNum of sprite me to i
  47.         startTimer()
  48.         repeat while the timer < delayT
  49.           updateStage()
  50.         end repeat
  51.         updateStage()
  52.       end repeat
  53.     end if
  54.   end if
  55. end
  56.  
  57. on checkventh
  58.   global VentH, mainH, sideH, stuhlH, orgelH, mytempo
  59.   if VentH = 0 then
  60.     if (mainH = 0) and (mytempo > 0) then
  61.       switchvent()
  62.     else
  63.       if (mainH = 1) and (mytempo > 0) then
  64.         if mytempo <= 1 then
  65.           if ((orgelH + stuhlH) = 0) or ((orgelH + sideH) = 0) then
  66.             switchvent()
  67.           end if
  68.         else
  69.           if orgelH = 0 then
  70.             switchvent()
  71.           end if
  72.         end if
  73.       end if
  74.     end if
  75.   end if
  76. end
  77.  
  78. on switchvent
  79.   global VentH, mytempo
  80.   if VentH = 0 then
  81.     set VentH to 1
  82.     if mytempo > 0 then
  83.       puppetSound(2, the number of cast "Vout")
  84.     end if
  85.     set thenum to the number of cast "vent"
  86.     repeat with x = thenum down to thenum - 5
  87.       set the castNum of sprite 14 to x
  88.       updateStage()
  89.     end repeat
  90.     set the castNum of sprite 20 to the number of cast "La"
  91.     updateStage()
  92.   end if
  93. end
  94.