---
title: "WarGames"
url: "https://aigamehub.app/zh-tw/games/wargames-a6b5ee"
source: "https://github.com/NoblerWorks-HQ/WarGames"
source_type: "github"
play_url: "https://noblerworks.com/"
platform: "desktop"
login_required: false
pricing: "free"
origin: "original"
ai_tools: ["Claude", "Gemini", "ChatGPT"]
game_languages: ["en"]
author: "NoblerWorks-HQ"
author_handle: "NoblerWorks-HQ"
category: "時事諷刺"
categories: ["current-affairs-satire", "simulation"]
tags: ["geopolitics", "llm", "map", "multi-agent", "open-source", "strategy"]
added: "2026-10-16T17:08:28.926Z"
updated: "2026-10-16T17:08:28.927Z"
locale: "zh-tw"
content_locale: "zh-tw"
---

# WarGames

一款由 AI 驅動的地緣政治策略模擬遊戲，北約、俄羅斯與中國在互動式地圖上爭奪領土與全球霸權，每個陣營由 LLM（Claude、Gemini 或 GPT）指揮。

## Description

War Games 是一款開源、以瀏覽器為基礎的地緣政治策略模擬遊戲。三大強權——北約、俄羅斯與中國——在互動式 Leaflet 地圖上爭奪領土、資源與全球霸權。每個陣營由一個 LLM 控制，每回合做出策略決策，包括核打擊與終局勝利畫面。本專案以 TypeScript、Vite、Leaflet 與 Express 建構，支援 Google Gemini、OpenAI 與 Anthropic Claude，並可針對各陣營覆寫供應商（例如北約用 Claude、俄羅斯用 Gemini、中國用 ChatGPT）以及一個旁白模型。在本機執行需要 Node 以及至少一個供應商的 API 金鑰：將 `.env.example` 複製為 `.env`，設定金鑰，然後執行 `npm run dev` 並開啟 http://localhost:3000。API 伺服器預設綁定於 127.0.0.1:3001。以 MIT 授權。

## Original post

AI-powered geopolitical strategy simulation — NATO, Russia, and China compete for global dominance on an interactive map, each faction commanded by an LLM (Claude, Gemini, or GPT). Built with TypeScript, Vite, Leaflet, and Express.

Topics: ai, claude, express, game, gemini, geopolitics, leaflet, llm, multi-agent, openai, simulation, strategy-game, typescript, vite, wargame

# War Games AI-powered geopolitical strategy simulation. Three great powers - NATO, Russia, and China - compete for territory, resources, and global dominance on an interactive map. Each faction is controlled by an AI making strategic decisions every turn. ![AI Strategy](https://img.shields.io/badge/AI-Strategy%20Simulation-red) ![TypeScript](https://img.shields.io/badge/TypeScript-007ACC?logo=typescript&logoColor=white) ![Leaflet](https://img.shields.io/badge/Leaflet-199900?logo=leaflet&logoColor=white) ![Vite](https://img.shields.io/badge/Vite-646CFF?logo=vite&logoColor=white) ![Express](https://img.shields.io/badge/Express-000000?logo=express&logoColor=white) ![Gemini](https://img.shields.io/badge/Google%20Gemini-8E75B2?logo=googlegemini&logoColor=white) ![OpenAI](https://img.shields.io/badge/OpenAI-412991?logo=openai&logoColor=white) ![Claude](https://img.shields.io/badge/Anthropic%20Claude-D4A574?logo=anthropic&logoColor=white) ![License MIT](https://img.shields.io/badge/License-MIT-green) ![Open Source](https://img.shields.io/badge/Open%20Source-%E2%9D%A4-red) ![Nuclear Launch Detected](screenshots/wargames-nuclear-launch-detected.png) ![Nuclear Explosion](screenshots/wargames-nuke-explosion.png) ![End Game - Victory Screen](screenshots/wargames-endgame.png) ## Quick Start ```bash # Install dependencies npm install # Configure your AI provider (see below) cp .env.example .env # Edit .env with your API key # Run (starts both server + client) npm run dev ``` Open http://localhost:3000 and click **Start Game**. The API server listens on 127.0.0.1:3001 only (set `HOST=0.0.0.0` to expose it on your network - every game spends your provider key). ## AI Providers War Games supports three AI providers. Pick whichever you prefer - you only need one. ### Google Gemini (default, cheapest) 1. Get an API key at https://aistudio.google.com/apikey 2. Set in `.env`: ``` AI_PROVIDER=gemini GEMINI_API_KEY=your-key-here ``` ### OpenAI / ChatGPT 1. Get an API key at https://platform.openai.com/api-keys 2. Set in `.env`: ``` AI_PROVIDER=openai OPENAI_API_KEY=your-key-here ``` ### Anthropic / Claude 1. Get an API key at https://console.anthropic.com/settings/keys 2. Set in `.env`: ``` AI_PROVIDER=anthropic ANTHROPIC_API_KEY=your-key-here ``` ### Mix and Match - Different AI per Faction Want Claude commanding NATO while Gemini runs Russia and ChatGPT leads China? Set per-faction overrides: ```env AI_PROVIDER=gemini # default for any faction without an override NATO_AI_PROVIDER=anthropic # NATO uses Claude RUSSIA_AI_PROVIDER=gemini # Russia uses Gemini CHINA_AI_PROVIDER=openai # China uses ChatGPT NARRATOR_AI_PROVIDER=anthropic # Narrator uses Claude # You'll need API keys for each provider you use GEMINI_API_KEY=... OPENAI_API_KEY=... ANTHROPIC_API_KEY=... ``` ### Advanced Configuration | Variable | Default | Description | |----------|---------|-------------| | `AI_PROVIDER` | `gemini` | Global default: `gemini`, `openai`, or `anthropic` | | `NATO_AI_PROVIDER` |
