home *** CD-ROM | disk | FTP | other *** search
/ Internet 1996 World Exposition / park.org.s3.amazonaws.com.7z / park.org.s3.amazonaws.com / Japan / Panasonic- / funcity / tokyo / slot.dcr / 00065_Coin.ls < prev    next >
Encoding:
Text File  |  2017-09-21  |  2.2 KB  |  113 lines

  1. on movecoin
  2.   global gcoin, gbet
  3.   if gcoin >= 10 then
  4.     set the puppet of sprite 45 to 1
  5.     set the castNum of sprite 45 to 12
  6.     repeat while stillDown()
  7.       set the locV of sprite 45 to the mouseV - 5
  8.       set the locH of sprite 45 to the mouseH
  9.       if gbet = 0 then
  10.         movelamp(1)
  11.       else
  12.         movelamp(2)
  13.       end if
  14.       updatelamp()
  15.       updateStage()
  16.     end repeat
  17.     set the puppet of sprite 45 to 0
  18.     if (the mouseV > 132) and (the mouseV < 139) and (the mouseH > 256) and (the mouseH < 286) then
  19.       if gbet = 0 then
  20.         resetlamp(2)
  21.       end if
  22.       set gbet to gbet + 1
  23.       if (gcoin / 10) > 14 then
  24.         set gcoin to gcoin - 10
  25.         dspcoin()
  26.       else
  27.         set gcoin to gcoin - 10
  28.         setname()
  29.       end if
  30.       puppetSound("3.coin")
  31.     end if
  32.     updateStage()
  33.   end if
  34. end
  35.  
  36. on dspcoin
  37.   global gcoin
  38.   setname()
  39.   set i to gcoin / 10
  40.   if i < 15 then
  41.     clearcoin()
  42.     repeat with j = 31 to 44
  43.       if i = 0 then
  44.         exit repeat
  45.       end if
  46.       set the puppet of sprite j to 0
  47.       set the visible of sprite j to 1
  48.       set i to i - 1
  49.     end repeat
  50.   else
  51.     if i < 100 then
  52.       setcoin(31, 4, 232, 209)
  53.     else
  54.       if i < 200 then
  55.         setcoin(31, 5, 232, 209)
  56.       else
  57.         if i < 350 then
  58.           setcoin(31, 6, 230, 208)
  59.         else
  60.           if i < 500 then
  61.             setcoin(31, 7, 231, 209)
  62.           else
  63.             setcoin(31, 8, 229, 207)
  64.           end if
  65.         end if
  66.       end if
  67.     end if
  68.   end if
  69. end
  70.  
  71. on setcoin i, j, k, l
  72.   clearcoin()
  73.   set the puppet of sprite i to 1
  74.   set the castNum of sprite i to j
  75.   set the locH of sprite i to k
  76.   set the locV of sprite i to l
  77.   set the visible of sprite i to 1
  78. end
  79.  
  80. on clearcoin
  81.   repeat with i = 31 to 44
  82.     set the visible of sprite i to 0
  83.     set the puppet of sprite i to 0
  84.   end repeat
  85. end
  86.  
  87. on allcoin
  88. end
  89.  
  90. on setname
  91.   global gname, gcoin
  92.   if gname = EMPTY then
  93.     set n to "├ç┬Å├ç├Æ├ç├ù├çΓÇó" && "/ "
  94.   else
  95.     set n to gname && "/ "
  96.   end if
  97.   if gcoin = 0 then
  98.     set n to n & "0" && "Pg"
  99.   else
  100.     set n to n & gcoin && "Pg"
  101.   end if
  102.   put n into field "NAME"
  103. end
  104.  
  105. on setbet
  106.   global gbet, gcoin
  107.   if gcoin >= 10 then
  108.     set gcoin to gcoin - 10
  109.     set gbet to gbet + 1
  110.     dspcoin()
  111.   end if
  112. end
  113.