Hello! Im working on a game project and having issue when looping to add more enemys.
What I want to do is like, if times run out and player get to failed frame, I want the child to get removed. but I find it hard to acces the var in the loop. I know it is some easy way..
but wil be prefect if someon have any help.
public function enemysLvl1(){
for(var i=0; i<10; i++){
var frukt1:Frukt = new Frukt;
addChild(frukt1);
}
Thank's!
I will say ty to Ned Murhpy for giving me answers too! but I couldn't get it to work the way I was looking for.
But I have to say thank you very much dmennenoh, that was the solution I have been looking for but couldn't find hehe. But now it worked out just as I wanted, so Thank's!!!
I can understand why you have to use containers alot, it is very usefull!![]()
North America
Europe, Middle East and Africa
Asia Pacific