[Solved] How do I make infinite wave spawns

0 favourites
  • 4 posts
From the Asset Store
Two levels with two sistem Wave. with Source-code (.c3p) + HTML5 Exported.
  • I want to make infinite number of waves that double the amount of spawned enemies after previous are defeated untill its 100 of them (then they keep that number). Also enemies cant bug each other when spawning by stacking on each other so they need to have time pauses between each spawn.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Do like:

    global var maxEnemies = 6 (or w.e)

    GROUP: Enemy Spawner

    Every 10.0 seconds: (or w.e time)

    • - For loopindex 0 to maxEnemies :: Spawn enemy
    • - - - Compare variables: loopindex = maxEnemies :: maxEnemies = maxEnemies * 2

    Compare variables: maxEnemies >= 100 :: Disable group "Enemy Spawner"

    Else :: Enable group "Enemy Spawner"

    As far as spawning on one another, you can put a Wait 0.5 sec in the loop, or space out the spawns spatially.

  • I have no idea how to use your solution, but...

    This is what I did:

    global variables

    Spawn - is spawning allowed? this waits untill there are no enemies left.

    enemycount - checks how many enemies have been counted

    cenemycurrent - checks how many enemies are alive

    checknumber - checks if checking of enemy current is in progress, if it is it stops it from looping.

    It works perfectly so far, enemies do not stack on each other.

  • Thanks for posting your solution, in case someone else has the same issue.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)