Hi,
What on the surface appeared to be an easy task has turned into a REAL mind bender!
I've got 3 clips being loaded into holding clips within a main clip.
What I want to do is give loading progress for the 3 clips as they are loaded in, so...... I have set up a loop to give me the “bytesLoaded” amount for each clip within an onEnterframe event
code:
_root.holdtext_mc.onEnterFrame = function() {
for (i in _root.ticking_array) {//ticking_array holds references to the clips.
eachLoad = (Math.floor((_root.ticking_array[i].getBytesLoaded()/1024)));
Now I've got no problem with the amounts being captured by “eachLoad” - 3 progressing totals correctly giving the amounts of each clip loading – Where it is all going tits up is how I can get a total for these 3 amounts reflected in a trace statement or text field.
It sounds simple but has got the better of me! I have tried to load them into an array, but my understanding is that you cannot easily update the parameter held in an array without removing it first so the code
code:
_root.holdtext_mc.onEnterFrame = function() {
for (i in _root.ticking_array) {
_root.tot_array.push(Math.floor((_root.ticking_arr ay[i].getBytesLoaded()/1024)));
}
will just stuff a new amount into a new position in the array
I have tried to use a variable to capture each amount & then add that to a variable keeping track of the total but at best this will give you an “Unnatural” block amount as the totals for all 3 clips are traced out – say first frame 34 next frame & trace statement 64 no single unit incrementation.
Any help please.