# OOP adding sprites

**URL:** https://forum.kirupa.com/t/oop-adding-sprites/269935
**Category:** flash
**Created:** [September 3, 2008, 10:50am UTC](https://forum.kirupa.com/t/oop-adding-sprites/269935 "2008-09-03T10:50:49Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![Spanjj](https://avatars.discourse-cdn.com/v4/letter/s/f04885/32.png) [@Spanjj](https://forum.kirupa.com/u/Spanjj)
#### Post date: [September 3, 2008, 10:50am UTC](https://forum.kirupa.com/t/oop-adding-sprites/269935/1 "2008-09-03T10:50:49Z")

</div>

Its probably very straight forward but I can’t seem to work it out, so maybe you guys can help! I’m making a game and in the game there is a menu screen which contains several sprites that represent the visual look of the menu.

So in MenuScrnStart.as I have proceeded to add a logo for my game like so…

private var \_logo:Sprites = new Sprites;

addChildAt(\_logo, 0);

‘Sprites’ is the class linked to my logo. This works perfectly, however, I’ve just gone to add another sprite and realized, if I link another sprite in my library to the Sprites class, how will flash know which sprite to put on the stage? Surely I don’t have to make a different class for each individual sprite I want to add on? Can anyone assist? 🙂
