Bomb Object added to level

I made a challenge myself that was to add a new object (Bomb) to the game. When the ball hit the bomb it destroys each block that is next to it.

I created an Array that gets all the objects on a rectangle area using the function Physics2D.OverlapAreaAll. Then when the balls collide with bomb it checks that array and destroy each object that is a Block or Bomb.

1 Like

Privacy & Terms