Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

movie inside of a loaded external movie

Participant ,
Jun 09, 2013 Jun 09, 2013

Hi

how to control a mc inside a loaded external movie?

so I have a main.swf, loaded a ex.swf into it by using loadMovie, and inside ex.swf there is a mc called 'mc'

how do I control 'mc' from main.swf? I tried something like newLoader.mc._x +=1;  ( newLoader is ex.swf), it doesn't work?

Thanks for reply.

TOPICS
ActionScript
376
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Jun 09, 2013 Jun 09, 2013

Show the code you use for loading ex.swf and explain how it acquires the identity of newLoader.

If I create an empty movieclip in the main file and assign it an instance name of "newLoader"... if I load ex.swf into that empty movieclip I am able to target it by that instance name and move the mc within it.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Participant ,
Jun 09, 2013 Jun 09, 2013
LATEST

Hi Ned

after I read your reply, i went on make a new sample file just to try it out, and it work, then I went back to my file and found out on these code

var currentObject = new Object;

currentObject = newLoader.newLoader2.newLoader3;

var currentObjectColor = new Object;

currentObjectColor = currentObject;  

and then I have

var my_color:Color = new Color(currentObjectColor.mc);

    trace (allowColor);

    my_color.setRGB(this.colorCC);

for some reason, after I replace currentObjectColor to just currentObject, it work just fine, I don't know if the problem is from putting one object equal another one, but as far as I need this would work for me.

thanks a lot.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines