How do I delete specific spawns

0 favourites
  • 4 posts
  • Hello guys, I am a new user of Construct, Still learning, Still watching a lot of videos.

    I have started creating a game already as practice and I got stuck in one part that I have no idea how to solve.

    My character spawn objects, like loads. I need to destroy specific spawns. Like, imagine that my character spawn one object every second, after 20 seconds there will have 20 objects spawned. I would like to destroy the spawn number 3 and 4, them number 7 and 8, them number 15 and 16. Is it possible? If so, what would I have to do?

    Thank you very much

  • You could use UIDs. Or give your spawner a variable called 'Spawn_ID.' Then give your object to be spawned a variable called 'ID.'

    When the spawner spawns the object:

    Object > set ID to spawner.Spawn_ID

    Spawner > add one to Spawn_ID

    Basically what this does, is each time an object is spawned, it sets it's ID to the spawner's id and adds one to the spawners Spawn_ID. So each one spawned should have one higher ID than the last one spawned.

    -Give me a Pixel

  • Thank you very much. Will try that as soon as I learn it

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • No problem. :)

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