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 / e / menu.dcr / 00001_-- movie script.ls next >
Encoding:
Text File  |  2017-09-21  |  7.5 KB  |  274 lines

  1. global oncursor, userid, userpw, userpm, userpg, lasteventtime, pmcginame, jumpmode, jumpmoviename, version
  2.  
  3. on startMovie
  4.   set pmcginame to "http://202.224.191.2/cgi-bin/EcOpe.cgi?"
  5.   set oncursor to [the number of cast "onCursor", the number of cast "onCursor" + 1]
  6.   set the buttonStyle to 1
  7.   cursor(oncursor)
  8.   set the textHeight of field "help" to 16
  9.   set the textHeight of field "info" to 16
  10.   set the textHeight of field "checkText1" to 16
  11.   set the textHeight of field "checkText2" to 16
  12.   set the textHeight of field "checkUserID" to 16
  13.   if voidp(userid) then
  14.     put "guest" into field "userID"
  15.     put "*****" into field "userPW"
  16.     put field "infoDe1" into field "info"
  17.   else
  18.     put userid into field "userID"
  19.     put userpw into field "userPW"
  20.     put field "infoDe2" into field "info"
  21.     if integer(char 1 of version) >= 5 then
  22.       gotonetpage("bgm.html", "low")
  23.     end if
  24.   end if
  25.   set lasteventtime to 0
  26. end
  27.  
  28. on stopMovie
  29.   put " " into field "userID"
  30.   put " " into field "userPW"
  31.   put " " into field "info"
  32. end
  33.  
  34. on gameback
  35.   if (the ticks - lasteventtime) > 15 then
  36.     set the puppet of sprite clickOn() to 0
  37.     if the frame >= label("bankResult") then
  38.       go(label("bank") + 1)
  39.     else
  40.       if the frame >= label("bank") then
  41.         go("loop")
  42.       else
  43.         if the frame >= label("help2") then
  44.           go("check")
  45.         else
  46.           if the frame >= label("help") then
  47.             go("loop")
  48.           else
  49.             jumpnetpage("http://japan.park.org/Japan/Panasonic/funcity/play.html")
  50.           end if
  51.         end if
  52.       end if
  53.     end if
  54.   end if
  55.   set lasteventtime to the ticks
  56. end
  57.  
  58. on gamehelp
  59.   set the puppet of sprite clickOn() to 0
  60.   if the frame >= label("check") then
  61.     go("help2")
  62.   else
  63.     go("help")
  64.   end if
  65. end
  66.  
  67. on jumpnetmovie mname
  68.   set jumpmoviename to mname
  69.   set userid to line 1 of field "userID"
  70.   set userpw to line 1 of field "userPW"
  71.   repeat with s = 1 to 48
  72.     set the puppet of sprite s to 0
  73.   end repeat
  74.   if userid = "guest" then
  75.     if mname = "goal.dcr" then
  76.       alert("Guests are not allowed in the" & RETURN & "Olympic stadium.")
  77.       go("loop")
  78.       abort()
  79.     else
  80.       alert("If you play as a guest," & RETURN & "you points will not be counted.")
  81.       set userpg to 2000
  82.       set userpm to "000000000000000000000000"
  83.       set jumpmode to 1
  84.       gotonetmovie(jumpmoviename)
  85.     end if
  86.   else
  87.     set jumpmode to 0
  88.     requestuserpm()
  89.   end if
  90.   go("move")
  91. end
  92.  
  93. on jumpnetpage pagename
  94.   allpuppetoff()
  95.   set jumpmode to 1
  96.   gotonetpage(pagename)
  97.   go("move")
  98. end
  99.  
  100. on requestuserpm
  101.   getnettext(pmcginame & "name=" & userid & "&" & "password=" & userpw)
  102. end
  103.  
  104. on checknetresult
  105.   if jumpmode then
  106.     exit
  107.   end if
  108.   if netdone() then
  109.     set nresult to nettextresult()
  110.     if nresult starts "<" then
  111.       alert(deletetag(nresult))
  112.       go("loop")
  113.       abort()
  114.     else
  115.       if nresult starts "E000" then
  116.         if line 1 of nresult = "E0000" then
  117.           set rtext to "Error : Server System Error"
  118.         else
  119.           if line 1 of nresult = "E0001" then
  120.             set rtext to "Error : " & userid & "The name is not registered."
  121.           else
  122.             if line 1 of nresult = "E0002" then
  123.               set rtext to "Error : The password is wrong."
  124.             else
  125.               if line 1 of nresult = "E0003" then
  126.                 set rtext to "Error : The parameter's form is wrong."
  127.               else
  128.                 if line 1 of nresult = "E0003" then
  129.                   set rtext to "Error : Your balance is short - you cannot make a withdrawal."
  130.                 end if
  131.               end if
  132.             end if
  133.           end if
  134.         end if
  135.         alert(rtext)
  136.         go("loop")
  137.         abort()
  138.       else
  139.         set userpg to integer(word 1 of nresult)
  140.         set userpm to word 2 of nresult
  141.         if jumpmoviename = "goal.dcr" then
  142.           checkmedallabel()
  143.         else
  144.           set jumpmode to 1
  145.           gotonetmovie(jumpmoviename)
  146.         end if
  147.       end if
  148.     end if
  149.   end if
  150. end
  151.  
  152. on checkmedallabel
  153.   if (userpg < 2000) or (integer(char 9 of userpm) < 2) or (integer(char 10 of userpm) < 2) or (integer(char 11 of userpm) < 2) or (integer(char 12 of userpm) < 2) or (integer(char 13 of userpm) < 2) or (integer(char 14 of userpm) < 2) then
  154.     beep()
  155.     go("check")
  156.     abort()
  157.   else
  158.     gotonetmovie(jumpmoviename)
  159.   end if
  160. end
  161.  
  162. on showuserpm
  163.   put userid into field "checkUserID"
  164.   put userpg & RETURN & pmtopoint(char 9 of userpm) & RETURN & pmtopoint(char 10 of userpm) & RETURN & pmtopoint(char 11 of userpm) & RETURN & pmtopoint(char 12 of userpm) & RETURN & pmtopoint(char 13 of userpm) & RETURN & pmtopoint(char 14 of userpm) into field "checktext2"
  165. end
  166.  
  167. on pmtopoint upm
  168.   if upm = 9 then
  169.     set upm to 10
  170.   end if
  171.   set upm to upm * 10
  172.   return integer(upm)
  173. end
  174.  
  175. on rolloverbtn
  176.   set rcnum to the mouseCast
  177.   if rcnum > 0 then
  178.     set rcname to string(the name of cast rcnum)
  179.     if item 2 of rcname = "off" then
  180.       repeat with s = 41 to 42
  181.         if the castNum of sprite s = rcnum then
  182.           if the mouseUp then
  183.             set the puppet of sprite s to 1
  184.             set the castNum of sprite s to rcnum + 1
  185.             if the frame <= label("loop") then
  186.               put field (item 1 of rcname & ".info") into field "info"
  187.               puppetSound("showInfo")
  188.             end if
  189.           end if
  190.           next repeat
  191.         end if
  192.         set the puppet of sprite s to 0
  193.       end repeat
  194.     else
  195.       if item 2 of rcname = "on" then
  196.         repeat with s = 41 to 42
  197.           if the castNum of sprite s = rcnum then
  198.             if the mouseDown and (clickOn() = s) then
  199.               set the castNum of sprite s to rcnum + 1
  200.               updateStage()
  201.               do(item 1 of rcname)
  202.             end if
  203.           end if
  204.         end repeat
  205.       else
  206.         if item 2 of rcname = "click" then
  207.           repeat with s = 41 to 42
  208.             if the castNum of sprite s = rcnum then
  209.               if the mouseUp then
  210.                 set the castNum of sprite s to rcnum - 1
  211.                 next repeat
  212.               end if
  213.             end if
  214.           end repeat
  215.         else
  216.           repeat with s = 41 to 42
  217.             set the puppet of sprite s to 0
  218.           end repeat
  219.         end if
  220.       end if
  221.     end if
  222.   else
  223.     repeat with s = 41 to 42
  224.       set the puppet of sprite s to 0
  225.     end repeat
  226.   end if
  227. end
  228.  
  229. on rolloverchar
  230.   repeat with s = 12 to 19
  231.     if rollOver(s) then
  232.       set chname to the name of cast the castNum of sprite s
  233.       if chname contains "loop" then
  234.         next repeat
  235.       end if
  236.       set the puppet of sprite s to 1
  237.       set the castNum of sprite s to the number of cast (chname & ".loop")
  238.       put field (chname & ".info") into field "info"
  239.       puppetSound("showInfo")
  240.       next repeat
  241.     end if
  242.     set the puppet of sprite s to 0
  243.   end repeat
  244.   repeat with s = 26 to 31
  245.     if rollOver(s) then
  246.       set chname to the name of cast the castNum of sprite s
  247.       if field (chname & ".info") <> field "info" then
  248.         put field (chname & ".info") into field "info"
  249.         puppetSound("showInfo")
  250.       end if
  251.     end if
  252.   end repeat
  253. end
  254.  
  255. on bannertext
  256.   set the puppet of sprite 21 to 1
  257.   set the locH of sprite 21 to the locH of sprite 21 - 4 + ((520 + the width of sprite 21) * (the right of sprite 21 < 0))
  258. end
  259.  
  260. on deletetag ctext
  261.   repeat while ctext contains "<"
  262.     set fchar to offset("<", ctext)
  263.     set echar to offset(">", ctext)
  264.     delete char fchar to echar of ctext
  265.   end repeat
  266.   return ctext
  267. end
  268.  
  269. on allpuppetoff
  270.   repeat with s = 1 to 48
  271.     set the puppet of sprite s to 0
  272.   end repeat
  273. end
  274.