Go to file
thw 80fdb0aa3b readme update 2026-11-14 06:51:41 +01:00
controller feat(blackjack): implement 3-step Devil's Gambit auto-showdown, Deity AI & UI overhaul 2026-11-14 06:46:46 +01:00
games readme update 2026-11-14 06:51:41 +01:00
models first commit 2026-11-14 05:25:51 +01:00
resources first commit 2026-11-14 05:25:51 +01:00
view feat(blackjack): implement 3-step Devil's Gambit auto-showdown, Deity AI & UI overhaul 2026-11-14 06:46:46 +01:00
README.md first commit 2026-11-14 05:25:51 +01:00
main.py first commit 2026-11-14 05:25:51 +01:00
user_data.db feat(blackjack): implement 3-step Devil's Gambit auto-showdown, Deity AI & UI overhaul 2026-11-14 06:46:46 +01:00

README.md

† The Goth Cardgame Collection †

Deutsch | English


🇩🇪 Deutsch

Überblick

The Goth Cardgame Collection ist eine erweiterbare Desktop-Kartenspielsammlung in Python (tkinter + Pillow + SQLite) im düsteren Gothic-Tarot-Stil. Das Projekt trennt strikt zwischen reinen Account-Profilen („Seelen“), spielgebundenem Fortschritt und einer zweigeteilten Datenbank-Architektur für unveränderliche Stammdaten und dynamische Spielstände.

Kern-Features des Hauptprogramms

  • Seelen-Profile & Spielgebundene Progression:
    • Ein Profil speichert lediglich die Identität des Spielers („Seele“).
    • Kein Cross-Game-Grinding: Jedes Spiel besitzt ein komplett eigenes Level, eigene Erfahrungspunkte (XP) und eigene Konsequenzen. Wer in Solitaire aufsteigt, kann diese XP nicht für Casino-Gold in Blackjack oder Poker zweckentfremden.
    • 1.295+ Prestige-Stufen: 259 Ränge mit je 5 römischen Unterstufen (Erst-Starter I bis Schöpfergeist V), gefolgt vom offenen Endlos-Rang Gottheit 1, 2, 3... (ab Level 1.296).
  • Flache 4-Kategorien-Architektur (ohne Untermenüs):
    • Glück (luck): Casino- und Wettspiele (Blackjack, Texas Hold'em) mit harten Konsequenzen, Goldbeuteln, Divine Punishment und The Devil's Deal.
    • Solo (solo): Reine Logik- und Geduldsspiele (Klondike, FreeCell, Spider Solitaire) ohne Gold-Zwang und mit eigenen Rückstufungsregeln.
    • Gesellschaft - Offline (party_offline): Klassische Runden am lokalen Tisch gegen KI-Charaktere.
    • Online (online): Kein Welpenschutz – Partien gegen echte Gegner sowie entfesselte KI-Spieler auf Gottheit-Niveau (Stufe 6).
  • Dynamischer Game-Loader (Plugin-Prinzip):
    • Neue Spiele werden einfach als Ordner mit einer start.py unter games/ abgelegt und in GAME_FOLDERS registriert (start_game(context), GAME_TITLE_KEY, GAME_CATEGORY).
  • Duale SQLite-Datenbank-Architektur:
    • resources/code_res/internal_base.db (Read-Only Stammdaten): Enthält alle Übersetzungen (base_i18n), alle 260 Prestige-Ränge (base_prestige_ranks) und Spielvarianten (game_variants). Wird per ATTACH DATABASE ... AS core eingebunden.
    • user_data.db (Dynamische Nutzerdaten): Speichert Profile, spielgebundene XP & Level-Historien, Goldbeutel, Bot-Setups, Fenstergeometrie, Audio-Settings, Statistiken und Pakt-Savegames.
  • Dynamisches UI-System & Visuelles State-Feedback:
    • Eigene rahmenlose Alpha-PNG-Buttons (ImageButton) mit automatischem PIL-Graustufen- und Abdunklungsfilter (enabled=False) für inaktive Aktionen, gesperrte Tische oder fehlende Voraussetzungen.
    • Vektorbasierte Gothic-Tarot-Spielkarten im Auswahlmenü sowie eine erweiterbare Topbar (AppContext.build_game_topbar) mit optionaler Direkteinbindung spielspezifischer Statistik-Ansichten und Live-Währungsanzeigen.
  • Live-Zweisprachigkeit (DE / EN):
    • Umschaltung zu jeder Zeit (im Hauptmenü, in Statistiken oder mitten im laufenden Spielzug) ohne Neustart.
  • Audio- & Atmosphären-Manager:
    • Getrennte Lautstärkeregler für Hintergrundmusik (Beyond the Iron Gate im Menü, The Midnight Hand am Spieltisch) und Soundeffekte, persistent in der DB gespeichert.
  • Detailliertes Statistik-Board:
    • Spiel- und variantenspezifische Auswertung für gespielte/gewonnene/verlorene Runden, Siegquote in %, aktuelle & längste Siegesserie sowie beste und durchschnittliche Spielzeit.

Verzeichnisstruktur

the_goth_cardgame_collection/
├── main.py                         # Einstiegspunkt
├── README.md                       # Hauptdokumentation (DE/EN)
├── user_data.db                    # Dynamische Spieler- & Savegame-DB (wird automatisch erzeugt)
├── controller/
│   ├── app_controller.py           # Hauptsteuerung, Login, Kategorien & Devil's-Lock-Prüfung
│   ├── app_context.py              # Schnittstelle & Topbar-Builder zwischen Hauptprogramm und Spiel
│   └── game_loader.py              # Dynamischer Loader für Spiele unter games/
├── models/
│   ├── card.py                     # Karten-Modell
│   ├── deck.py                     # Deck-Verwaltung & Mischen
│   ├── database.py                 # Kapselung aller SQLite-Zugriffe & Transaktionen
│   ├── progression.py              # Level-, XP- & Prestige-Berechnung (spielgebunden)
│   └── sound_manager.py            # Musik- & SFX-Steuerung
├── resources/
│   ├── code_res/
│   │   ├── game_constants.py       # Zentrale Konstanten, Kategorien, Farben & Balancing-Werte
│   │   ├── i18n.py                 # Übersetzungs-Cache & Formatierung
│   │   ├── sql_queries.py          # Alle SQL-Statements zentral ausgelagert
│   │   ├── internal_base.sql       # Vollständiger SQL-Dump der Stammdaten
│   │   └── internal_base.db        # Kompilierte SQLite-Stammdatenbank
│   ├── images/                     # UI-Grafiken & Kartendecks
│   └── sounds/                     # Musik & Soundeffekte
├── view/
│   ├── main_window.py              # Hauptfenster, Geometrie-Speicherung & globale Styles
│   ├── assets_manager.py           # Bild- & GIF-Caching
│   ├── dialogs/                    # Modale Dialoge (z.B. Audio-Einstellungen)
│   ├── menus/                      # LoginView, MainMenuView, StatisticsView
│   └── widgets/                    # Wiederverwendbare UI-Bausteine (ImageButton inkl. Graufilter, StatsBoard, BotSetup)
└── games/
    └── blackjack/                  # Blackjack – Devil's Gambit Modul (inkl. eigener README & StatsView)

Installation & Start

  1. Abhängigkeiten installieren:
    pip install pillow pygame
    
  2. Stammdatenbank (internal_base.db) aus SQL-Dump erzeugen/aktualisieren:
    sqlite3 resources/code_res/internal_base.db ".read resources/code_res/internal_base.sql"
    
  3. Spiel starten:
    python main.py
    

Spiele-Dokumentationen


🇬🇧 English

Overview

The Goth Cardgame Collection is an extensible desktop card game suite built with Python (tkinter + Pillow + SQLite), styled in a dark Gothic Tarot aesthetic. The architecture strictly separates player identity ("Souls"), game-bound progression, and a dual-database setup for immutable core data versus dynamic player states.

Core Engine Features

  • Soul Profiles & Game-Bound Progression:
    • A profile strictly represents the player's identity ("Soul").
    • Zero Cross-Game Grinding: Every game tracks its own independent XP, level, and consequences. Progress earned in Solitaire cannot be converted into casino gold for Blackjack or Poker.
    • 1,295+ Prestige Levels: 259 rank titles divided into 5 Roman sub-tiers (First-Starter I up to Creator Spirit V), followed by open-ended Deity 1, 2, 3... ranks starting at Level 1,296.
  • Flat 4-Category Structure (No Submenus):
    • Luck (luck): High-stakes gambling games (Blackjack, Texas Hold'em) featuring gold pouches, Divine Punishment, and The Devil's Deal.
    • Solo (solo): Pure skill and patience games (Klondike, FreeCell, Spider Solitaire) with dedicated progression and demotion mechanics, free of gold entry fees.
    • Party - Offline (party_offline): Classic parlor card games played locally against AI personalities.
    • Online (online): No hand-holding – matches against human players and unleashed Deity-tier bots (Level 6).
  • Dynamic Game Loader:
    • Games live in modular folders under games/ exposing a start.py (start_game(context), GAME_TITLE_KEY, GAME_CATEGORY).
  • Dual SQLite Database Architecture:
    • resources/code_res/internal_base.db (Read-Only Core Data): Stores all translations (base_i18n), all 260 prestige titles (base_prestige_ranks), and game variants (game_variants), attached at runtime as core.
    • user_data.db (Dynamic User Data): Stores profiles, per-game XP & level history, gold pouches, bot setups, window geometry, audio preferences, statistics, and lock-state savegames.
  • Adaptive UI & Visual State Feedback:
    • Custom borderless alpha-PNG buttons (ImageButton) with automatic PIL grayscale/dimming filters (enabled=False) to clearly signal inactive actions, locked tables, or missing prerequisites.
    • Vector-styled Gothic Tarot game cards in the main menu and an extensible topbar (AppContext.build_game_topbar) supporting dedicated per-game statistics views and live balance badges.
  • Instant Localization (DE / EN):
    • Toggle between German and English on the fly—even mid-hand—without restarting.
  • Audio & Ambiance System:
    • Separate volume controls for background music and menu/table sound effects, saved persistently.
  • Comprehensive Statistics Board:
    • Filterable per game and variant: games played/won/lost, win percentage, current & longest streak, best time, and average duration.

Directory Structure

the_goth_cardgame_collection/
├── main.py                         # Entry point
├── README.md                       # Main documentation (DE/EN)
├── user_data.db                    # Dynamic player & savegame DB (auto-created)
├── controller/
│   ├── app_controller.py           # Core routing, login, categories & Devil's Lock check
│   ├── app_context.py              # Bridge & topbar builder between host app and active game
│   └── game_loader.py              # Dynamic discovery for modules inside games/
├── models/
│   ├── card.py                     # Playing card model
│   ├── deck.py                     # Shoe & shuffling logic
│   ├── database.py                 # SQLite abstraction & transaction handling
│   ├── progression.py              # Game-bound XP, level & prestige calculation
│   └── sound_manager.py            # Music & SFX controller
├── resources/
│   ├── code_res/
│   │   ├── game_constants.py       # Central constants, categories, colors & balancing values
│   │   ├── i18n.py                 # Localization cache & string formatting
│   │   ├── sql_queries.py          # Centralized SQL statements
│   │   ├── internal_base.sql       # Complete SQL seed dump for static data
│   │   └── internal_base.db        # Compiled read-only SQLite core database
│   ├── images/                     # UI assets & card decks
│   └── sounds/                     # Music tracks & sound effects
├── view/
│   ├── main_window.py              # Root window, geometry persistence & global ttk styles
│   ├── assets_manager.py           # Image & animated GIF cache
│   ├── dialogs/                    # Modal dialogs (e.g., Audio settings)
│   ├── menus/                      # LoginView, MainMenuView, StatisticsView
│   └── widgets/                    # Reusable UI widgets (ImageButton w/ gray filter, StatsBoard, BotSetup)
└── games/
    └── blackjack/                  # Blackjack – Devil's Gambit module (incl. README & StatsView)

Setup & Launch

  1. Install dependencies:
    pip install pillow pygame
    
  2. Build or update internal_base.db from the SQL seed:
    sqlite3 resources/code_res/internal_base.db ".read resources/code_res/internal_base.sql"
    
  3. Run the application:
    python main.py
    

Game Manuals