Im new to actionscript 3 and am a little confused about how the addchild function works.
I want to draw 5 houses. each house has a roof and wall. Each wall has a door and a window. I have the following classes and this is how I grouped them
class Main
class House
class Roof //a triangle
class Wall //a rectangle
class Door //a rectangle
class Window //a square
Im having trouble with inheritance of the classes. I cant made the wall class show up with a window and a door. Can someone point me to the right direction?
UPDATE: This is the part I do not understand. How can I write it so that it draws the door and window relative to the wall? (use the top left corner of wall as 0,0; instead of the screen)