home *** CD-ROM | disk | FTP | other *** search
/ 1&1 Multimedia Trend 1996 10 B / MM_TREND.ISO / prog / t-online / shared.dir / 00305.ls < prev    next >
Encoding:
Text File  |  1996-08-16  |  11.2 KB  |  446 lines

  1. on Check48Rollover
  2.   global glSpriteRoll, giOtherSpn, giSPN, gb1u1Logo
  3.   set giSPN to 0
  4.   set giOtherSpn to 0
  5.   repeat with i = 26 to 47
  6.     if the castNum of sprite i > 0 then
  7.       if rollOver(i) then
  8.         set x to getAt(glSpriteRoll, i)
  9.         if x > 0 then
  10.           set giSPN to i
  11.           exit repeat
  12.           next repeat
  13.         end if
  14.       end if
  15.     end if
  16.   end repeat
  17.   if (gb1u1Logo = 1) and (the mouseDown = 1) then
  18.     set the visible of sprite 45 to 0
  19.     set gb1u1Logo to 0
  20.     updateStage()
  21.     set giSPN to 0
  22.   end if
  23. end
  24.  
  25. on CheckOtherRollover
  26.   global glOtherRoll, glOtherShow, giOtherSpn
  27.   set Anz to count(glOtherRoll)
  28.   repeat with i = 1 to Anz
  29.     if giOtherSpn = getAt(glOtherRoll, i) then
  30.       go(getAt(glOtherShow, i))
  31.     end if
  32.   end repeat
  33. end
  34.  
  35. on CheckMyRollover
  36.   global giOtherSpn, giSPN, glActiveRoll, gbSldOpen
  37.   Check48Rollover()
  38.   if gbSldOpen = 1 then
  39.     set x to getOne(glActiveRoll, giSPN)
  40.     if x = 0 then
  41.       set giSPN to 0
  42.     end if
  43.   end if
  44.   if giSPN > 0 then
  45.     ExecRollover()
  46.   else
  47.     ResetRollover()
  48.   end if
  49. end
  50.  
  51. on CheckNaviRollover
  52.   global giSPN
  53.   Check48Rollover()
  54.   if (giSPN > 25) and (giSPN < 29) then
  55.     ExecRollover()
  56.   else
  57.     ResetRollover()
  58.   end if
  59. end
  60.  
  61. on ExecRollover
  62.   global giLastSprite, glCastOfSprite, glSpriteRoll, giDownFlag, gbSldOpen, giSPN, giBlinkCast, gbISDN, giAuto
  63.   set spn to giSPN
  64.   set x to 0
  65.   set ok to 1
  66.   if (giLastSprite > 0) and (giLastSprite <> spn) then
  67.     ResetRollover()
  68.   end if
  69.   set y to getAt(glSpriteRoll, spn)
  70.   if y > 0 then
  71.     set x to getAt(glCastOfSprite, spn)
  72.     if the castNum of sprite spn = x then
  73.       if spn = 38 then
  74.         set ok to 0
  75.       end if
  76.       if spn = 45 then
  77.         set ok to 0
  78.       end if
  79.       if (spn = 43) and (gbSldOpen = 1) then
  80.         ChangeSndBtn(1)
  81.         set ok to 0
  82.       end if
  83.       if spn = (40 + gbISDN) then
  84.         set x to getAt(glCastOfSprite, 40 + gbISDN)
  85.         set the castNum of sprite (40 + gbISDN) to x
  86.       end if
  87.       if spn = 36 then
  88.         debug("change Auto: " & giAuto)
  89.         if giAuto = 0 then
  90.           set x to getAt(glOrigOfSprite, spn)
  91.           set the castNum of sprite spn to x + 7
  92.           debug("  + 7")
  93.         else
  94.           set x to getAt(glOrigOfSprite, spn)
  95.           set the castNum of sprite spn to x + 1
  96.           debug("   +1")
  97.         end if
  98.         set ok to 0
  99.         updateStage()
  100.       end if
  101.       if spn = 37 then
  102.         debug("change Auto: " & giAuto)
  103.         if giAuto = 1 then
  104.           set x to getAt(glOrigOfSprite, spn)
  105.           set the castNum of sprite spn to x + 7
  106.           debug("  + 7")
  107.         else
  108.           set x to getAt(glOrigOfSprite, spn)
  109.           set the castNum of sprite spn to x + 1
  110.           debug("   +1")
  111.         end if
  112.         set ok to 0
  113.         updateStage()
  114.       end if
  115.       if ok = 1 then
  116.         set the castNum of sprite spn to x + 1
  117.         updateStage()
  118.       end if
  119.     else
  120.       if (spn = 43) and (gbSldOpen = 1) then
  121.         ChangeSndBtn(1)
  122.         set ok to 0
  123.       end if
  124.     end if
  125.   else
  126.     if spn = 43 then
  127.       ChangeSndBtn(1)
  128.     end if
  129.   end if
  130.   if the mouseDown = 1 then
  131.     if giLastSprite = spn then
  132.       MyMouseDown()
  133.       set giDownFlag to spn
  134.       WaitTicks(5)
  135.       MyMouseUp()
  136.     end if
  137.   end if
  138.   set giLastSprite to spn
  139. end
  140.  
  141. on ChangeSndBtn art
  142.   global gbSldOpen, gbISDN, giSPN
  143.   set y to giSPN
  144.   if gbISDN then
  145.     set sp to 436
  146.   else
  147.     set sp to 380
  148.   end if
  149.   if art = 1 then
  150.     set x to 0
  151.   else
  152.     set x to 2
  153.   end if
  154.   if (gbSldOpen = 1) and (giSPN = 43) then
  155.     if the mouseH > 605 then
  156.       if the mouseV > 340 then
  157.         set the castNum of sprite 43 to sp + x
  158.       else
  159.         set the castNum of sprite 43 to sp + 1 + x
  160.       end if
  161.     end if
  162.     updateStage()
  163.   end if
  164. end
  165.  
  166. on ResetRollover
  167.   global giLastSprite, glCastOfSprite, glSpriteRoll, giDownFlag
  168.   if giLastSprite > 0 then
  169.     if giLastSprite <> 38 then
  170.       set x to getAt(glCastOfSprite, giLastSprite)
  171.       set the castNum of sprite giLastSprite to x
  172.       updateStage()
  173.     end if
  174.     set giDownFlag to 0
  175.     set giLastSprite to 0
  176.   end if
  177. end
  178.  
  179. on MyMouseDown
  180.   global giLastSprite, gbSldOpen, gb1u1Logo
  181.   debug("MyMouseDown: " & giLastSprite)
  182.   set x to 0
  183.   if giLastSprite > 0 then
  184.     set x to getAt(glSpriteRoll, giLastSprite)
  185.     if x > 0 then
  186.       PlayNoise("click")
  187.       if giLastSprite <> 38 then
  188.         set x to getAt(glCastOfSprite, giLastSprite)
  189.         set the castNum of sprite giLastSprite to x + 2
  190.         updateStage()
  191.       end if
  192.       if giLastSprite = 44 then
  193.         debug("show 1&1")
  194.         if the visible of sprite 45 = 1 then
  195.           set the visible of sprite 45 to 0
  196.           set gb1u1Logo to 0
  197.         else
  198.           set the visible of sprite 45 to 1
  199.           set gb1u1Logo to 1
  200.         end if
  201.         updateStage()
  202.       else
  203.         if the visible of sprite 45 = 1 then
  204.           debug("hide  1&1")
  205.           set the visible of sprite 45 to 0
  206.           set gb1u1Logo to 0
  207.           updateStage()
  208.         end if
  209.       end if
  210.       if gbSldOpen = 1 then
  211.         if giLastSprite = 39 then
  212.           ChangeSoundLevel()
  213.         else
  214.           if giLastSprite = 38 then
  215.             ChangeSoundOnOff()
  216.           else
  217.             if giLastSprite = 43 then
  218.               ChangeSndBtn(2)
  219.             else
  220.             end if
  221.           end if
  222.         end if
  223.       end if
  224.     else
  225.     end if
  226.   end if
  227.   debug("...down ready")
  228. end
  229.  
  230. on MyMouseUp
  231.   global giLastSprite, glAction, gbISDN, giExtraAction
  232.   set s to "  "
  233.   set x to 0
  234.   if giLastSprite > 0 then
  235.     set x to getAt(glSpriteRoll, giLastSprite)
  236.     if x > 0 then
  237.       debug("MsUpProc.." & giLastSprite)
  238.       updateStage()
  239.       if giLastSprite <> 38 then
  240.         set x to getAt(glCastOfSprite, giLastSprite)
  241.         set the castNum of sprite giLastSprite to x
  242.         updateStage()
  243.       end if
  244.       set z to giLastSprite
  245.       set s to getAt(glAction, giLastSprite)
  246.       debug(" call " & s)
  247.       if z = 26 then
  248.         GoPrev()
  249.       else
  250.         if z = 27 then
  251.           GoNext()
  252.         else
  253.           if z = 28 then
  254.             GoMenu()
  255.           else
  256.             if z = 34 then
  257.               Install()
  258.             else
  259.               if z = 35 then
  260.                 Antrag()
  261.               else
  262.                 if z = 36 then
  263.                   SetAutoNein()
  264.                 else
  265.                   if z = 37 then
  266.                     SetAutoJa()
  267.                   else
  268.                     if z = 38 then
  269.                       SetSound()
  270.                     else
  271.                       if z = 39 then
  272.                         SetSndLevel()
  273.                       else
  274.                         if z = 40 then
  275.                           if gbISDN = 0 then
  276.                             escInst()
  277.                           end if
  278.                         else
  279.                           if z = 41 then
  280.                             escAntrag()
  281.                           else
  282.                             if z = 42 then
  283.                               escAuto()
  284.                             else
  285.                               if z = 43 then
  286.                                 escSound()
  287.                               else
  288.                                 if z = 44 then
  289.                                 else
  290.                                   if z = 46 then
  291.                                     Finished()
  292.                                   else
  293.                                     if z = 99 then
  294.                                     else
  295.                                     end if
  296.                                   end if
  297.                                 end if
  298.                               end if
  299.                             end if
  300.                           end if
  301.                         end if
  302.                       end if
  303.                     end if
  304.                   end if
  305.                 end if
  306.               end if
  307.             end if
  308.           end if
  309.         end if
  310.       end if
  311.     else
  312.     end if
  313.   end if
  314.   if giExtraAction > 0 then
  315.     if giLastSprite > 0 then
  316.       debug("---EXTRA!")
  317.       ExtraAction()
  318.     end if
  319.   end if
  320.   debug("...up ready")
  321. end
  322.  
  323. on SliderVisible id, JaNein
  324.   global glCastOfSprite, glOrigOfSprite, giLastSprite, gbDoBlink, gbSldOpen, giSliderID, glStatus, giMusic, giNoise, giAuto, glActiveRoll, giMovieNr
  325.   debug("slider visible")
  326.   set x to 0
  327.   if JaNein = 1 then
  328.     if giMovieNr > 0 then
  329.       set x to giMovieNr
  330.       set giMovieNr to 0
  331.       repeat while the movieRate of sprite x > 0
  332.         nothing()
  333.       end repeat
  334.     end if
  335.     PlayNoise("ExtendTab")
  336.     set gbDoBlink to 0
  337.     set gbSldOpen to 1
  338.   end if
  339.   if id = 1 then
  340.     set the visible of sprite 30 to JaNein
  341.     set the visible of sprite 34 to JaNein
  342.     set glActiveRoll to [30, 34, 40]
  343.   end if
  344.   if id = 2 then
  345.     set the visible of sprite 31 to JaNein
  346.     set the visible of sprite 35 to JaNein
  347.     set glActiveRoll to [31, 35, 41]
  348.   end if
  349.   if id = 3 then
  350.     set the visible of sprite 32 to JaNein
  351.     if giAuto = 0 then
  352.       set x to getAt(glOrigOfSprite, 36)
  353.       set the castNum of sprite 36 to x + 2
  354.       set x to getAt(glOrigOfSprite, 37)
  355.       set the castNum of sprite 37 to x
  356.     else
  357.       set x to getAt(glOrigOfSprite, 36)
  358.       set the castNum of sprite 36 to x
  359.       set x to getAt(glOrigOfSprite, 37)
  360.       set the castNum of sprite 37 to x + 2
  361.     end if
  362.     set the visible of sprite 36 to JaNein
  363.     set the visible of sprite 37 to JaNein
  364.     set glActiveRoll to [32, 36, 37, 42]
  365.     debug(" CASTNUM: " & the castNum of sprite 36 & the castNum of sprite 37)
  366.   end if
  367.   if id = 4 then
  368.     set the visible of sprite 29 to JaNein
  369.     set the visible of sprite 33 to JaNein
  370.     set the visible of sprite 39 to JaNein
  371.     if JaNein = 1 then
  372.       set x to 0
  373.       set spn to 38
  374.       set x to getAt(glOrigOfSprite, spn)
  375.       debug("ORIG: " & x)
  376.       if giNoise = 1 then
  377.         if giMusic = 1 then
  378.           set the castNum of sprite spn to x
  379.         else
  380.           set the castNum of sprite spn to x + 2
  381.         end if
  382.       else
  383.         if giMusic = 1 then
  384.           set the castNum of sprite spn to x + 1
  385.         else
  386.           set the castNum of sprite spn to x + 3
  387.         end if
  388.       end if
  389.     end if
  390.     set the visible of sprite 38 to JaNein
  391.     set glActiveRoll to [29, 33, 39, 38, 43]
  392.   end if
  393.   set x to getAt(glCastOfSprite, giLastSprite)
  394.   if JaNein = 1 then
  395.     set y to x + 3
  396.   else
  397.     set y to x - 3
  398.   end if
  399.   setAt(glCastOfSprite, giLastSprite, y)
  400.   set the castNum of sprite giLastSprite to y
  401.   set the visible of sprite giLastSprite to 1
  402.   if JaNein = 1 then
  403.     set giSliderID to id
  404.     setAt(glStatus, id, 1)
  405.   else
  406.     set gbDoBlink to 1
  407.     set gbSldOpen to 0
  408.     set giSliderID to 0
  409.     setAt(glStatus, id, 0)
  410.     continue()
  411.   end if
  412.   debug("   ready slider")
  413.   updateStage()
  414. end
  415.  
  416. on ShowThemAll
  417.   repeat with i = 20 to 48
  418.     set the visible of sprite i to 1
  419.   end repeat
  420. end
  421.  
  422. on sliderOut id
  423.   global giLastSprite, giDummySliderId, giDummySliderHomeId, gbAnimation
  424.   exit
  425.   PlayNoise("ExtendTab")
  426.   set x to the locH of sprite giDummySliderHomeId
  427.   set y to the locV of sprite giLastSprite
  428.   set the locH of sprite giDummySliderId to x
  429.   set the locV of sprite giDummySliderId to y - 10
  430.   set the visible of sprite giDummySliderId to 1
  431.   updateStage()
  432.   if gbAnimation = 1 then
  433.     set the locH of sprite giDummySliderId to x - 70
  434.   else
  435.     repeat with i = 1 to 5
  436.       set the locH of sprite giDummySliderId to x
  437.       set x to x - 14
  438.       updateStage()
  439.     end repeat
  440.   end if
  441. end
  442.  
  443. on SliderBack
  444.   global giDummySliderId
  445. end
  446.