Skip navigation
Currently Being Moderated

Adding Child to AS3 Flash Sprite in Director 11.5

Jun 28, 2012 8:46 PM

Tags: #flash #swf #11 #director #addchild

To add a new movie clip to a Flash sprite using ActionScript 2 I do something like this

 

new_clip = flash_sprite.createEmptyMovieClip( "my clip", flash_sprite.getNextHighestDepth() )

 

 

Can someone tell the the ActionScript 3 equivalent? I tried this

 

new_clip = flash_sprite.newObject( "flash.display.MovieClip" )

flash_sprite.addChild( new_clip )

 

 

but I get an error saying #addChild handler not found in object.

 
Replies

More Like This

  • Retrieving data ...

Bookmarked By (0)

Answers + Points = Status

  • 10 points awarded for Correct Answers
  • 5 points awarded for Helpful Answers
  • 10,000+ points
  • 1,001-10,000 points
  • 501-1,000 points
  • 5-500 points