addChildren giving undefined- finished skeleton, drafted other parts and commented out some unnecesary stuff