Skip to main content

A terminal-based document verification game

Project description

Veritaminal

Version License

A terminal-based document verification game where players act as border control agents, verifying AI-generated documents to approve or deny travelers. Test your judgment, attention to detail, and critical thinking as you navigate through an immersive narrative experience.

๐ŸŽฎ Game Overview

In Veritaminal, you play as a border control agent stationed at various checkpoints around a fictional world. Your job is to review travel documents and decide whether to approve or deny entry based on the current rules and regulations.

Key Features:

  • Immersive Narrative: Experience a compelling story that evolves based on your decisions
  • AI-Powered Content: Uses Google Gemini API to generate unique documents and storylines
  • Progressive Difficulty: Face increasingly complex decisions as the game progresses
  • Multiple Border Settings: Work at different border checkpoints, each with unique challenges
  • Save System: Save your progress and continue your career later
  • Career Tracking: See how your decisions impact your career stats over time

๐Ÿ“‹ Gameplay

Core Mechanics:

  1. Document Verification: Review traveler documents including names, permits, and backstories
  2. Decision Making: Choose to approve or deny each traveler
  3. Narrative Consequences: Your decisions affect trust, corruption, and the overall story
  4. Career Progression: Advance through a 10-day career path at your assigned checkpoint

Commands:

  • approve - Approve the current traveler's entry
  • deny - Deny the current traveler's entry
  • hint - Request a hint from Veritas (the game's AI assistant)
  • rules - Display current verification rules
  • save - Save your current game progress
  • help - Show help information
  • quit - Exit the game

๐Ÿ”ง Installation

Prerequisites

Option 1: Direct Installation from PyPI

pip install veritaminal

Once installed, run the game with:

veritaminal

Option 2: From Source

  1. Clone this repository

    git clone https://github.com/yourusername/veritaminal.git
    cd veritaminal
    
  2. Run the setup script

    # Windows
    python setup_veritaminal.py
    
    # Linux/Mac
    python3 setup_veritaminal.py
    
  3. Set up your Google Gemini API key when prompted, or manually in a .env file:

    GEMINI_API_KEY=your_api_key_here
    

๐Ÿš€ Running the Game

Windows

  • Double-click on veritaminal.bat, or
  • Run in command prompt: veritaminal.bat

Linux/Mac

  • Run the shell script: ./veritaminal.sh

Any Platform with Python

  • Run with Python: python run_game.py (or python3 run_game.py)

Command Line Arguments

The game supports several command line arguments:

  • --debug: Enable debug logging
  • --load [SAVE_FILE]: Load a specific save file
  • --skip-menu: Skip the main menu and start a new game immediately

Example:

python run_game.py --debug --load saves/veritaminal_save_20250312_222841.json

๐Ÿ“ Project Structure

veritaminal/
โ”œโ”€โ”€ __init__.py         # Package initialization
โ”œโ”€โ”€ run_game.py         # Entry point script
โ”œโ”€โ”€ setup_veritaminal.py  # Setup script for API keys
โ”œโ”€โ”€ requirements.txt    # Python dependencies
โ”œโ”€โ”€ game/               # Core game modules
โ”‚   โ”œโ”€โ”€ __init__.py     
โ”‚   โ”œโ”€โ”€ api.py          # API interactions for content generation
โ”‚   โ”œโ”€โ”€ gameplay.py     # Core gameplay mechanics
โ”‚   โ”œโ”€โ”€ main.py         # Main game loop
โ”‚   โ”œโ”€โ”€ main_menu.py    # Menu system
โ”‚   โ”œโ”€โ”€ memory.py       # Game state persistence
โ”‚   โ”œโ”€โ”€ narrative.py    # Story management
โ”‚   โ”œโ”€โ”€ settings.py     # Game settings and configuration
โ”‚   โ””โ”€โ”€ ui.py           # Terminal user interface
โ”œโ”€โ”€ saves/              # Directory for saved games
โ””โ”€โ”€ utils/              # Utility scripts

โš™๏ธ Game Mechanics Explained

Document Verification

Each document contains:

  • Name: The traveler's full name
  • Permit: An identification code that must follow specific formats
  • Backstory: The traveler's reason for crossing the border
  • Additional Fields: May include seals, issuance dates, or other information depending on the border setting

Rules System

Rules evolve as you progress through the game:

  • New regulations are introduced on specific days
  • Border settings have their own unique requirements
  • Trust and corruption metrics affect game outcomes

Narrative System

The game features a dynamic narrative that responds to:

  • Your decision patterns (strict vs. lenient)
  • Specific story events triggered by days or decisions
  • Trust and corruption metrics

Game Endings

Multiple endings are possible based on:

  • Trust Score: How much the government trusts your decision-making
  • Corruption Level: How often you've bent the rules
  • Days Completed: Whether you completed your 10-day assignment

๐Ÿ› ๏ธ Development

To install in development mode:

pip install -e .

This allows you to make changes to the code and have them immediately take effect when running veritaminal.

Adding New Border Settings

Border settings are managed in game/settings.py and consist of:

  • Name and description
  • Document requirements
  • Common issues
  • Special rules

Requirements

The following Python packages are used:

  • prompt_toolkit: For interactive terminal UI
  • colorama: For cross-platform terminal colors
  • requests: For API calls
  • python-dotenv: For managing API keys

โ“ Troubleshooting

Common Issues

  1. API Key Issues:

    • Ensure your Gemini API key is correctly set in the .env file
    • Check that the key has proper permissions
  2. Display Problems:

    • The game uses colorama for cross-platform terminal colors
    • If you see incorrect characters, ensure your terminal supports UTF-8
  3. Save File Issues:

    • Save files are stored in the saves/ directory as JSON files
    • If loading fails, check file permissions

Debug Mode

Run with --debug to enable detailed logging:

python run_game.py --debug

The log file veritaminal.log will contain detailed information about game operations.

๐Ÿ“ License

This project is licensed under the MIT License - see the LICENSE file for details.

๐Ÿ™ Acknowledgments

  • This game was inspired by "Papers, Please" by Lucas Pope
  • Uses the Google Gemini API for document and narrative generation

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

veritaminal-1.0.0.tar.gz (30.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

veritaminal-1.0.0-py3-none-any.whl (31.8 kB view details)

Uploaded Python 3

File details

Details for the file veritaminal-1.0.0.tar.gz.

File metadata

  • Download URL: veritaminal-1.0.0.tar.gz
  • Upload date:
  • Size: 30.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.9

File hashes

Hashes for veritaminal-1.0.0.tar.gz
Algorithm Hash digest
SHA256 5085b9bc13823a6a3a37d6e483ea11222a3a6353884ad9df8c0f92c86a0e6428
MD5 a5d62bd991b4edd9ade3fb43d6b7fe14
BLAKE2b-256 84720d113e6844beee51af8b7d035451c12f487205d7ea0f34e57983a210e5f5

See more details on using hashes here.

File details

Details for the file veritaminal-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: veritaminal-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 31.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.9

File hashes

Hashes for veritaminal-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 89e458e6950ccb49ba83b75732fde373d476b1f9f05503e78d9845f23edba2aa
MD5 22dae926476df731e58385c6ff4bbade
BLAKE2b-256 0669cd07b2c422093a2a776e1a1494d215e40e3d5b7ffb681bd4817c45a14013

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page