A minimalist, data-driven, text-based card battler for your terminal.
Project description
Kard-X
A minimalist, data-driven, text-based card battler that runs directly in your terminal.
Welcome to Kard-X, a pure command-line interface (CLI) card game where strategy meets simplicity. Built with Python and designed for extensibility, Kard-X offers a classic deck-builder experience with a modern, tech-inspired feel.
Features
- Purely Text-Based: Enjoy a clean, distraction-free, and retro-cool gaming experience in your terminal.
- Data-Driven Design: All cards and characters are defined in simple
.jsoncfiles. Modifying the game or creating new content is as easy as editing a text file! - Strategic Depth: Manage your Health (HP), Defense (DEF), and Mana to outwit your opponent. Grow stronger by permanently increasing your Max Mana.
- Adventure Mode: Choose routes through a multi-node run with battles, events, shops, rest sites, elites, and a final boss.
- Run Progression: Carry HP, Gold, deck changes, relics, defeated enemies, and event outcomes across an adventure.
- Rarity-Aware Rewards: Card rewards favor common tools, with rare scaling cards like
Mana Crystalappearing less often. - Infinite Replayability: Choose from different hero archetypes, shape your deck, and face unique enemies.
Installation
You can install Kard-X directly from PyPI with a single command:
pip install kard-x
For local development, install it from the repository in editable mode:
python -m pip install -e .
Requires Python 3.10 or higher.
How to Play
After installation, start the game with the console command:
kardx
You can also launch the installed package as a module:
python -m kardx
The old repository-only command still works as a compatibility shim:
python -m src.main
Editable card and character data is copied from the packaged defaults into your user data directory the first time you open a data file from the in-game editor. Restart the game after saving those files.
Game Concept
The main menu offers Adventure Mode for a full route-based run and Quick Battle for the classic single fight. Each character begins with a unique starting deck.
- Objective: Reduce the enemy's HP to zero.
- Turns: Each turn, you draw 5 cards and your Mana is refilled. Play cards by spending Mana.
- Card Effects:
- Attack: Deal damage to the enemy.
- Defense: Gain DEF to block incoming damage for one turn.
- Power: Play cards like
Mana Crystalto permanently increase your Max Mana, enabling more powerful combos in later turns.
- Deck Cycling: Played cards go to discard. When the draw deck runs out, the discard pile is shuffled back into the deck.
- Adventure Nodes: Routes are generated from editable node pools with controlled pacing. Early routes build your deck, shops and rest sites appear before major difficulty jumps, elites can grant relics, and events can upgrade cards or reshape resources.
Editable Content
The Content Editor can open the game's editable JSONC files:
cards.jsoncfor card definitions.characters.jsoncfor playable characters and enemies.adventures.jsoncfor route maps and reward pools.events.jsoncfor non-combat choices.relics.jsoncfor passive run modifiers.
Roadmap (Future Development)
Kard-X is built to be expanded. Here's what's planned for the future:
- Card Reward System: Gain new cards after winning a battle.
- More Enemies & Bosses: Introduce enemies with unique AI and abilities.
- Relics & Artifacts: Add passive items that grant special bonuses.
- Event System: Encounter non-combat events that offer choices and consequences.
- Color Support: Using libraries like
coloramaorrichto enhance the UI.
License
This project is licensed under the MIT License - see the LICENSE file for details.
Built with passion and Python.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file kard_x-0.1.3.tar.gz.
File metadata
- Download URL: kard_x-0.1.3.tar.gz
- Upload date:
- Size: 37.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
043e5bdd4dec79ef40a30496bb0bd147b38d3af912b098d5f4cae8d11ed332cc
|
|
| MD5 |
0912e6d68a93ccd3fb40ca68098c6bd3
|
|
| BLAKE2b-256 |
2d8505973296966795e15cea7a29d39af75eda5c05a9d3d4556555a033530f86
|
File details
Details for the file kard_x-0.1.3-py3-none-any.whl.
File metadata
- Download URL: kard_x-0.1.3-py3-none-any.whl
- Upload date:
- Size: 50.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a89eec0f2f543ef72bcaa2a49833358c4ddcfa406b57e98010e32eba073cd419
|
|
| MD5 |
2e20d3806794760902bde8a090d73222
|
|
| BLAKE2b-256 |
38a67d7d33076f4cc8cbb4b861f97e3c25d5e053d32528855f63675da2504b17
|