# patryk129/timberman--projekt-gry architecture

> Architecture diagram of the GitHub repository patryk129/timberman--projekt-gry, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-21). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/patryk129/timberman--projekt-gry
- Repository: https://github.com/patryk129/timberman--projekt-gry

## Overview

This repository is a console Timberman game, with a final version and several standalone prototype revisions. In the final version, keyboard events drive menu or gameplay actions; gameplay updates the tree-and-player board and score, while rendering writes the board and score to the console. The files are single-script implementations rather than separate runtime services. The sampled excerpts show only part of the final script, so the graph omits unverified calls and does not infer connections between the duplicated revisions.

Main entry points: [`Gra- wersja końcowa.py`](https://github.com/patryk129/timberman--projekt-gry/blob/main/Gra-%20wersja%20ko%C5%84cowa.py) (Board movement)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_runtime["Final game"]
  node_handler["Input handler"]
  node_board["Board movement"]
  node_render["Console rendering"]
  node_score["Score display"]
end

subgraph group_history["Prototype revisions"]
  node_rev1["Prototype 1"]
  node_rev2["Prototype 2"]
  node_rev3["Prototype 3"]
  node_rev4["Prototype 4"]
  node_rev5["Prototype 5"]
  node_rev6["Prototype 6"]
  node_rev7["Prototype 7"]
end

node_keyboard(("Keyboard input"))

node_keyboard -->|"dispatches events"| node_handler
node_handler -->|"moves player"| node_board
node_handler -->|"runs game turn"| node_render
node_board -->|"increments score"| node_score
node_board -->|"generates top"| node_board
node_render -->|"prints score"| node_score

click node_handler "https://github.com/patryk129/timberman--projekt-gry/blob/main/Gra-%20wersja%20ko%C5%84cowa.py"
click node_board "https://github.com/patryk129/timberman--projekt-gry/blob/main/Gra-%20wersja%20ko%C5%84cowa.py"
click node_render "https://github.com/patryk129/timberman--projekt-gry/blob/main/Gra-%20wersja%20ko%C5%84cowa.py"
click node_score "https://github.com/patryk129/timberman--projekt-gry/blob/main/Gra-%20wersja%20ko%C5%84cowa.py"
click node_rev1 "https://github.com/patryk129/timberman--projekt-gry/blob/main/wersja%20robocza-%201.py"
click node_rev2 "https://github.com/patryk129/timberman--projekt-gry/blob/main/wersja%20robocza-%202.py"
click node_rev3 "https://github.com/patryk129/timberman--projekt-gry/blob/main/wersja%20robocza-%203.py"
click node_rev4 "https://github.com/patryk129/timberman--projekt-gry/blob/main/wersja%20robocza-%204.py"
click node_rev5 "https://github.com/patryk129/timberman--projekt-gry/blob/main/wersja%20robocza-%205.py"
click node_rev6 "https://github.com/patryk129/timberman--projekt-gry/blob/main/wersja%20robocza-%206.py"
click node_rev7 "https://github.com/patryk129/timberman--projekt-gry/blob/main/wersja%20robocza-%207.py"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_handler,node_board,node_render,node_score toneBlue
class node_rev1,node_rev2,node_rev3,node_rev4,node_rev5,node_rev6,node_rev7 toneAmber
class node_keyboard toneIndigo
```

## Components

### Final game

- [Input handler](https://github.com/patryk129/timberman--projekt-gry/blob/main/Gra-%20wersja%20ko%C5%84cowa.py): `Gra- wersja końcowa.py`
- [Board movement](https://github.com/patryk129/timberman--projekt-gry/blob/main/Gra-%20wersja%20ko%C5%84cowa.py): `Gra- wersja końcowa.py`
- [Console rendering](https://github.com/patryk129/timberman--projekt-gry/blob/main/Gra-%20wersja%20ko%C5%84cowa.py): `Gra- wersja końcowa.py`
- [Score display](https://github.com/patryk129/timberman--projekt-gry/blob/main/Gra-%20wersja%20ko%C5%84cowa.py): `Gra- wersja końcowa.py`

### Prototype revisions

- [Prototype 1](https://github.com/patryk129/timberman--projekt-gry/blob/main/wersja%20robocza-%201.py): `wersja robocza- 1.py`
- [Prototype 2](https://github.com/patryk129/timberman--projekt-gry/blob/main/wersja%20robocza-%202.py): `wersja robocza- 2.py`
- [Prototype 3](https://github.com/patryk129/timberman--projekt-gry/blob/main/wersja%20robocza-%203.py): `wersja robocza- 3.py`
- [Prototype 4](https://github.com/patryk129/timberman--projekt-gry/blob/main/wersja%20robocza-%204.py): `wersja robocza- 4.py`
- [Prototype 5](https://github.com/patryk129/timberman--projekt-gry/blob/main/wersja%20robocza-%205.py): `wersja robocza- 5.py`
- [Prototype 6](https://github.com/patryk129/timberman--projekt-gry/blob/main/wersja%20robocza-%206.py): `wersja robocza- 6.py`
- [Prototype 7](https://github.com/patryk129/timberman--projekt-gry/blob/main/wersja%20robocza-%207.py): `wersja robocza- 7.py`

### Other components

- **Keyboard input**

## Connections

- Keyboard input → Input handler: dispatches events (evidence: `Gra- wersja końcowa.py`)
- Input handler → Board movement: moves player (evidence: `Gra- wersja końcowa.py`)
- Input handler → Console rendering: runs game turn (evidence: `Gra- wersja końcowa.py`)
- Board movement → Score display: increments score (evidence: `Gra- wersja końcowa.py`)
- Board movement → Board movement: generates top (evidence: `Gra- wersja końcowa.py`)
- Console rendering → Score display: prints score (evidence: `Gra- wersja końcowa.py`)
