# AS3 in timeline vs package

**URL:** <https://forum.kirupa.com/t/as3-in-timeline-vs-package/305979>\
**Category:** flash\
**Created:** [March 7, 2010, 2:14am UTC](https://forum.kirupa.com/t/as3-in-timeline-vs-package/305979 "2010-03-07T02:14:24Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![whiteart](https://avatars.discourse-cdn.com/v4/letter/w/c67d28/32.png) [@whiteart](https://forum.kirupa.com/u/whiteart)\
**Post date:** [March 7, 2010, 2:14am UTC](https://forum.kirupa.com/t/as3-in-timeline-vs-package/305979/1 "2010-03-07T02:14:24Z")

</div>

I’m starting out in AS3 and need some basic advice. I noticed when you create an external package/class for a movieclip, all scripts nested in that movieclip timeline are ignored. Only issue is, I have some animations that I only want to play once, achieved by placing a simple stop(); in the timeline. I know you can place a stop() from the external class, but if I have several nested animations, then this could get messy & confusing.

I have been placing my AS3 code in the first frame of the timeline of the movieclip. But it is coming apparent to me the best practice is creating external classes.

I guess the question is this: Is placing code in the timeline a bad practice coming from AS2, and if so, is it standard to set a bunch of stop()'s for movieclips placed on the stage, or am I missing something simple?
