Problems with actor

Shishkov

  • Posts: 169
Hello everybody,

I have only one scene which I would like to use in my game. At the beginning of the game through scene redactor I added some actors(enemies) and after their death(when they are killed) I made that player continue to stay at the place where he was and at the same time but in the other part of the scene another enemy appears(BOSS). But it appers in unlimited numbers. I tried to use flags, different events, to my dismay, it was useless because of the same thing.
I used this algorithm:
1) when the scene appered there had already been created some enemies
2) count number of dead enemies
3) if they are all dead, create BOSS
I want to have only one BOSS, not billions...)))

Please, help me to solve this problem?!
Thanks

Tuo

  • *
  • Posts: 2469
I'm guessing you are using a conditional in "always". If that is the case, use a boolean that has a default value that is checked when the number of enemies is 0, and if the boolean is default, set the boolean to off and create the boss. Here's a pic of the idea.
Don't look to me but rather to the One who is the reason for what I do. :)

If you need help, send me a PM. Even if I haven't been on in the forums in ages, I still receive those messages via email notifications. You can also reply to any of my forum posts, regardless of the age (especially if I created it), and I will likely reply.

If you want to see the programming behind certain types of games, feel free to check out my "Demo-" games on StencylForge (http://community.stencyl.com/index.php/topic,16160.0.html)