home *** CD-ROM | disk | FTP | other *** search
/ Sunday That One Day / STOD_VFS_INVIS.ISO / pc / map2.dxr / 00024.ls < prev    next >
Encoding:
Text File  |  1995-09-15  |  2.6 KB  |  93 lines

  1. on enterFrame
  2.   global gSprite2Cast, PlayedCarAnim, TimerCount
  3.   CursorOn()
  4.   updateStage()
  5.   set TimerCount to TimerCount + 1
  6.   if (TimerCount > 80) and (PlayedCarAnim = 0) then
  7.     puppetSprite(2, 0)
  8.     puppetSprite(3, 0)
  9.     puppetSprite(4, 0)
  10.     set TimerCount to 0
  11.     set PlayedCarAnim to 1
  12.     if gSprite2Cast = the number of cast "LakeWave1" then
  13.       CursorOff()
  14.       go("OtherCar1")
  15.     else
  16.       if gSprite2Cast = the number of cast "LakeWave2" then
  17.         CursorOff()
  18.         go("OtherCar2")
  19.       else
  20.         go("OtherCar3")
  21.         CursorOff()
  22.       end if
  23.     end if
  24.   else
  25.     if (TimerCount > 150) and (PlayedCarAnim = 1) then
  26.       puppetSprite(2, 0)
  27.       puppetSprite(3, 0)
  28.       puppetSprite(4, 0)
  29.       set TimerCount to 0
  30.       if gSprite2Cast = the number of cast "LakeWave1" then
  31.         CursorOff()
  32.         go("TownAnim1")
  33.       else
  34.         if gSprite2Cast = the number of cast "LakeWave2" then
  35.           CursorOff()
  36.           go("TownAnim2")
  37.         else
  38.           CursorOff()
  39.           go("TownAnim3")
  40.         end if
  41.       end if
  42.     end if
  43.   end if
  44. end
  45.  
  46. on exitFrame
  47.   global gSprite2Cast, gSprite3Cast, gSprite4Cast
  48.   puppetSprite(2, 1)
  49.   if gSprite2Cast = the number of cast "LakeWave1" then
  50.     set gSprite2Cast to the number of cast "LakeWave3"
  51.   else
  52.     if gSprite2Cast = the number of cast "LakeWave2" then
  53.       set gSprite2Cast to the number of cast "LakeWave1"
  54.     else
  55.       if gSprite2Cast = the number of cast "LakeWave3" then
  56.         set gSprite2Cast to the number of cast "LakeWave2"
  57.       end if
  58.     end if
  59.   end if
  60.   puppetSprite(3, 1)
  61.   if gSprite3Cast = the number of cast "PondWave1" then
  62.     set gSprite3Cast to the number of cast "PondWave2"
  63.   else
  64.     if gSprite3Cast = the number of cast "PondWave2" then
  65.       set gSprite3Cast to the number of cast "PondWave3"
  66.     else
  67.       if gSprite3Cast = the number of cast "PondWave3" then
  68.         set gSprite3Cast to the number of cast "PondWave1"
  69.       end if
  70.     end if
  71.   end if
  72.   puppetSprite(4, 1)
  73.   if gSprite4Cast = the number of cast "Fountain1" then
  74.     set gSprite4Cast to the number of cast "Fountain2"
  75.   else
  76.     if gSprite4Cast = the number of cast "Fountain2" then
  77.       set gSprite4Cast to the number of cast "Fountain3"
  78.     else
  79.       if gSprite4Cast = the number of cast "Fountain3" then
  80.         set gSprite4Cast to the number of cast "Fountain4"
  81.       else
  82.         if gSprite4Cast = the number of cast "Fountain4" then
  83.           set gSprite4Cast to the number of cast "Fountain1"
  84.         end if
  85.       end if
  86.     end if
  87.   end if
  88.   set the castNum of sprite 2 to gSprite2Cast
  89.   set the castNum of sprite 3 to gSprite3Cast
  90.   set the castNum of sprite 4 to gSprite4Cast
  91.   go(the frame)
  92. end
  93.