How suchy499/privategamehelper-for-super-animal-royale works
Project type and purpose
• Type: Desktop GUI application written in Python (uses PyQt or similar).
• Purpose: Let users configure, save, and apply private match settings for Super Animal Royale and calculate tournament results.
File structure
• src/core: Core logic and application entry point (__main__.py). Handles global state, functions, classes, versioning, and Qt app setup.
• src/ui: All UI pages and window definitions. Organized by feature (home, dodgeball, duels, tournaments, etc.).
• src/widgets: Custom Qt widget implementations (buttons, sidebars, popups, etc.).
• updater/: Separate module for the auto-updater window and logic.
• setup.py & requirements.txt: Build/install scripts and dependencies.
README for additional insights
• GUI-centric desktop tool; Windows only.
• No explicit backend services or database—presumably stores presets locally (e.g., JSON or similar).
• Integrates with in-game UI via simulated keypress detection (not shown in file tree, but implied).
Main components & interactions
a. Components
1. Application Launcher
– src/__main__.py loads core App.
2. Core Logic
– src/core: Application state, settings IO, game integration functions.
3. UI Layer
– src/ui: MainWindow, Overlays, Pages. Renders controls, captures user interaction.
4. Widgets Library
– src/widgets: Reusable UI controls.
5. Resource Manager
– src/images & src/styles: QRC-generated resources loaded by UI and widgets.
6. Preset Storage
– Likely JSON or flat-file storage managed by core functions.
7. Updater Module
– updater/: Auto-update interface invoked at startup or on demand.
8. External Game Interface
– Core functions simulate keypresses or read game window state.
b. Relationships / Data Flow
• The Launcher invokes Core Logic.
• Core Logic initializes the UI Layer (MainWindow).
• UI sends user actions (e.g., “Apply Dodgeball Settings”) to Core Logic.
• Core Logic updates External Game via functions (simulate keystrokes).
• Core Logic reads/writes Preset Storage.
• UI displays feedback (via Widgets) and tournament graphs (core uses .github/tournament_graphs templates?).
• On update check: Core Logic launches Updater Module in a separate window.
c. Architectural patterns / design principles
• Modular separation: core, ui, widgets, resources, updater.
• MVC-like:
– Model: core/classes.py, globals.py (application state, presets)
– View: ui/pages + widgets (UI definitions)
– Controller: core/functions.py (handles logic on user events)
• Resource bundling: QRC for images & styles, generated at build time.
• Plugin-style pages: each feature page is its own module.
d. Key technologies
• Python 3.12
• PyQt (qt_core abstraction in core/qt_core.py)
• Qt Resource System (QRC → rc_images.py, rc_fonts.py)
• QSS styling for themes
• Matplotlib or similar for tournament graphs (inferred)
• setuptools (setup.py) and pip (requirements.txt)