Hello, im currently looking at the top down shooter template in c2
When two instances of enemies are closeby and when I shoot, It seems that the bullets harm both the nearby enemies before destroying itself.
How to make the bullet only harm the enemy it hits first?
Develop games in your browser. Powerful, performant & highly capable.
When this condition is true:
Bullet -> On ovelapping with Enemy
There might be two enemies overlapping with it, and you hurt both of the in the actions.
You should pick one of those enemies, for example, add the following condition to the overlapping one:
Pick Top Enemy (It is in the Z order)
and now only the one will hirt which is on the top.
There are other picking tools also -> Pick nearest, Pick nth