Skip to content

A Web Service that monitors the MultiplayerSessionList API for BZ2 Vet Strat games and posts to Discord with Webhooks.

License

Notifications You must be signed in to change notification settings

sevsunday/bz2-watchbot

Repository files navigation

BZ2VSR WatchBot - Web Service

A Web Service that monitors multiplayer game data from Battlezone II: Combat Commander, curated specifically for VSR games hosted by the BZ2 Vet Strat Discord community. Inspired by bz2vsr.com.

Relies on the MultiplayerSessionList API by Nielk1 (Github | Twitter).

image

Technical Details

  • Uses Discord Webhooks for communication
  • Polls the BZ2 multiplayer API at configurable intervals
  • Maintains session history for accurate status tracking
  • Handles both Steam and GOG player identifiers
  • Includes enhanced VSR map data

Requirements

  • Python 3.7+
  • python-dotenv
  • aiohttp
  • watchdog

Installation

WARNING: add your .env file to .gitignore to avoid exposing your webhook URL. Anyone with your webhook URL can post to your channel.

  1. Clone or download this repository.
  2. Install dependencies with pip install -r requirements.txt
  3. Create a file called .env in the root directory and add this line DISCORD_WEBHOOK_URL=<your_webhook_url>
  4. Configure the NOTIFICATION_TAG and MONITORED_STEAM_IDS variables in config.py to fit your needs.
  5. Run the bot python main.py

NOTE: run.py runs main.py in a wrapper that will automatically reload the bot if any changes are made to the code. This is useful for local development, and may also be useful in production depending on your server setup.

About

A Web Service that monitors the MultiplayerSessionList API for BZ2 Vet Strat games and posts to Discord with Webhooks.

Resources

License

Stars

Watchers

Forks

Languages