| Ultrashock Forums
• [AS3] use mc on stage via class file |
|||
![]() |
||||
| Search this Thread | Thread Tools | Display Modes |
|
|
|||||||||||||||||||||||||
![]() |
Ultrashock Member Comments:
|
|
2007-10-31
#2 |
||
|
No one can help me?
|
|
|
2007-10-31
#3 |
||
|
You can't access a movie clip directly on stage, but you can import it from the library at run time by attaching it to an empty movie clip created in your class.
|
|
|
|
2007-10-31
#4 |
||
|
Okay, what if I want to use a motion tween in the timeline on the movieclip I attach to an empty movie clip?
|
|
|
2007-10-31
#5 |
||
|
you would need to pass the reference of your MovieClip when you instantiate your class.
|
|
|
|
2007-10-31
#6 |
||
|
do you have a link or something to a example, it would be great
|
|
|
2007-10-31
#7 |
||
|
it all really depends on where you're instantiating your class, unless that's the document class?
|
|
|
|
2007-10-31
#8 |
||
|
I instantiate my class by using this code: ActionScript Code:
|
|
|
2007-10-31
#9 |
||
|
yes, but if your movieclip isn't instantiated via code, i *believe* you'll have to use getChildByName and not explicitly declare the instance in your class... there was a thread on here awhile back that touched on this very topic. i believe senocular can answer this.
|
|
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|


8 comments
| 316 views


Linear Mode