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

AS2 drag and drop a masked content from loadMovie clip

Participant ,
Apr 08, 2013 Apr 08, 2013

In the main content, when I have a movie clip like this   a1.a2.a3 while  a3 inside a2 and a2 inside a1, and a2 is a masked layer movie clip.

I can drag and drop the masked content (while a1 stay still) with like this   a1.a2.onPress = function () { startDrag(this); }  and a1.a2.onRelease = function () { stopDrag(); }

but then what i need is a1 stay in main content, while moved a2.a3 to an external .swf, and use loadMovie to put .swf(a2.a3) back into a1, and I can still drag/drop a2.a3 when a1 stay still.

I tried differetn methods they all not working.  I've learned that you need to create another MC inside a1 like this a1.a4.a2.a3 ( while a2.a3 from loadMovie clip). it only work if I want to drag a1. but if I want to drag masked content a2.a3 it still doesn't.

I really need help it's a project for work.

TOPICS
ActionScript
774
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

correct answers 1 Correct answer

Community Expert , Apr 08, 2013 Apr 08, 2013

after loading is complete, apply your drag code to a1.a4, the load target that contains a2 and its children (after loading is complete).

Translate
Community Expert ,
Apr 08, 2013 Apr 08, 2013

after loading is complete, apply your drag code to a1.a4, the load target that contains a2 and its children (after loading is complete).

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 ,
Apr 08, 2013 Apr 08, 2013

if I apply drag to a1.a4 , it will still move the whole thing but not just masked content which is in a2.a3

I pretty much given up on this one at this point..   gonna just throw everything into just one big swf save the struggling time,

but thank  you for your input.

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
Community Expert ,
Apr 08, 2013 Apr 08, 2013
LATEST

you're welcome.

but my suggestion will work. 

however, if you made a2 a child of the main timeline instead of the main timeline, apply startDrag() to the load target dot a2.

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