Help! Pathfinding and Spawning Issues!!!

0 favourites
  • 3 posts
From the Asset Store
Game with complete Source-Code (Construct 3 / .c3p) + HTML5 Exported.
  • I am currently producing a tower defense game but I am having a problem with my enemies spawning. For some reason rather than waiting 1 second and checking if Enemies Remaining is not equal to zero it is spawning the enemies continuously. As well as this problem, I can't seem to stop my enemies from clipping the corners that are created by invisible wall that are opaque and on another layer.

    Also having another problem now the pathfinding and spawning is completely broken even defaulting to every 2 seconds

    [quote:206k4q9m]https://db.tt/rNlAJQ9v

  • can you provide a .capx so we can help you?

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • ok the problem is in the event :

    System EnemiesRemaining = 0,

    Go sprite Is Ready System

    set EnemiesRemaining to WaveNo * 3.

    I will explain what is wrong with this; In the event that "spawns" your enemies you are doing this:

    System Every 1.0 seconds

    System EnemiesRemaining =0

    System set EnemiesRemaining (EnemiesRemaining-1)

    so when this condition gets to 0 the event mentioned before sets the variable to WaveNo*3 so it will never becomes 0. You will have to find other way to update your EnemiesRemaining for each level. Hope it helps

    Edit: I didnt realize and you toggled some events off but not quite correctly, delete or toggle the DEBUG events correctly or you will keep the strange infinite create object behaviour you are having right now.

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