How to prevent gaining extra points after enemy has been defeated

2 favourites
  • 11 posts
From the Asset Store
Connect the dots in the correct order and draw happy animals!
  • Hi,

    I'm making a simple shooting game and have set things so that one point is added to the score every time a bullet makes contact with an enemy. I've found if I continue to shoot at the enemy while it's playing its "vanishing" animation (even though this lasts for less than a second), points are still added to the score. Is there a way to stop this from happening? Link to the (incomplete) game is below:

    drive.google.com/file/d/1IBHbS2RfYkxOwHhVKtCRosKlgvEoNzs6/view

  • Add a condition to on collision event : critter opacity=100. When fading its opacity is less than 100.

  • Hi plinkie, I've added the opacity condition but I'm still able to gain points from repeatedly shooting an enemy before it disappears.

  • Let's see a screenshot of the events you added

  • Here it is. I tried disabling the Fade effect as well but the issue's still there.

  • So I mean add a condition, which appear on the left (press C), to the on collision event. The condition should be critter opacity=100. This means when the bullet collides that the critter object opacity must be 100 for it to do the actions i.e. it is not fading. So you can only hit it one time with that condition.

  • Here it is. I tried disabling the Fade effect as well but the issue's still there.

    Hello.

    Try to add another condition to "on collision with critter" "critter its not play c animation".

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • So I mean add a condition, which appear on the left (press C), to the on collision event. The condition should be critter opacity=100. This means when the bullet collides that the critter object opacity must be 100 for it to do the actions i.e. it is not fading. So you can only hit it one time with that condition.

    Sorry for misunderstanding, I'm still new to this and often get the terms mixed up. I've tried adding another condition but can't find the "set opacity" option. The closest I can find is "compare opacity".

  • > So I mean add a condition, which appear on the left (press C), to the on collision event. The condition should be critter opacity=100. This means when the bullet collides that the critter object opacity must be 100 for it to do the actions i.e. it is not fading. So you can only hit it one time with that condition.

    Sorry for misunderstanding, I'm still new to this and often get the terms mixed up. I've tried adding another condition but can't find the "set opacity" option. The closest I can find is "compare opacity".

    Yup, that's the one!

  • You can also disable collisions for the Critter once it's "destroyed" so bullets stop colliding with it :)

  • This worked, thank you so much! :)

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