dear all

I am having fun (?) trying to get a random element to work on a project. I 
had better explain.

Currently I have a mouseDown event that triggers at the same time

1.      A random change in the foreColor of a series of squares on the stage
2.      A random sound out of 64 small sound samples and
3.      A random change in 4 images, out of about 50, overlaying the coloured 
squares.

What I am trying to do is to a ripple effect, rather like throwing a stone 
in water. So as the ripples disperse, one intersects a particular coloured 
square sprite (that are still generated randomly) which in tern triggers the 
radom sound and images. I have tried to generate a ripple effect swapping 
cast members using 'memberNum' and I cannot get it to work properly. I have 
also got the 3 points above to work....However I am unable to get all of it 
to fit togeather.

Now it is likely that I am missing something incredibly obvious or something 
similar, but can anyone help,...please. I am posting my rather messy lingo 
below to give you some idea where I am coming from.

Please note that I recieve the digest form and that it is 2.30 am so I am 
going to get some rest if my brain will allow. You can always email me off 
list but I will post any success up.

on startMovie
--  puppetsprite 73, TRUE -- sprite 73 being the start of the ripple 
aniamtion
--  set the visible of sprite 73 to false
end


on exitFrame
  go to the frame
--  if the mouseDown = FALSE then
--    set the visible of sprite 73 to false
--  end if
end

--  the mouseUp handler generates the random images, squares and sounds
on mouseUp

  set songno = random(66)
  set imageno = random(8) -- coloured squares
  set pictno = random(44) -- images

  put songno
  put imageno
  put pictno


  puppetSound ("song_" & songno)
  set the member of sprite (1 + random(64)) to ("square_" & imageno)
  set the member of sprite (67 + random(4)) to ("pict_" & pictno)


end

-- this was bought in from a movie that sort of worked in order to generate 
a ripple. however I
-- have tried to mix this in with the above with litle success

on mouseDown


  set the locH of sprite 73 to the mouseH
  set the locV of sprite 73 to the mouseV
  set the visible of sprite 73 to true
  set the memberNum of sprite 73 to 121


  set the memberNum of sprite 73 to the memberNum of sprite 73 + 1
  if sprite 73 intersects 4 then puppetSound 4, "Bbom"
  if the memberNum of sprite 73 = 125 then set the blend of sprite 73 to 30
  if the memberNum of sprite 73 = 126 then set the blend of sprite 73 to 15
  if the memberNum of sprite 73 = 127 then set the blend of sprite 73 to 5
  if the memberNum of sprite 73 > 127 then set the visible of sprite 73 to 
false
  if the memberNum of sprite 73 > 127 then set the memberNum of sprite 73 to 
121
  if the memberNum of sprite 73 = 121 then set the blend of sprite 1 to 100
  updateStage
end if
end

--  if the memberNum of sprite 73 = 121 then

cheers

Mike Gilmour
MA student Multimedia UWCN
[EMAIL PROTECTED]
_________________________________________________________________________
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com.

Share information about yourself, create your own public profile at 
http://profiles.msn.com.


[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