How do I properly trigger an event once per enemy

0 favourites
  • 2 posts
From the Asset Store
Game Triggers is as versatile as a Swiss army knife, and will be a great resource for any type of game you're creating.
  • Okay, so I've been using Construct for years now and I feel so stupid for not knowing this.. I'm sure I've sorted it in the past but I'm struggling with it right now.

    I have many enemies and I want a little icon to pop up over their heads when they're alerted (think Metal Gear).

    I want this to happen once per enemy but when it happens. I want them to start other actions too on a state change but I just want to start with this one simple action to see it's working.

    So when one enemy changes state an icon pops up.. except it works for the first enemy, then all others it continues to spawn - I've tried every combination of actions I could think of so I would love some advice on how to do this properly!

    I suppose this is what I'm aiming for:

    enemy variable state = "idle"

    For each enemy

    Trigger once

    {

    Spawn icon

    }

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Solved.. I've been working so much this week I hadn't realised there was a better way.

    Called a state change function when needed now instead.

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