Adding basic game logic and collision detection
Welcome to part 4 of my tutorial series. In the previous parts we've created a sprite, added movement, created enemies which follow our sprite, added bullets and a HUD. But, for a real game some essential parts are missing:
- Collision detection between the bullets and our sprite
- Basic game logic
- Scoring
- Pause
- Life Lost & Game Over
I'll show how to implement this today. As a starting point you can download the code from tutorial part 3 here.