home *** CD-ROM | disk | FTP | other *** search
/ What PC? 1996 August / WPCAUG96.ISO / refwaug.dxr / 00023_REFQuitCD.ls < prev    next >
Encoding:
Text File  |  1996-06-14  |  2.4 KB  |  67 lines

  1. on REFQuitCD
  2.   global REFQuittingList, IFLQuitsprite, REFQuitCounter, REFChooseQuit
  3.   if rollOver(IFLQuitsprite) then
  4.     repeat with t = 1 to count(REFQuittingList)
  5.       if t <> 1 then
  6.         setAt(getAt(REFQuittingList, t), 2, the castNum of sprite getAt(getAt(REFQuittingList, t), 1))
  7.       end if
  8.       set the castNum of sprite getAt(getAt(REFQuittingList, t), 1) to getAt(getAt(REFQuittingList, t), 3)
  9.       set the ink of sprite getAt(getAt(REFQuittingList, t), 1) to getAt(getAt(REFQuittingList, t), 5)
  10.     end repeat
  11.     updateStage()
  12.     repeat while rollOver(IFLQuitsprite)
  13.       if the mouseDown then
  14.         set REFChooseQuit to 1
  15.         set the castNum of sprite 48 to 208
  16.         set the locH of sprite 48 to 500
  17.         set the locV of sprite 48 to 420
  18.         set the ink of sprite 48 to 39
  19.         set the castNum of sprite IFLQuitsprite to 212
  20.         updateStage()
  21.         exit repeat
  22.       end if
  23.     end repeat
  24.     if REFChooseQuit = 1 then
  25.       repeat while 1
  26.         wait(0.01)
  27.         set REFQuitCounter to 1 + REFQuitCounter
  28.         if REFQuitCounter = 30 then
  29.           set the castNum of sprite 48 to the castNum of sprite 48 + 1
  30.           updateStage()
  31.         else
  32.           if REFQuitCounter = 60 then
  33.             set REFQuitCounter 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 REFQuitCounter to 0
  41.           set REFChooseQuit 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 REFQuitCounter to 0
  46.           set REFChooseQuit to 2
  47.           exit repeat
  48.         end if
  49.       end repeat
  50.     end if
  51.     if REFChooseQuit = 0 then
  52.       repeat with t = 1 to count(REFQuittingList)
  53.         set the castNum of sprite getAt(getAt(REFQuittingList, t), 1) to getAt(getAt(REFQuittingList, t), 2)
  54.         set the ink of sprite getAt(getAt(REFQuittingList, t), 1) to getAt(getAt(REFQuittingList, t), 4)
  55.       end repeat
  56.       updateStage()
  57.     end if
  58.   end if
  59.   if REFChooseQuit = 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.