Actionscript help - loadMovie
Discussion
I'm using actionscript to dynamically load jpegs for a image viewer using the loadMovie function.
I want to fade the current image out while the next image loads and then fade the next image in. I was thinking of doing this by having another movieclip on top of the picture, a white rectangle, which i increase the alpha to 100% to cover the photo, then decrease back to 0% to show the new photo.
Initially, my code should work like this:
On the mouse click, a function to start loading is executed. This had a loop to increase the alpha of the white rectangle. Once at 100%, a preloader is run which uses on EnterFrame. Once completely loaded, another loop is used to decrease the alpha to 0%.
Unfortunately, it doesn't work! When i test the movie, the rectangle disappears completely (i've tested it, making it orange an visible on the stage initially when the movie is run), as if the loadMovie function destroys it!
This is the first time i've used the loadMovie function so any info about it or advice would be good
Cheers
I want to fade the current image out while the next image loads and then fade the next image in. I was thinking of doing this by having another movieclip on top of the picture, a white rectangle, which i increase the alpha to 100% to cover the photo, then decrease back to 0% to show the new photo.
Initially, my code should work like this:
On the mouse click, a function to start loading is executed. This had a loop to increase the alpha of the white rectangle. Once at 100%, a preloader is run which uses on EnterFrame. Once completely loaded, another loop is used to decrease the alpha to 0%.
Unfortunately, it doesn't work! When i test the movie, the rectangle disappears completely (i've tested it, making it orange an visible on the stage initially when the movie is run), as if the loadMovie function destroys it!
This is the first time i've used the loadMovie function so any info about it or advice would be good
Cheers
Gassing Station | Computers, Gadgets & Stuff | Top of Page | What's New | My Stuff


