# Issue: Nested sprites not visible

**URL:** https://forum.kirupa.com/t/issue-nested-sprites-not-visible/293535
**Category:** Uncategorized
**Created:** [July 30, 2009, 10:22am UTC](https://forum.kirupa.com/t/issue-nested-sprites-not-visible/293535 "2009-07-30T10:22:43Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![noobie123](https://avatars.discourse-cdn.com/v4/letter/n/ad7895/32.png) [@noobie123](https://forum.kirupa.com/u/noobie123)
#### Post date: [July 30, 2009, 10:22am UTC](https://forum.kirupa.com/t/issue-nested-sprites-not-visible/293535/1 "2009-07-30T10:22:43Z")

</div>

I have tried to create nested Sprite objects. But I see only the bigger square. What am I doing wrong?

var square:Sprite = new Sprite();  
square.graphics.beginFill(0xFFCC00);  
square.graphics.drawRect(0, 0, 100, 100);  
square.x = 100;  
square.y = 200;  
var square1:Sprite = new Sprite();  
square1.graphics.beginFill(0xFFCCFF);  
square1.graphics.drawRect(0, 0, 50, 50);  
square1.x = 100;  
square1.y = 200;

addChild(square);  
square.addChild(square1);
