home *** CD-ROM | disk | FTP | other *** search
/ 321 GAMES / 321GAMES.iso / logic / runes / runes.exe / runes.DXR / 00025_REMOVEFLOORS.ls < prev    next >
Encoding:
Text File  |  1996-07-01  |  2.0 KB  |  69 lines

  1. on REMOVEFLOORS
  2.   global GRIDX, GRIDY, GRIDVAL, BUTGRID, BG, DT, HEAD, MAN, TEMBUTGRID
  3.   set BG to 0
  4.   setAt(GRIDVAL, BUTGRID, 1)
  5.   puppetSound("BUTTON.WAV")
  6.   set DT to 5
  7.   COUNTTIME()
  8.   set DT to 1
  9.   set BUTGRID to 1000
  10.   set the trails of sprite 12 to 0
  11.   repeat with n = 1 to 168
  12.     if getAt(GRIDVAL, n) = 5 then
  13.       ANIMATEORACLE()
  14.       set the locH of sprite 12 to getAt(GRIDX, n)
  15.       set the locV of sprite 12 to getAt(GRIDY, n)
  16.       setAt(GRIDVAL, n, 0)
  17.       updateStage()
  18.       set the locH of sprite 12 to -2000
  19.       set the locV of sprite 12 to -2000
  20.       updateStage()
  21.     end if
  22.   end repeat
  23.   set the trails of sprite 12 to 1
  24.   set the trails of sprite 11 to 1
  25.   updateStage()
  26.   set DT to 1
  27.   repeat with n = 154 down to 1
  28.     if (getAt(GRIDVAL, n) = 2) and (getAt(GRIDVAL, n + 14) = 0) then
  29.       ANIMATEORACLE()
  30.       set the trails of sprite 11 to 0
  31.       set BG to n
  32.       setAt(GRIDVAL, n, 0)
  33.       set the locH of sprite 11 to getAt(GRIDX, n)
  34.       set the locV of sprite 11 to getAt(GRIDY, n)
  35.       updateStage()
  36.       repeat while getAt(GRIDVAL, BG + 14) = 0
  37.         repeat with M = 1 to 4
  38.           set the locV of sprite 11 to getAt(GRIDY, BG) + (M * 8)
  39.           updateStage()
  40.           COUNTTIME()
  41.         end repeat
  42.         set BG to BG + 14
  43.         set the locV of sprite 11 to getAt(GRIDY, BG)
  44.         updateStage()
  45.         if BG > 154 then
  46.           exit repeat
  47.         end if
  48.       end repeat
  49.       puppetSound("DROPROCK.WAV")
  50.       setAt(GRIDVAL, BG, 2)
  51.       ANIMATEORACLE()
  52.       set the trails of sprite 11 to 1
  53.       set the locV of sprite 11 to getAt(GRIDY, BG)
  54.       updateStage()
  55.       set the locH of sprite 11 to -2000
  56.       set the locV of sprite 11 to -2000
  57.       updateStage()
  58.     end if
  59.   end repeat
  60.   set the trails of sprite 11 to 0
  61.   if HEAD = 1 then
  62.     set the locH of sprite 11 to getAt(GRIDX, MAN - 14)
  63.     set the locV of sprite 11 to getAt(GRIDY, MAN - 14)
  64.   end if
  65.   set the locH of sprite 8 to -2000
  66.   set the locV of sprite 8 to -2000
  67.   updateStage()
  68. end
  69.