home *** CD-ROM | disk | FTP | other *** search
/ CD-ROM Fácil 3 / CDFACIL3.iso / lazer / desafios / stact101.Dxr / 00057.ls < prev    next >
Encoding:
Text File  |  1996-12-01  |  831 b   |  34 lines

  1. on exitFrame
  2.   global knock, simonpos, trylist, rand, head, step, simonlist, possiblelist
  3.   if knock = 1 then
  4.     cursor([52, 53])
  5.   else
  6.     cursor([50, 51])
  7.   end if
  8.   if knock = 1 then
  9.     set new to animehit()
  10.     if ((new = 1) and (count(trylist) = count(simonlist))) or (new = 0) then
  11.       set simonpos to 1
  12.       set rand to random(2)
  13.       set knock to 0
  14.       set step to 1
  15.       set head to 0
  16.       mydelay(0.20000000000000001)
  17.       if new > 0 then
  18.         add(simonlist, getAt(possiblelist, random(count(possiblelist))) + 1)
  19.       else
  20.         puppetSound("buzzer")
  21.       end if
  22.       set trylist to []
  23.       if count(simonlist) = 11 then
  24.         repeat with quik = 2 to 6
  25.           puppetSprite(quik, 0)
  26.         end repeat
  27.         go("rew1")
  28.       else
  29.         go(the frame - 16)
  30.       end if
  31.     end if
  32.   end if
  33. end
  34.