-
Enemy spawning help.
Okay, so I have several working enemies and several working spawners as well. The way I have now works just fine, Spawner A will only create Enemy A, Spawner B will only create Enemy B. Fine and dandy, but my issue is, I would have to create another event for each new enemy I add.
I am looking for a way to streamline this. I'm trying to figure out if there's a way I could spawn enemies through their alterable value, or something similar.
For example, a Spawner with Alt Value A=1 would ONLY spawn enemies with the same value. Not sure if I'm explaining this right, anyone have suggestions?
-
Re: Enemy spawning help.
Maybe spread value on your spawners and enemies, then run a fast loop.
Marv
-
Re: Enemy spawning help.
Can you give me an example? I can't seem to work it out in my head.
-
Re: Enemy spawning help.
In your "On loop" events, add the condition "Enemy alterable value (whichever you selected to spread the value in) = LoopIndex("nameOfLoop"). This will select one specific enemy object on each loop - run the loop NObjects("Enemy") times to run it once for each of them.
Marv
-
Re: Enemy spawning help.
I haven't tried it yet, but wouldn't that only work for one enemy object? If I were to use a completely different enemy object, I would need another similar event, wouldn't I?
That's pretty much what I have already, I'm trying to avoid that.
-
Re: Enemy spawning help.
No, this is based on cloned enemies and every loop it would pick a different enemy. There is a fast loop tutorial on the ---> sidebar, under tutorials.
Marv
-
Re: Enemy spawning help.
GameDragon, disregard what I said...I am full of doo-doo with the formula.
Sorry
Marv
-
Re: Enemy spawning help.
Haha, it's fine.
I noticed it's not possible to create objects by qualifier, which is the only thing making this confusing.