hi all

  wonder if u can help.

  how to get this same effect but fix the fact that if the sprite 
intersects an icon at the same time that the mouse is over another 
one then it keeps switching the flag on and off so it jumps the 
videos and sounds all the time

i tried putting this just b4 the updatestage but it doesnt work
         if sprite(4).intersects(i+4) = false then
           flag = 1 -- already started playing rand. on this node
         else
           flag = 0
         end if

any ideas

thanx

p///



----

var flag


repeat with i = 1 to Tlist[t].count
       if the rollover= i + 4 then -- mouse within the node
         if flag = 0 then -- it wasn't within before, so play
           sprite(i+4).visible=1 -- see the node
           sound fadeout 2, 30
           sprite(1).member = 
Tlist[t][i].MOimg[random(Tlist[t][i].MOimg.count)] -- random image
           puppetsound 3, 
Tlist[t][i].MOsnd[random(Tlist[t][i].mosnd.count)]-- play random sound

           set the text of member "name" = string(Tlist[t][i].LineSnd) 
--put name



           updatestage
           flag = 1 -- already started playing rand. on this node
         end if
       else if sprite(4).intersects(i+4) then -- mouse intersects node
         flag = 0 -- its just intersecting again, prepare to play
         sprite(i+4).visible=1 -- see the node
         if not soundbusy(5) then
           puppetsound 5, Tlist[t][i].LineSnd-- play line crossing sound
         end if

       else
         sprite(i+4).visible =0 -- dont see the node
       end if
     end repeat
   else
     repeat with i = 1 to Tlist[t].count
       if the rollover= i + 4 then -- mouse within the node
         if flag <> i then -- it wasn't within before, so play
           sound fadeout 2, 30
           sprite(1).member = 
Tlist[t][i].MOimg[random(Tlist[t][i].MOimg.count)] -- random image
           puppetsound 3, 
Tlist[t][i].MOsnd[random(Tlist[t][i].mosnd.count)]-- play random sound

           set the text of member "name" = string(Tlist[t][i].LineSnd) 
--put name

           updatestage
           flag = i -- already started playing rand. on this node
         end if
       end if
     end repeat


   end if


[To remove yourself from this list, or to change to digest mode, go to
http://www.penworks.com/LUJ/lingo-l.cgi  To post messages to the list,
email [EMAIL PROTECTED]  (Problems, email [EMAIL PROTECTED])
Lingo-L is for learning and helping with programming Lingo.  Thanks!]

Reply via email to