Fade in Images!

I have a simple slideshow with arrows whent clicked to jump to the next frame. I wonder is there a script for controling the alpha to fade the image in. Like for example: When I press the arrow button it jumps to the next frame and the image in the frame fades from 0% alpha to 100% but without the use of the timeline. I want to keep each frame one image if possible.

Thanks!

tripd

you would need some sort of a timer. i have no clue about timers or pacers in flash. good luck though, it’s possible…

Why don’t you just create a movieclip?

OR

You can use setIntervals and Functions

setInterval and functions:

 
function fadeIn (clip) {
	if (clip._alpha < 100) {
		clip._alpha += 1
	} else {
	clearInterval (time)
	}
}
time = setInterval (fadeIn, 50, picture) //50 is in milliseconds
//picture is the instance name of the movieclip that your picture is in

I think that’s right

Thanks
I’m getting a ton of syntax errors. I’m also a newbie in this thing. What do I have to replace? Lets say my movie clip is called “Fred” and the Instance name is “Fire” how would the code look then?? Also do I have to convert it to a movie not a graphic, right?

Thanks for your help!

tripd

Put this code on the frame at which you want to fade the picture:

 
function fadeIn () {
	if (Fire._alpha < 100) {
		Fire._alpha += 1
		//The higher the number the faster it fades
	} else {
		clearInterval (time)
	}
}
time = setInterval (fadeIn, 50) 
//50 is in milliseconds, so the lower the number, the faster it fades
 

Yes, it has to be a movieclip