bjones8050
05-18-2005, 01:39 PM
Hi,
THE PROBLEM:
Incrementing alpha channel onEnterFrame, runs very inconsistent with lots of XML data. Runs fine with fewer items, but adding say 20 items makes things run very irradically.
THE BACKGROUND:
I've attached a small menu project I'm working on that has me stumped. I am loading XML data into flash for the menu, each xml "item" includes a title, description and an image link.
Flash loads in the xml, then, using MovieClipLoader() it consecutively displays each menu items title and desc as a button, once the items image has loaded. It also makes each of the images alpha set to 0 except the first.
When someone clicks a menu button, using onEnterFrame, I am telling the image for the item clicked to increment the alpha channel up from 0 until it reaches 100. once it reaches 100 I set the previous images alpha to zero, delete the onEnterFrame and we're done.
Works great, except with lots of XML data (like 20 or so) the incremental alpha channel onEnterFrame works very inconsistently, just chopping in for some, coming in really slow for others, and towards the very bottom of the script runing normal.
I thought it might not be deleting the onEnterFrame and gettign messed up but I'm pretty sure that is working OK.
Is there any reason loading 20 or so XML items would cause major performance problems?
Any thoughts are greatly appreciated, thanks for your time!
THE PROBLEM:
Incrementing alpha channel onEnterFrame, runs very inconsistent with lots of XML data. Runs fine with fewer items, but adding say 20 items makes things run very irradically.
THE BACKGROUND:
I've attached a small menu project I'm working on that has me stumped. I am loading XML data into flash for the menu, each xml "item" includes a title, description and an image link.
Flash loads in the xml, then, using MovieClipLoader() it consecutively displays each menu items title and desc as a button, once the items image has loaded. It also makes each of the images alpha set to 0 except the first.
When someone clicks a menu button, using onEnterFrame, I am telling the image for the item clicked to increment the alpha channel up from 0 until it reaches 100. once it reaches 100 I set the previous images alpha to zero, delete the onEnterFrame and we're done.
Works great, except with lots of XML data (like 20 or so) the incremental alpha channel onEnterFrame works very inconsistently, just chopping in for some, coming in really slow for others, and towards the very bottom of the script runing normal.
I thought it might not be deleting the onEnterFrame and gettign messed up but I'm pretty sure that is working OK.
Is there any reason loading 20 or so XML items would cause major performance problems?
Any thoughts are greatly appreciated, thanks for your time!