Tirsvad b5d1c13293
TirSystem/git-workflows: Release / release (push) Skipped
TirSystem/git-workflows: Publish accepted milestones / publish (push) Skipped
TirSystem/git-workflows: Sync GitHub mirror metadata / sync-metadata (push) Successful in 14s
TirSystem/git-workflows: Publish wiki / publish-wiki (push) Successful in 26s
TirSystem/git-workflows: Validate / validate (push) Successful in 35s
TirSystem/git-workflows: OpenGrep / opengrep (push) Successful in 1m27s
Merge pull request 'Add English wiki, registry languages and README' (#1) from docs/add-wiki into main
Reviewed-on: #1
2026-11-15 05:29:15 +01:00
2026-11-15 12:24:36 +08:00
2026-11-15 12:18:40 +08:00

🚀 Treasure Island

A beginner-friendly Python "Choose Your Own Adventure" text game where your choices decide whether you find the treasure.

📚 Table of Contents

🧭 Overview

You start at a crossroad and pick your way through the story using if / elif / else logic. Answers are lowercased and trimmed, so Left and LEFT work too, and invalid answers are asked again.

crossroad: left or right
  right -> Game Over (hole)
  left  -> lake: wait or swim
            swim -> Game Over (trout)
            wait -> island: red, yellow or blue door
                      red    -> Game Over (fire)
                      blue   -> Game Over (beasts)
                      yellow -> You Win!

Only one path wins. Feel free to rewrite the story in src/treasure_island/game.py. It is part of Udemy's 100 Days of Code: The Complete Python Pro Bootcamp and has no runtime dependencies.

The repository holds the game in src/treasure_island/, its tests in tests/, the project documents and the wiki pages in docs/, and the SQA and QC framework in framework/.

📋 Requirements

  • Python 3.13 or newer
  • pytest (only for running the tests)

🛠️ Setup

Create and activate a local virtual environment in the project root:

python -m venv .venv

Activate it:

  • Windows (PowerShell): .venv\Scripts\Activate.ps1
  • Windows (cmd): .venv\Scripts\activate.bat
  • Git Bash on Windows: source .venv/Scripts/activate
  • macOS / Linux: source .venv/bin/activate

Install the project with the test tools:

pip install -e ".[dev]"

Leave the environment with deactivate.

Optional: copy .env.example to .env and fill in the tokens you need. They are only used for repository maintenance, never to run the game. .env is git-ignored.

▶️ Run

python -m treasure_island

or, after installing:

treasure-island

🧪 Tests

pytest

📄 License

Released under the GNU Affero General Public License v3.0 (AGPL-3.0-or-later).

📎 Appendix: Project documents

The documents a newcomer needs, in reading order.

Document What it tells you
AGENTS.md The rules AI agents follow in this repository
Wiki How to play, install and develop the game
Artifact registry Where each artifact type lives, the next version, the PO language and domain
Framework README The framework this project uses
Framework changelog What changed in each framework release

S
Description
Treasure Island: a beginner-friendly Python choose-your-own-adventure text game (Udemy 100 Days of Code, day 3).
Readme AGPL-3.0
54 KiB
0 Stars 1 Watchers 0 Forks
Languages
Python 100%