controlling children of sprites
In the code:
import flash.display.Sprite;
var spriteOne:Sprite = new Sprite()
spriteOne.graphics.beginFill(0x999999)
spriteOne.graphics.drawCircle(0,0,100)
var spriteTwo:Sprite = new Sprite()
spriteTwo.addChild(spriteOne)
addChild(spriteOne)
spriteOne.spriteTwo.alpha = .5
I get the error:
Scene 1, Layer 'Layer 1', Frame 1, Line 11 1119: Access of possibly undefined property spriteTwo through a reference with static type flash.display:Sprite.
I can control child movieclips on the stage this way, so why can't I control sprites made in AS3 this way?