How viett123/stungeon works
Stungeon is a pygame educational dungeon-crawler: the player creates or resumes a hero, explores floors, answers German questions to resolve combat, and progresses through rewards and choices toward the final floor. The graph separates run flow, dungeon exploration, question-driven combat, progression/economy, and presentation. Edges are limited to relationships visible in excerpts, SOURCE INDEX references, or the README; several unsampled subsystems are shown without speculative internal wiring.
Main entry points: flow.py Run Flow · dungeon_scene.py Dungeon Scene · combat_scene.py Fight Screen · shop_screen.py Shop Screen
Components 24
Game Flow
- Game Runtime
core/game.py - Scene Manager
core/scene.py - Run Flow
core/flow.py
Dungeon Exploration
- Dungeon Scene
dungeon/dungeon_scene.py - Floor Generation
dungeon/floor.py - Dungeon Rendering
dungeon/renderer.py - Actors and Sprites
dungeon/actor.py
Combat and Learning
- Fight Screen
combat/combat_scene.py - Battle Rules
combat/battle.py - German Questions
questions/engine.py
Run Progression
- Player
systems/player.py - Run State
core/run.py - Save System
systems/save.py - Items and Inventory
systems/inventory.py - Loot Rewards
systems/loot.py - Between-Floor Shop
systems/shop.py - Risk-Reward Choice
systems/choices.py
Screens and Rendering
- Hero Setup
ui/new_game.py - Class Selection
ui/class_select.py - HUD
ui/hud.py - Inventory Screen
ui/inventory_screen.py - Shop Screen
ui/shop_screen.py - Other Screens
ui/screens.py
Other components
- Player
Connections 28
- Player → Hero Setup: starts run
README.md - Hero Setup → Run Flow: submits choices
ui/new_game.py - Run Flow → Scene Manager: routes scenes
core/flow.py - Game Runtime → Scene Manager: drives scenes
- Run Flow → Run State: creates run
core/flow.py - Run Flow → Save System: loads and saves
core/flow.py - Run Flow → Dungeon Scene: enters floor
core/flow.py - Run Flow → Shop Screen: opens shop
core/flow.py - Run Flow → Other Screens: shows end screen
core/flow.py - Class Selection → Run Flow: submits class
ui/class_select.py - Run State → Player: holds player
core/run.py - Dungeon Scene → Floor Generation: generates floor
dungeon/dungeon_scene.py - Dungeon Scene → Dungeon Rendering: renders floor
dungeon/dungeon_scene.py - Dungeon Scene → Actors and Sprites: uses actors
dungeon/dungeon_scene.py - Dungeon Scene → Fight Screen: starts fight
dungeon/dungeon_scene.py - Dungeon Scene → Items and Inventory: adds loot
dungeon/dungeon_scene.py - Dungeon Scene → Loot Rewards: awards loot
dungeon/dungeon_scene.py - Fight Screen → Battle Rules: resolves moves
combat/combat_scene.py - Fight Screen → German Questions: asks questions
combat/combat_scene.py - Battle Rules → Player: uses combat stats
combat/battle.py - Fight Screen → Items and Inventory: uses consumables
combat/combat_scene.py - Inventory Screen → Items and Inventory: reads inventory
ui/inventory_screen.py - Shop Screen → Between-Floor Shop: uses shop system
core/flow.py - HUD → Player: shows status
- Player → Dungeon Scene: explores floors
README.md - Player → Fight Screen: chooses moves
README.md - Player → Inventory Screen: opens bag
README.md - Player → Shop Screen: shops between floors
README.md