ndleah / python-mini-project

🙌 Welcome open-source Python mini-project contributions!
MIT License
3.17k stars 1.25k forks source link

Add retry feature to Caterpillar game (Issue #277) #308

Open 1zj23 opened 2 weeks ago

1zj23 commented 2 weeks ago

Description

A short summary of what is included in your Pull Request. This pull request introduces a new "Retry" feature to the Caterpillar game, addressing issue #277. With this feature, players can press the "R" key to restart the game immediately after the "GAME OVER" screen, providing a more fluid and enjoyable gaming experience.

The following changes were made:

Added a keybinding for the "R" key that restarts the game after it's over. Improved the game loop to accommodate the retry feature without restarting the entire script. Updated comments to explain the new functionality and ensure maintainability. Fixes #(issue_no)

Type of change

Choosing one or more options from the following as per the nature of your Pull request.

Project

Checklist:

Please tick all the boxes that are fulfilled by your Pull Request.