Hitting Enemies with Projectiles
摘要
Once you have a player you can control and a way to fire projectiles, the next step involves hitting enemies with a projectile. This involves creating an enemy, detecting when a collision occurs between a projectile and an enemy, and then removing both the projectile and the enemy afterward. By removing the enemy, the enemy is eliminated in the game.