home *** CD-ROM | disk | FTP | other *** search
/ Computer Music Interactif 7 / cd.iso / pc / PC / Demos / GroovMak / data1.cab / Program_Executable_Files / Media / grooveM.dxr / 00365.ls < prev    next >
Encoding:
Text File  |  1999-09-17  |  22.3 KB  |  561 lines

  1. on mouseDown
  2.   global gOn, gpag, gPath, gSong, gNumUser, gSync, stateTrackList, virTracklIst, apri
  3.   if not (the visible of window "help") then
  4.     if gOn then
  5.       if inside(the clickLoc, rect(615, 454, 634, 471)) then
  6.         repeat while the mouseDown
  7.           set the memberNum of sprite 13 to the number of member "Hquit"
  8.           set the ink of sprite 13 to 36
  9.           set the loc of sprite 13 to point(625, 464)
  10.           updateStage()
  11.         end repeat
  12.         pass()
  13.       end if
  14.       if inside(the clickLoc, rect(249, 169, 390, 310)) and not inside(the clickLoc, rect(292, 196, 348, 216)) and not inside(the clickLoc, rect(280, 236, 360, 242)) and not inside(the clickLoc, rect(292, 264, 348, 284)) and (virTracklIst <> [-1, -1, -1, -1, -1, -1, -1, -1]) and not gSync then
  15.         repeat while the mouseDown
  16.           set the memberNum of sprite 13 to the number of member "Hred"
  17.           set the ink of sprite 13 to 36
  18.           set the loc of sprite 13 to point(320, 240)
  19.           updateStage()
  20.         end repeat
  21.         pass()
  22.       end if
  23.       if inside(the clickLoc, rect(565, 52, 573, 60)) then
  24.         repeat while the mouseDown
  25.           set the memberNum of sprite 13 to the number of member "HpreviousPage"
  26.           set the ink of sprite 13 to 36
  27.           set the loc of sprite 13 to point(569, 57)
  28.           updateStage()
  29.         end repeat
  30.         pass()
  31.       end if
  32.       if inside(the clickLoc, rect(626, 52, 634, 60)) then
  33.         repeat while the mouseDown
  34.           set the memberNum of sprite 13 to the number of member "HnextPage"
  35.           set the ink of sprite 13 to 36
  36.           set the loc of sprite 13 to point(631, 57)
  37.           updateStage()
  38.         end repeat
  39.         pass()
  40.       end if
  41.       if inside(the clickLoc, rect(102, 150, 108, 159)) and (field "grooveMem" <> EMPTY) then
  42.         if (the lineCount of member "grooveMem" > 8) and not ((integer(chars(the name of member the memberNum of sprite 30, 2, length(the name of member the memberNum of sprite 30))) + 7) >= the lineCount of member "grooveMem") then
  43.           repeat while the mouseDown
  44.             set the memberNum of sprite 13 to the number of member "HnextGroove"
  45.             set the ink of sprite 13 to 36
  46.             set the loc of sprite 13 to point(106, 155)
  47.             updateStage()
  48.           end repeat
  49.           pass()
  50.         end if
  51.       end if
  52.       if inside(the clickLoc, rect(102, 308, 108, 316)) and (field "grooveMem" <> EMPTY) then
  53.         if the name of member the memberNum of sprite 30 <> "g1" then
  54.           repeat while the mouseDown
  55.             set the memberNum of sprite 13 to the number of member "HpreviousGroove"
  56.             set the ink of sprite 13 to 36
  57.             set the loc of sprite 13 to point(106, 312)
  58.             updateStage()
  59.           end repeat
  60.           pass()
  61.         end if
  62.       end if
  63.       if inside(the clickLoc, rect(592, 454, 611, 471)) then
  64.         repeat while the mouseDown
  65.           set the memberNum of sprite 13 to the number of member "Hpref"
  66.           set the ink of sprite 13 to 36
  67.           set the loc of sprite 13 to point(602, 464)
  68.           updateStage()
  69.         end repeat
  70.         pass()
  71.       end if
  72.       if inside(the clickLoc, rect(567, 433, 633, 446)) then
  73.         repeat while the mouseDown
  74.           set the memberNum of sprite 13 to the number of member "HvMix"
  75.           set the ink of sprite 13 to 36
  76.           set the loc of sprite 13 to point(601, 441)
  77.           updateStage()
  78.         end repeat
  79.         pass()
  80.       end if
  81.       if inside(the clickLoc, rect(22, 212, 78, 269)) then
  82.         if not ((getPos(stateTrackList, "on") = 0) and (getPos(stateTrackList, "solo") = 0)) then
  83.           set temp to chars(the name of member the memberNum of sprite 12, 2, length(the name of member the memberNum of sprite 12))
  84.           if not integerp(integer(temp)) then
  85.             repeat while the mouseDown
  86.               set the memberNum of sprite 13 to the number of member "Hmarker"
  87.               set the ink of sprite 13 to 36
  88.               set the loc of sprite 13 to point(51, 240)
  89.               updateStage()
  90.             end repeat
  91.           end if
  92.         end if
  93.         pass()
  94.       end if
  95.       if inside(the clickLoc, rect(35, 155, 81, 197)) then
  96.         if (stateTrackList <> ["off", "off", "off", "off", "off", "off", "off", "off"]) and (stateTrackList <> ["mute", "mute", "mute", "mute", "mute", "mute", "mute", "mute"]) then
  97.           repeat while the mouseDown
  98.             set the memberNum of sprite 13 to the number of member "HsaveGroove"
  99.             set the ink of sprite 13 to 36
  100.             set the loc of sprite 13 to point(58, 177)
  101.             updateStage()
  102.           end repeat
  103.         end if
  104.         pass()
  105.       end if
  106.       if inside(the clickLoc, rect(35, 283, 81, 325)) then
  107.         repeat while the mouseDown
  108.           set the memberNum of sprite 13 to the number of member "HloadGroove"
  109.           set the ink of sprite 13 to 36
  110.           set the loc of sprite 13 to point(58, 305)
  111.           updateStage()
  112.         end repeat
  113.         pass()
  114.       end if
  115.       if inside(the clickLoc, rect(567, 413, 633, 426)) then
  116.         repeat while the mouseDown
  117.           set the memberNum of sprite 13 to the number of member "Hseq"
  118.           set the ink of sprite 13 to 36
  119.           set the loc of sprite 13 to point(601, 422)
  120.           updateStage()
  121.         end repeat
  122.         pass()
  123.       end if
  124.       if inside(the clickLoc, rect(567, 372, 633, 387)) then
  125.         repeat while the mouseDown
  126.           set the memberNum of sprite 13 to the number of member "HsongMenu"
  127.           set the ink of sprite 13 to 36
  128.           set the loc of sprite 13 to point(601, 381)
  129.           updateStage()
  130.         end repeat
  131.         pass()
  132.       end if
  133.       if inside(the clickLoc, rect(508, 50, 563, 63)) then
  134.         if gNumUser < 16 then
  135.           repeat while the mouseDown
  136.             set the memberNum of sprite 13 to the number of member "HloadUser"
  137.             set the ink of sprite 13 to 36
  138.             set the loc of sprite 13 to point(536, 58)
  139.             updateStage()
  140.           end repeat
  141.         end if
  142.         pass()
  143.       end if
  144.     end if
  145.   end if
  146. end
  147.  
  148. on mouseUp
  149.   global gRandom, gTraccia, gSong, gBpmSong, gFirstNum, gOn, gpag, gReturn, gPath, gGrooveSel, gOnSynth, gArp, gProg, gPosVolSynth, gPosPanSynth, gNumUser, gMix, gGreen, gloadGroove, gSync, gFirstClick, gBlue, tempList, volValList, volPosList, stateTrackList, tapList, keepList, virTracklIst, panValList, panPosList, soloGroupList, progList, synthList, randomizeList, apri
  150.   if not (the visible of window "help") then
  151.     if inside(point(the mouseH, the mouseV), rect(615, 454, 634, 471)) then
  152.       openWin("YesNo")
  153.       tell window "YesNo"
  154.         go("quit")
  155.       end tell
  156.       pass()
  157.     end if
  158.     if inside(point(the mouseH, the mouseV), rect(249, 169, 390, 310)) and not inside(point(the mouseH, the mouseV), rect(292, 196, 348, 216)) and not inside(point(the mouseH, the mouseV), rect(280, 236, 360, 242)) and not inside(point(the mouseH, the mouseV), rect(292, 264, 348, 284)) and (virTracklIst <> [-1, -1, -1, -1, -1, -1, -1, -1]) and not gSync then
  159.       clickRed()
  160.       pass()
  161.     end if
  162.     if gOn then
  163.       if inside(point(the mouseH, the mouseV), rect(102, 150, 108, 159)) then
  164.         if (the lineCount of member "grooveMem" > 8) and not ((integer(chars(the name of member the memberNum of sprite 30, 2, length(the name of member the memberNum of sprite 30))) + 7) >= the lineCount of member "grooveMem") then
  165.           if gGrooveSel then
  166.             puppetSprite(12, 0)
  167.           end if
  168.           repeat with i = 1 to 8
  169.             set the memberNum of sprite (29 + i) to the memberNum of sprite (29 + i) + 1
  170.             updateStage()
  171.           end repeat
  172.           if gGrooveSel then
  173.             set firstNum to integer(chars(the name of member the memberNum of sprite 30, 2, length(the name of member the memberNum of sprite 30)))
  174.             set lastNum to integer(chars(the name of member the memberNum of sprite 37, 2, length(the name of member the memberNum of sprite 37)))
  175.             if (gGrooveSel >= firstNum) and (gGrooveSel <= lastNum) then
  176.               puppetSprite(12, 1)
  177.               set nS to "h" & gGrooveSel
  178.               set the memberNum of sprite 12 to the number of member nS
  179.               set the loc of sprite 12 to the loc of sprite (29 + (gGrooveSel - firstNum + 1))
  180.             end if
  181.           end if
  182.         end if
  183.         pass()
  184.       end if
  185.       if inside(the clickLoc, rect(102, 308, 108, 316)) and (field "grooveMem" <> EMPTY) then
  186.         if the name of member the memberNum of sprite 30 <> "g1" then
  187.           if gGrooveSel then
  188.             puppetSprite(12, 0)
  189.           end if
  190.           repeat with i = 8 down to 1
  191.             if chars(the name of member the memberNum of sprite (29 + i), 1, 2) <> "gr" then
  192.               set ultimo to integer(chars(the name of member the memberNum of sprite (29 + i), 2, length(the name of member the memberNum of sprite (29 + i))))
  193.               exit repeat
  194.             end if
  195.           end repeat
  196.           set j to 0
  197.           repeat with k = i + 1 down to 1
  198.             set j to j + 1
  199.             set nS to "g" & ultimo - j + 1
  200.             set the memberNum of sprite (29 + k) to the number of member nS
  201.           end repeat
  202.           if gGrooveSel then
  203.             set firstNum to integer(chars(the name of member the memberNum of sprite 30, 2, length(the name of member the memberNum of sprite 30)))
  204.             set lastNum to integer(chars(the name of member the memberNum of sprite 37, 2, length(the name of member the memberNum of sprite 37)))
  205.             if (gGrooveSel >= firstNum) and (gGrooveSel <= lastNum) then
  206.               puppetSprite(12, 1)
  207.               set nS to "h" & gGrooveSel
  208.               set the memberNum of sprite 12 to the number of member nS
  209.               set the loc of sprite 12 to the loc of sprite (29 + (gGrooveSel - firstNum + 1))
  210.             end if
  211.           end if
  212.           pass()
  213.         end if
  214.       end if
  215.       if inside(point(the mouseH, the mouseV), rect(565, 52, 573, 60)) then
  216.         if gpag <> 1 then
  217.           scrollByLine(member "fieldAudio", -20)
  218.           set gpag to gpag - 1
  219.         else
  220.           set q to the lineCount of member "fieldAudio" / 20
  221.           set r to the lineCount of member "fieldAudio" mod 20
  222.           if r then
  223.             set numPag to q + 1
  224.           else
  225.             set numPag to q
  226.           end if
  227.           scrollByLine(member "fieldAudio", 20 * (numPag - 1))
  228.           set gpag to numPag
  229.         end if
  230.         pass()
  231.       end if
  232.       if inside(point(the mouseH, the mouseV), rect(626, 52, 634, 60)) then
  233.         set q to the lineCount of member "fieldAudio" / 20
  234.         set r to the lineCount of member "fieldAudio" mod 20
  235.         if r then
  236.           set numPag to q + 1
  237.         else
  238.           set numPag to q
  239.         end if
  240.         if gpag <> numPag then
  241.           scrollByLine(member "fieldAudio", 20)
  242.           set gpag to gpag + 1
  243.         else
  244.           scrollByLine(member "fieldAudio", -20 * (numPag - 1))
  245.           set gpag to 1
  246.         end if
  247.         puppetSprite(13, 0)
  248.         pass()
  249.       end if
  250.       if inside(point(the mouseH, the mouseV), rect(592, 454, 611, 471)) then
  251.         set tapList to [0, 0]
  252.         set gReturn to "groove grooveM"
  253.         set gFirstNum to chars(the name of member the memberNum of sprite 30, 2, length(the name of member the memberNum of sprite 30))
  254.         if the visible of window "synth" then
  255.           close(window "synth")
  256.         end if
  257.         go("start", "pref")
  258.         pass()
  259.       end if
  260.       if inside(point(the mouseH, the mouseV), rect(567, 433, 633, 446)) then
  261.         set gFirstNum to chars(the name of member the memberNum of sprite 30, 2, length(the name of member the memberNum of sprite 30))
  262.         repeat with i = 3 to 5
  263.           puppetSprite(i, 0)
  264.         end repeat
  265.         puppetSprite(11, 0)
  266.         puppetSprite(12, 0)
  267.         puppetSprite(13, 0)
  268.         repeat with i = 14 to 21
  269.           puppetSprite(i, 0)
  270.         end repeat
  271.         puppetSprite(26, 0)
  272.         repeat with i = 30 to 37
  273.           puppetSprite(i, 0)
  274.         end repeat
  275.         set the memberNum of sprite 39 to 1000
  276.         repeat with i = 41 to 48
  277.           puppetSprite(i, 0)
  278.         end repeat
  279.         set tapList to [0, 0]
  280.         set keepList to [0, 0, 0, 0, 0, 0, 0, 0]
  281.         set soloGroupList to [0, 0, 0, 0, 0, 0, 0, 0]
  282.         if IKGetCurrentBeat() <> -1 then
  283.           if gOnSynth then
  284.             IKSynthStop()
  285.             set gOnSynth to 0
  286.           end if
  287.           IKStop()
  288.           IKFunction()
  289.           if gOnSynth and (synthList <> []) then
  290.             case char 1 of gArp of
  291.               "[":
  292.                 set arp to 1
  293.               "]":
  294.                 set arp to 2
  295.               "{":
  296.                 set arp to 4
  297.               "}":
  298.                 set arp to 8
  299.             end case
  300.             IKSynthVolume(integer(128 * (-gPosVolSynth + 54) / 45))
  301.             IKSynthPan(integer(128 * (-gPosPanSynth + 54) / 45))
  302.             IKSynthArp(getPos(progList, gProg) - 1, arp, createSeq())
  303.           end if
  304.         end if
  305.         put EMPTY into field "fieldBarBeat"
  306.         repeat with i = 1 to 8
  307.           if getAt(virTracklIst, i) <> -1 then
  308.             put "=" into word 1 of line getAt(virTracklIst, i) of field "fieldAudio"
  309.           end if
  310.         end repeat
  311.         go("vMix")
  312.         set the loc of sprite 39 to point(320, 226)
  313.         set bpm to float(field "fieldBpm")
  314.         set the locH of sprite 24 to (15 * 25 * (bpm - gBpmSong) / gBpmSong) + 321
  315.         set the locV of sprite 24 to 341
  316.         updateStage()
  317.         pass()
  318.       end if
  319.       if not gSync or (gSync and gFirstClick) then
  320.         set gFirstClick to 0
  321.         set random to 0
  322.         if inside(point(the mouseH, the mouseV), rect(109, 63, 130, 84)) then
  323.           set gRandom to getAt(randomizeList, 4)
  324.           set random to 1
  325.         end if
  326.         if inside(point(the mouseH, the mouseV), rect(129, 47, 150, 68)) then
  327.           set gRandom to getAt(randomizeList, 3)
  328.           set random to 1
  329.         end if
  330.         if inside(point(the mouseH, the mouseV), rect(150, 32, 171, 54)) then
  331.           set gRandom to getAt(randomizeList, 2)
  332.           set random to 1
  333.         end if
  334.         if inside(point(the mouseH, the mouseV), rect(171, 20, 193, 41)) then
  335.           set gRandom to getAt(randomizeList, 1)
  336.           set random to 1
  337.         end if
  338.         if random then
  339.           set random to 0
  340.           if gTraccia then
  341.             set the foreColor of word 2 of line getAt(virTracklIst, gTraccia) of field "fieldAudio" to gGreen
  342.           end if
  343.           set gTraccia to 0
  344.           set the loc of sprite 3 to point(529, 239)
  345.           set the loc of sprite 4 to point(543, 239)
  346.           if virTracklIst <> [-1, -1, -1, -1, -1, -1, -1, -1] then
  347.             repeat with i = 1 to 8
  348.               setAt(tempList, i, getAt(virTracklIst, i))
  349.             end repeat
  350.           end if
  351.           repeat with i = 1 to 8
  352.             if getAt(virTracklIst, i) <> -1 then
  353.               put "=" into word 1 of line getAt(virTracklIst, i) of field "fieldAudio"
  354.             end if
  355.           end repeat
  356.           set virTracklIst to [-1, -1, -1, -1, -1, -1, -1, -1]
  357.           set soloGroupList to [0, 0, 0, 0, 0, 0, 0, 0]
  358.           updateStage()
  359.           playRandom()
  360.           pass()
  361.         end if
  362.       end if
  363.       set traccia to 0
  364.       if not gSync then
  365.         if gTraccia <> 0 then
  366.           set the foreColor of word 2 of line getAt(virTracklIst, gTraccia) of field "fieldAudio" to gGreen
  367.         end if
  368.         if inside(point(the mouseH, the mouseV), rect(295, 42, 344, 92)) then
  369.           set gTraccia to 1
  370.           set traccia to 1
  371.         else
  372.           if inside(point(the mouseH, the mouseV), rect(295, 387, 344, 437)) then
  373.             set gTraccia to 5
  374.             set traccia to 1
  375.           end if
  376.         end if
  377.         if inside(point(the mouseH, the mouseV), rect(416, 91, 466, 141)) then
  378.           set gTraccia to 2
  379.           set traccia to 1
  380.         else
  381.           if inside(point(the mouseH, the mouseV), rect(416, 336, 466, 386)) then
  382.             set gTraccia to 4
  383.             set traccia to 1
  384.           end if
  385.         end if
  386.         if inside(point(the mouseH, the mouseV), rect(174, 91, 224, 141)) then
  387.           set gTraccia to 8
  388.           set traccia to 1
  389.         else
  390.           if inside(point(the mouseH, the mouseV), rect(174, 336, 224, 386)) then
  391.             set gTraccia to 6
  392.             set traccia to 1
  393.           end if
  394.         end if
  395.         if inside(point(the mouseH, the mouseV), rect(467, 216, 517, 266)) then
  396.           set gTraccia to 3
  397.           set traccia to 1
  398.         else
  399.           if inside(point(the mouseH, the mouseV), rect(123, 216, 173, 266)) then
  400.             set gTraccia to 7
  401.             set traccia to 1
  402.           end if
  403.         end if
  404.       end if
  405.       if traccia then
  406.         set traccia to 0
  407.         puppetSprite(12, 1)
  408.         clickTrack()
  409.         pass()
  410.       end if
  411.       if inside(point(the mouseH, the mouseV), rect(22, 212, 78, 269)) then
  412.         puppetSprite(13, 0)
  413.         if not ((getPos(stateTrackList, "on") = 0) and (getPos(stateTrackList, "solo") = 0)) then
  414.           set temp to chars(the name of member the memberNum of sprite 12, 2, length(the name of member the memberNum of sprite 12))
  415.           if not integerp(integer(temp)) then
  416.             clickMarker()
  417.           end if
  418.         end if
  419.         pass()
  420.       end if
  421.       if inside(point(the mouseH, the mouseV), rect(35, 155, 81, 197)) then
  422.         if (stateTrackList <> ["off", "off", "off", "off", "off", "off", "off", "off"]) and (stateTrackList <> ["mute", "mute", "mute", "mute", "mute", "mute", "mute", "mute"]) then
  423.           cursor(4)
  424.           saveGroove()
  425.           cursor(-1)
  426.         end if
  427.         pass()
  428.       end if
  429.       if inside(point(the mouseH, the mouseV), rect(35, 283, 81, 325)) then
  430.         set myFile to new(xtra("fileio"))
  431.         setFilterMask(myFile, ".txt")
  432.         set gloadGroove to displayOpen(myFile)
  433.         set myFile to 0
  434.         puppetSprite(13, 0)
  435.         pass()
  436.       end if
  437.       if inside(point(the mouseH, the mouseV), rect(489, 408, 523, 442)) then
  438.         set click to the timer
  439.         if getAt(tapList, 2) <> 0 then
  440.           if ((click - getAt(tapList, 2)) <= 80) and ((click - getAt(tapList, 2)) >= 10) then
  441.             puppetSprite(5, 0)
  442.             set media to float((click - getAt(tapList, 1)) / 2)
  443.             set bpm to float(3600) / media
  444.             if bpm > (6 * gBpmSong / 5) then
  445.               set bpm to float(6 * gBpmSong / 5)
  446.             end if
  447.             if bpm < (4 * gBpmSong / 5) then
  448.               set bpm to float(4 * gBpmSong / 5)
  449.             end if
  450.             set tapList to [0, 0]
  451.             IKMixBPM(bpm * 1000)
  452.             put bpm into field "fieldBpm"
  453.             set the textFont of member "fieldBpm" to "IK10"
  454.             set the foreColor of member "fieldBpm" to gGreen
  455.             set the locH of sprite 24 to (15 * 25 * (bpm - gBpmSong) / gBpmSong) + 321
  456.             set the locV of sprite 24 to 449
  457.             updateStage()
  458.           else
  459.             set tapList to [click, 0]
  460.             puppetSprite(5, 1)
  461.             set the memberNum of sprite 5 to the number of member "Htap"
  462.             set the loc of sprite 5 to point(507, 425)
  463.             set the ink of sprite 5 to 8
  464.             updateStage()
  465.           end if
  466.         else
  467.           if (getAt(tapList, 2) = 0) and (getAt(tapList, 1) <> 0) then
  468.             if ((click - getAt(tapList, 1)) <= 80) and ((click - getAt(tapList, 1)) >= 10) then
  469.               setAt(tapList, 2, click)
  470.             else
  471.               setAt(tapList, 1, click)
  472.             end if
  473.           else
  474.             setAt(tapList, 1, click)
  475.           end if
  476.           puppetSprite(5, 1)
  477.           set the memberNum of sprite 5 to the number of member "Htap"
  478.           set the loc of sprite 5 to point(507, 425)
  479.           set the ink of sprite 5 to 8
  480.           updateStage()
  481.         end if
  482.         pass()
  483.       end if
  484.       if inside(point(the mouseH, the mouseV), rect(567, 413, 633, 426)) then
  485.         if chars(the name of member the memberNum of sprite 30, 1, 2) <> "gr" then
  486.           set gFirstNum to chars(the name of member the memberNum of sprite 30, 2, length(the name of member the memberNum of sprite 30))
  487.         else
  488.           set gFirstNum to "0"
  489.         end if
  490.         repeat with i = 3 to 5
  491.           puppetSprite(i, 0)
  492.         end repeat
  493.         puppetSprite(11, 0)
  494.         puppetSprite(12, 0)
  495.         repeat with i = 13 to 21
  496.           puppetSprite(i, 0)
  497.         end repeat
  498.         puppetSprite(26, 0)
  499.         repeat with i = 30 to 37
  500.           puppetSprite(i, 0)
  501.         end repeat
  502.         repeat with i = 41 to 48
  503.           puppetSprite(i, 0)
  504.         end repeat
  505.         set the loc of sprite 39 to point(138, 239)
  506.         set the visible of sprite 5 to 1
  507.         set tapList to [0, 0]
  508.         set keepList to [0, 0, 0, 0, 0, 0, 0, 0]
  509.         set soloGroupList to [0, 0, 0, 0, 0, 0, 0, 0]
  510.         repeat with i = 1 to 8
  511.           if getAt(virTracklIst, i) <> -1 then
  512.             put "=" into word 1 of line getAt(virTracklIst, i) of field "fieldAudio"
  513.           end if
  514.         end repeat
  515.         go("seq")
  516.         put "00" & word 1 of field "fieldBarBeat" into word 1 of field "fieldBarBeat"
  517.         set bpm to float(field "fieldBpm")
  518.         set the locH of sprite 24 to (15 * ((100 * (bpm - gBpmSong) / gBpmSong) + 52) / 4) + 5
  519.         set the locV of sprite 24 to 362
  520.         updateStage()
  521.         put EMPTY into field "fieldState"
  522.         pass()
  523.       end if
  524.       if inside(point(the mouseH, the mouseV), rect(567, 372, 633, 387)) then
  525.         openWin("YesNo")
  526.         tell window "YesNo"
  527.           go("newSong")
  528.         end tell
  529.         pass()
  530.       end if
  531.       if inside(point(the mouseH, the mouseV), rect(508, 50, 563, 63)) then
  532.         puppetSprite(13, 0)
  533.         openWin("Message")
  534.         tell window "Message"
  535.           go("22")
  536.         end tell
  537.         pass()
  538.       end if
  539.       if inside(the clickLoc, rect(508, 67, 563, 79)) then
  540.         if not (the memberNum of sprite 26) then
  541.           puppetSprite(26, 1)
  542.           set the memberNum of sprite 26 to the number of member "Hkeep"
  543.           set the ink of sprite 26 to 36
  544.           set the loc of sprite 26 to point(536, 76)
  545.           updateStage()
  546.         else
  547.           puppetSprite(26, 0)
  548.           repeat with i = 1 to 8
  549.             if getAt(keepList, i) then
  550.               set the foreColor of word 1 of line getAt(virTracklIst, i) of field "fieldAudio" to gBlue
  551.             end if
  552.           end repeat
  553.           set keepList to [0, 0, 0, 0, 0, 0, 0, 0]
  554.         end if
  555.         pass()
  556.       end if
  557.     end if
  558.   end if
  559.   set the editable of member "fieldBpm" to 0
  560. end
  561.