Loading of external swf w/ animation

when i load an external swf w/ an animation tat is continuous (from kirupa.com tutorial) the animation only runs once, but if i go preview the swf with just the animation it works just fine. anyhelp would be greatly appreciated

Sounds like it is obeying a stop action from your main timeline,
…how are you loading the ext.SWF ?

im loading it like this:


design.onPress = function () {
	loadMovie("design.swf", "contents");
	contents._x = 152 ;
	contents._y = 20 ;
}

i have no stop actions or anything so i dont think that is it.

I don’t have flash on this box - so I straining to remember if there is a loop/notLoop selectable in the publish settings (?)

…it sure sounds like a stop in one of the timelines … on “contents” (?)

“contents” is an empty movie clip that the .swf’s are loaded into

bump… i need help. im having trouble figuring this out. if you need any more info just ask.

Why don’t you post your FLA so we can look at it, it would be a lot easier for us to help as well. =)

hold on a sec, gotta zip the second file is too big

alright here is a zip with the the first file

heres the other file

i took out most the bg’s and stuff for file size cause it was being gay and im not too good with this zipping business so if you need anything else just let me know.

Ok I figured out the problem and it had to do with your targeting.
This is the original script you had on your stars:[AS]onClipEvent (enterFrame) {
//generating movement
location = this._x;
var i;
i = 25;
if (this, hitTest(_root.block)) {
this._x = -1000;
} else {
this._x = location+i++;
}
}[/AS]
That will only work if design.swf is by itself. Once you load it into the main swf, you have to define that path of the block MC in order for the stars to hit.

So now the scirpt above needs to look like this:[AS]onClipEvent (enterFrame) {
//generating movement
location = this._x;
var i;
i = 25;
if (this, hitTest(_root.contents.block)) {
this._x = -1000;
} else {
this._x = location+i++;
}
}[/AS]

I added in “contents” to the line _root.contents.block because after design.swf is loaded into the main swf, block MC is located inside contents MC located on the _root which is the main timeline of main swf. I hope you got all that. :sigh:

thank you so much electron geek. it works dandy great now.

no problem, glad it worked. =)