home *** CD-ROM | disk | FTP | other *** search
/ 1&1 Multimedia Trend 1996 10 B / MM_TREND.ISO / prog / t-online / shared.dir / 00306_Script_306 < prev    next >
Text File  |  1996-08-16  |  12KB  |  545 lines

  1. --Action
  2. --idle
  3.  
  4. on  idle
  5.   MyIdle
  6.   
  7. end idle
  8.  
  9.  
  10.  
  11. on Myidle
  12.   global gbDoBlink, gBlink, gAuto, gbISDN, giBlinkCast
  13.   global gbGoto, gsGoFrame, gsExtension, gbSldOpen
  14.   global gbQuitWait 
  15.   
  16.   --debug "idle..."
  17.   
  18.   -- blinken
  19.   if (gbDoBlink = true) then  
  20.     -- - 
  21.     if  (the ticks > gBlink) then
  22.       set x = 40 + gbISDN
  23.       if the castnum of sprite x =  giBlinkCast then 
  24.         set the castnum of sprite x to giBlinkCast + 2
  25.         set gBlink = the Ticks + 20
  26.       else
  27.         
  28.         set the castnum of sprite x to giBlinkCast
  29.         set gBlink = the Ticks  + 20
  30.       end if
  31.     end if  --ticks 
  32.     updatestage
  33.   end if -- doBlink
  34.   
  35.   -- autoloop
  36.   -- goto frame . hier, damit der stack der Proc intakt bleibt
  37.   if gbGoto = true then
  38.     debug "Goto in idle  <<<<<<<<:" & gsGoFrame & ":"
  39.     set gbGoto = false
  40.     cursor -1
  41.     set gbQuitWait = true
  42.     if gsGoFrame contains "," then
  43.       put item 1 of gsGoFrame into m
  44.       put item 2 of gsGoFrame into f
  45.       -- continue
  46.       go to frame f of movie m
  47.       exit
  48.     else
  49.       -- continue
  50.       go to gsGoFrame
  51.       exit
  52.     end if
  53.     
  54.   end if
  55.   
  56.   -- interims maus-check, bei paus einer animation
  57.   if gbSldOpen = true then
  58.     --debug "idle checkroll bei sld open"
  59.     CheckMyRollover
  60.   end if
  61.   
  62. end Myidle
  63.  
  64.  
  65. -- die Aktionen die beim globalen handle MousUp aufgerufen werden
  66. -- **********************MouseUp*****************************
  67. on Install
  68.   
  69.   global gsGoMain, gsGoSub
  70.   
  71.   debug "install t-online .. "
  72.   set gsGoMain ="Install"
  73.   set gsGoSub = ""
  74.   WriteParams  --in inifile
  75.   SendParams -- WinMsg
  76.   QuitMovie   --301
  77.   
  78.   
  79. end
  80.  
  81.  
  82. -- *********************MouseUp**************************
  83. on Antrag
  84.   
  85.   global gsGoMain, gsGoSub
  86.   
  87.   debug "Antragsformular "
  88.   set gsGoMain ="Antrag"
  89.   set gsGoSub = ""
  90.   WriteParams  --in inifile
  91.   SendParams -- WinMsg
  92.   
  93.   QuitMovie   --301
  94.   
  95. end
  96.  
  97.  
  98. -- ************************MouseUp****************************
  99. on SetAutoNein
  100.   -- Interaktiv !!!
  101.   global giAuto, giLastSprite
  102.   
  103.   -- die "orignal" castnummern sind die roten buttons
  104.   -- beim drⁿcken umsetzen
  105.   
  106.   debug "AutoInter:" & giAuto
  107.   
  108.   set x = 0
  109.   -- 36 auf grⁿn
  110.   put GetAt (glOrigOfSprite, giLastSprite) into x
  111.   setAt glCastOfSprite, giLastSprite, x +6
  112.   set the castnum of sprite giLastSprite = x + 6
  113.   
  114.   -- 37 auf rot
  115.   put GetAt (glOrigOfSprite, giLastSprite + 1) into x
  116.   setAt glCastOfSprite, (giLastSprite +1 ), x 
  117.   set the castnum of sprite (giLastSprite + 1) = x   
  118.   
  119.   updatestage
  120.   
  121.   set giAuto= 0
  122.   WriteParams
  123.   
  124. end
  125.  
  126.  
  127.  
  128. -- ****************************MouseUp****************************
  129. on SetAutoJa
  130.   -- gesteuert
  131.   global giAuto, giLastSprite
  132.   
  133.   -- die "orignal" castnummern sind die roten buttons
  134.   -- beim drⁿcken umsetzen
  135.   
  136.   debug "AutoGesteuert:" & giAuto
  137.   set x = 0
  138.   -- 37 auf grⁿn
  139.   put GetAt (glOrigOfSprite, giLastSprite) into x
  140.   setAt glCastOfSprite, giLastSprite, x +6
  141.   set the castnum of sprite giLastSprite = x + 6
  142.   
  143.   -- 36 auf rot
  144.   put GetAt (glOrigOfSprite, giLastSprite - 1) into x
  145.   setAt glCastOfSprite, (giLastSprite -1 ), x 
  146.   set the castnum of sprite (giLastSprite - 1) = x   
  147.   updatestage
  148.   
  149.   set giAuto= 1
  150.   WriteParams
  151.   
  152. end
  153.  
  154.  
  155. -- ****************************MouseUp*****************************
  156. on SetSound
  157.   -- mouse up ⁿber radio 
  158.   -- aktion erst bei click auf OK button
  159. end
  160.  
  161.  
  162. -- ****************************MouseUp*****************************
  163. on SetSndLevel
  164.   global giTmpLevel
  165.   
  166.   
  167.   debug "Set soundlevel: " & giTmpLevel
  168.   set x = integer(float(giTmpLevel) / 1.4)  --1..10 -> 1..7
  169.   set the soundLevel = x
  170.   
  171.   puppetsound "chord"  -- zum test
  172.   -- schreiben der params bei MouseUp auf Button!!
  173.   
  174. end
  175.  
  176. -- ***********************************************************
  177. -- -----------------bei mouse down -----------
  178. on ChangeSoundLevel
  179.   -- bewegung ds reglers
  180.   global giTmpLevel
  181.   
  182.   repeat while the mousedown
  183.     --put the mouseH
  184.     set the locH of sprite 39 to the mouseH
  185.     updatestage
  186.   end repeat
  187.   
  188.   set divi = 10
  189.   set y = float(1)
  190.   set Min = the Left of sprite 29
  191.   set Max = float(the width of sprite 29)
  192.   set pos = the left of sprite 39 + 10 -- +5 fⁿr mitte  
  193.   set x = pos - Min
  194.   if x < 0 then set x= 0
  195.   set y = float(x) / Max * divi
  196.   set y = integer(y) +1 
  197.   if y > 10 then set y = 10
  198.   
  199.   --set the movebleSprite of sprite 39 to true
  200.   --puppetSprite 39, TRUE
  201.   --set the moveableSprite of sprite 39 to TRUE
  202.   
  203.   set giTmpLevel = integer(y)
  204.   
  205.   debug "change sound...."
  206.   
  207.   -- debug "Pos: "& the left of sprite 39 & " x,y:" & x & "," & integer(y)
  208.   -- debug "Min/Max: " & Min & " , " & Max & 
  209.   
  210. end
  211.  
  212. -- -----------------------------------------------------
  213.  
  214. on ChangeSoundOnOff
  215.   -- bei mousedown auf die radiobuttons
  216.   --  (bei mouse up in datei)
  217.   global glOrigOfSprite
  218.   global giTmpNoise, giTmpMusic
  219.   
  220.   debug "change On/off"
  221.   set spn = 38
  222.   set Links = the Left of sprite spn
  223.   set pos = the mouseH - Links
  224.   
  225.   if (pos >1) and (pos<26) then
  226.     set giTmpNoise = 1   
  227.   else if (pos >29) and (pos<56) then
  228.     set giTmpNoise = 0 
  229.   else if (pos >70) and (pos<97) then
  230.     set giTmpMusic = 1  
  231.   else if (pos >103) and (pos<126) then
  232.     set giTmpMusic = 0
  233.   end if
  234.   ChangeSpriteSoundOnOff
  235.   
  236.   
  237. end
  238.  
  239. -- -----------------------------------------
  240. on ChangeSpriteSoundOnOff
  241.   -- sprite umsetzten bei radiobuttons
  242.   
  243.   global glOrigOfSprite
  244.   global giTmpNoise, giTmpMusic
  245.   
  246.   debug "change On/Off sprite"
  247.   set x = 0
  248.   set spn = 38
  249.   put getAt (glOrigOfSprite, spn) into x
  250.   if giTmpNoise =1 then
  251.     if giTmpMusic= 1 then 
  252.       set the castnum of sprite spn to x  
  253.     else
  254.       set the castnum of sprite spn to x +2
  255.     end if
  256.     
  257.   else  -- noise = 0
  258.     if giTmpMusic= 1 then 
  259.       set the castnum of sprite spn to x + 1  
  260.     else
  261.       set the castnum of sprite spn to x + 3
  262.     end if
  263.     
  264.   end if
  265.   updatestage  
  266. end
  267.  
  268.  
  269.  
  270.  
  271. -- ******************MouseUp*****************************************
  272.  
  273. --  ----------------    navigation -----------------
  274.  
  275.  
  276. -- ***********************************************************
  277. on GoNext
  278.   --  sucht ⁿber die marker funktion das nΣchste label
  279.   --  dann wird das label mit der bsListe geprⁿft
  280.   
  281.   global giError, gsX
  282.   global gbGoto, gsGoFrame, gsMenuName
  283.   
  284.   -- pause  --!!!!!!!!!!!!
  285.   
  286.   ChkFramePos 1      -- unten
  287.   StopThatSound  
  288.   
  289.   debug "GoNext: " & gsX
  290.   set gbGoto = true
  291.   set gsGoFrame = gsX
  292.   cursor 4
  293.   
  294. end
  295.  
  296.  
  297. -- ***********************************************************
  298. on GoPrev
  299.   global giError, gsX
  300.   global gbGoto, gsGoFrame, gsMenuName
  301.   
  302.   -- pause  --!!!!!!!!!!!!
  303.   
  304.   ChkFramePos  0     -- unten
  305.   StopThatSound  
  306.   debug "GoPrev: " & gsX
  307.   set gbGoto = true
  308.   set gsGoFrame = gsX
  309. end
  310.  
  311.  
  312.  
  313. -- ***********************************************************
  314. on GoMenu
  315.   -- menu in projektor
  316.   global  gsMenuName
  317.   global gbGoto, gsGoFrame, giAuto
  318.   
  319.   debug "go menu:" & gsMenuName 
  320.   
  321.   -- pause  --!!!!!!!!!!!!
  322.   
  323.   StopThatSound  -- util
  324.   set gbGoto = true
  325.   put GetAt (glGotoListe, 3) into gsGoFrame
  326.   if giAuto > 0 then
  327.     set giAuto = 0
  328.     WriteParams  
  329.     
  330.   end if
  331.   
  332. end
  333.  
  334.  
  335. -- ***********************************************************
  336. on Finished
  337.   -- exit zum lader 
  338.   global gsGoMain, gsGoSub, gbDebug, gbISDN
  339.   
  340.   debug "ende des movies"
  341.   StopThatSound
  342.   
  343.   set gsGoMain ="Ende"
  344.   set gsGoSub = ""
  345.   WriteParams  --in inifile
  346.   SendParams -- WinMsg
  347.   
  348.   QuitMovie   --301
  349.   
  350. end
  351.  
  352.  
  353. -- ***********************************************************
  354. on EinsInfo
  355.   global giLastSprite
  356.   
  357.   if giLastSprite <> 44 then
  358.     set the visible of sprite 45 to false
  359.   end if
  360.   
  361. end
  362.  
  363.  
  364.  
  365.  
  366.  
  367.  
  368. -- ***********************************************************
  369. --  ----------------   Slider/ ESC/ OK -----------------
  370. -- ***********************************************************
  371.  
  372.  
  373. on escInst
  374.   global giLastSprite, giSliderID, glStatus
  375.   global gsGoMain, gsGoSub, gbDebug
  376.   
  377.   debug "proc BtnIst.."
  378.   if (giSliderId = 0) then  -- and (getAt (glStatus ,1) = 0) then
  379.     SliderVisible 1, 1
  380.   else
  381.     if giSliderId = 1 then
  382.       SliderVisible 1, 0
  383.     end if
  384.   end if
  385. end BtnInst
  386.  
  387.  
  388. -- ***********************************************************
  389.  
  390. on escAntrag
  391.   
  392.   global giLastSprite, giSliderID, glStatus, glCastOfSprite
  393.   
  394.   debug "proc BtnAntrag.."
  395.   
  396.   -- zeigen / unsichtbar der elemente auf slider
  397.   if (giSliderId = 0) then  
  398.     SliderVisible 2, 1
  399.   else
  400.     if giSliderId = 2 then
  401.       SliderVisible 2, 0
  402.     end if
  403.   end if
  404. end
  405.  
  406.  
  407. -- ***********************************************************
  408.  
  409. on escAuto
  410.   -- Auto Animatio On/Off
  411.   global giLastSprite, giSliderID, glStatus, glCastOfSprite
  412.   
  413.   debug "proc BtnAuto.."
  414.   
  415.   -- zeigen / unsichtbar der elemente auf slider
  416.   if (giSliderId = 0) then  
  417.     SliderVisible 3, 1
  418.   else
  419.     if giSliderId = 3 then
  420.       SliderVisible 3, 0
  421.     end if
  422.   end if
  423.   debug "  ready BtnAuto"
  424. end
  425.  
  426.  
  427.  
  428. -- *********************** OK / ESC ***************************
  429.  
  430. on escSound
  431.   --
  432.   global giLastSprite, giSliderID, glStatus, glCastOfSprite
  433.   global giTmpNoise, giTmpMusic, giTmpLevel
  434.   global giNoise, giMusic, giSoundLevel
  435.   
  436.   debug "proc sound."
  437.   
  438.   -- zeigen / unsichtbar der elemente auf slider
  439.   if (giSliderId = 0) then 
  440.     SliderVisible 4, 1
  441.   else
  442.     if giSliderId = 4 then
  443.       if the mouseV < 335 then  -- OK
  444.         set giMusic = giTmpMusic
  445.         set giNoise = giTmpNoise
  446.         set giSoundLevel = giTmpLevel
  447.         WriteParams
  448.       end if
  449.       SliderVisible 4, 0
  450.     end if
  451.   end if
  452. end
  453.  
  454. -- ***********************************************************
  455.  
  456.  
  457. on DummyAction
  458.   debug "Dummy !! .. "
  459. end
  460.  
  461. -- ***********************************************************
  462.  
  463. on GoKatalog X
  464.   
  465.   global gsGoMain, gsGoSub
  466.   
  467.   debug "katalog ... "
  468.   set gsGoMain = X
  469.   set gsGoSub = ""
  470.   WriteParams  --in inifile
  471.   SendParams -- WinMsg
  472.   
  473.   QuitMovie   --301
  474.   
  475. end
  476.  
  477.  
  478. -- *************************************************
  479.  
  480. on ChkFramePos Richtung
  481.   -- prⁿft, ob die MarkerPos noch in der Liste ist
  482.   
  483.   global glBsListe, glBsFrame, giError, gsX, giAuto
  484.   
  485.   set fnr = 0
  486.   set idx = 0
  487.   set gsX = ""
  488.   set wo = the frame
  489.   
  490.   put Marker (Richtung) into fnr   -- frame nummer
  491.   put GetOne (glBsFrame, fnr) into idx  -- index oder 0
  492.   debug "ChkFrame: " & wo & " zu: " & fnr &", "& idx
  493.   
  494.   
  495.   if idx = 0 then
  496.     -- kein marker gefunden, gehe zu inhalt
  497.     debug ">>>>>marker not found"
  498.     --set giError = 0
  499.     --put GetAt (glGotoListe, 3) into gsX
  500.     
  501.   end if
  502.   
  503.   if richtung = 0 then
  504.     -- zurⁿck
  505.     
  506.     if idx > 1 then
  507.       -- es gibt marker weiter vorne 
  508.       put GetAt (glBsListe, idx -1) into gsX
  509.     else
  510.       -- gehezu vorigem movie
  511.       if giAuto = 0 then
  512.         put GetAt (glGotoListe, 1) into gsX
  513.       else
  514.         -- voriger in auto-folge
  515.         put GetAt (glGotoListe, 4) into gsX
  516.       end if
  517.     end if
  518.     
  519.   else -- VOR ---
  520.     
  521.     if fnr > wo then
  522.       if idx > 0 then
  523.         -- es gibt marker weiter hinten 
  524.         put GetAt (glBsListe, idx) into gsX
  525.       else
  526.         -- nach letztem in bsliste, dann weiter
  527.         put GetAt (glGotoListe, 2) into gsX
  528.       end if
  529.       
  530.     else
  531.       -- aus der gotoliste
  532.       if giAuto = 0 then
  533.         -- gehezu nΣchstem movie
  534.         put GetAt (glGotoListe, 2) into gsX
  535.       else
  536.         -- nΣchster in auto-folge
  537.         put GetAt (glGotoListe, 5) into gsX
  538.       end if
  539.       
  540.     end if
  541.     debug "Frame=: "  & gsX
  542.   end if  --rechung
  543. end
  544.  
  545.