nanopython  /  invaders-lite

Invaders-lite

Aliens march left-right and descend; you shoot them down before they land. Pro-style: Player, Alien, Bullet classes and a Game that owns them. Classes carry their state explicitly; @on_key decorators bind input; a Ticker drives the 30 fps loop.

Companion to breakout-lite (kid-style: module globals + a few functions). Invaders has multiple entity kinds, so the class shape pays off here.

Loading…

Score0
Wave1
High0

A/D or arrow keys to move. Space to fire. S stops the ship. R restarts.