home *** CD-ROM | disk | FTP | other *** search
/ What PC? 1997 December / WPCDEC97.ISO / DXRS / RESWDEC.DXR / 00012_MGIQuitCD.ls < prev    next >
Encoding:
Text File  |  1997-10-13  |  2.4 KB  |  67 lines

  1. on RESQuitCD
  2.   global RESQuittingList, IFLQuitsprite, RESQuitCounter, RESChooseQuit
  3.   if rollOver(IFLQuitsprite) then
  4.     repeat with t = 1 to count(RESQuittingList)
  5.       if t <> 1 then
  6.         setAt(getAt(RESQuittingList, t), 2, the castNum of sprite getAt(getAt(RESQuittingList, t), 1))
  7.       end if
  8.       set the castNum of sprite getAt(getAt(RESQuittingList, t), 1) to getAt(getAt(RESQuittingList, t), 3)
  9.       set the ink of sprite getAt(getAt(RESQuittingList, t), 1) to getAt(getAt(RESQuittingList, t), 5)
  10.     end repeat
  11.     updateStage()
  12.     repeat while rollOver(IFLQuitsprite)
  13.       if the mouseDown then
  14.         set RESChooseQuit to 1
  15.         set the castNum of sprite 48 to 84
  16.         set the locH of sprite 48 to 522
  17.         set the locV of sprite 48 to 446
  18.         set the ink of sprite 48 to 36
  19.         set the castNum of sprite IFLQuitsprite to 83
  20.         updateStage()
  21.         exit repeat
  22.       end if
  23.     end repeat
  24.     if RESChooseQuit = 1 then
  25.       repeat while 1
  26.         wait(0.01)
  27.         set RESQuitCounter to 1 + RESQuitCounter
  28.         if RESQuitCounter = 30 then
  29.           set the castNum of sprite 48 to the castNum of sprite 48 + 1
  30.           updateStage()
  31.         else
  32.           if RESQuitCounter = 60 then
  33.             set RESQuitCounter to 0
  34.             set the castNum of sprite 48 to the castNum of sprite 48 - 1
  35.             updateStage()
  36.           end if
  37.         end if
  38.         if (the mouseH > 548) and (the mouseH < 605) and (the mouseV > 431) and (the mouseV < 469) and the mouseDown then
  39.           set the locH of sprite 48 to 2000
  40.           set RESQuitCounter to 0
  41.           set RESChooseQuit to 0
  42.           exit repeat
  43.         end if
  44.         if (the mouseH > 442) and (the mouseH < 504) and (the mouseV > 431) and (the mouseV < 469) and the mouseDown then
  45.           set RESQuitCounter to 0
  46.           set RESChooseQuit to 2
  47.           exit repeat
  48.         end if
  49.       end repeat
  50.     end if
  51.     if RESChooseQuit = 0 then
  52.       repeat with t = 1 to count(RESQuittingList)
  53.         set the castNum of sprite getAt(getAt(RESQuittingList, t), 1) to getAt(getAt(RESQuittingList, t), 2)
  54.         set the ink of sprite getAt(getAt(RESQuittingList, t), 1) to getAt(getAt(RESQuittingList, t), 4)
  55.       end repeat
  56.       updateStage()
  57.     end if
  58.   end if
  59.   if RESChooseQuit = 2 then
  60.     repeat with t = 1 to 48
  61.       puppetSprite(t, 0)
  62.     end repeat
  63.     go("Credits")
  64.     updateStage()
  65.   end if
  66. end
  67.