I'm new to flash, and i'm trying to make my first game in AS3.
In the game i create several objects on screen, when the user presses a key (circles and squares), and the user has to click on them to delete them from screen.
I already know how to create the objects on screen

var xpto=new myClass;

Now, how can i delete this object when the user clicks on it?
Ok, my guess is using arrays. I've search google and some books but it just seems i can't find the way. Don't i must have an eventListenner for every object in order to detect if the user clicked on it? if that is true, once i don't know the objects name at debugtime how can i add the events to them?

Does anyone has some code example or could give me some help?

My thanks in advanced
Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!