project-context
OpenCivilizations project architecture, patterns, and conventions. Auto-applies for implementation tasks to ensure consistency.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
OpenCivilizations project architecture, patterns, and conventions. Auto-applies for implementation tasks to ensure consistency.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Animate 3D objects and characters in Blender with Python. Use when the user wants to keyframe properties, create armatures and rigs, set up IK/FK chains, animate shape keys for facial animation, edit F-Curves, use the NLA editor to blend actions, add drivers for expression-based animation, or script any animation workflow in Blender.
Create 3D models procedurally with Blender Python. Use when the user wants to generate meshes from code, build geometry with bmesh, apply modifiers, create parametric shapes, procedural landscapes, grids, curves, or any programmatic 3D modeling in Blender.
Automate Blender compositing and post-processing with Python. Use when the user wants to set up compositor nodes, add post-processing effects, color correct renders, combine render passes, apply blur or glare, key green screens, create node-based VFX pipelines, or script the Blender compositor.
Automate Blender rendering from the command line. Use when the user wants to set up renders, batch render scenes, configure Cycles or EEVEE, set up cameras and lights, render animations, create materials and shaders, or build a render pipeline with Blender Python scripting.
Write and run Blender Python scripts for 3D automation. Use when the user wants to automate Blender tasks, run headless scripts, manipulate scenes, batch process .blend files, import/export 3D models, manage objects, or script Blender from the command line using the bpy API.
MongoDB database exploration for understanding game data, debugging, and investigation. Auto-applies when discussing database structure or debugging data issues.
| name | project-context |
| description | OpenCivilizations project architecture, patterns, and conventions. Auto-applies for implementation tasks to ensure consistency. |
| allowed-tools | Read, Grep, Glob |
Architecture and conventions for OpenCivilizations (web-based MMORTS).
| Aspect | Standard |
|---|---|
| Language | TypeScript strict |
| Game Engine | Phaser 3 |
| UI Framework | React or Vue (overlays) |
| Backend | Node.js + Colyseus |
| Database | MongoDB |
| Caching | Redis |
docs/architecture.md - System designshared/constants.ts - Game balance datashared/types.ts - Type definitions| Term | Meaning |
|---|---|
| Base | Player's civilization layout |
| Building | Structure on the grid (TownCenter, Farm, Barracks) |
| Unit | Trainable troop with AI behavior |
| Resource | Food, Gold, Oil |
| Age | Technology era (Stone, Bronze, Iron, etc.) |
| Nation | Civilization with unique bonuses |
client/src/
assets/ # Sprites, tiles, audio
game/
scenes/ # Phaser scenes (MainMap, Battle, Loading)
entities/ # Buildings, Units, Projectiles
systems/ # Pathfinding, Grid, Input
ui/ # React/Vue overlays (HUD, Menus)
server/src/
rooms/ # Colyseus game rooms
models/ # MongoDB schemas (User, Base, Clan)
mechanics/ # Authoritative game logic
shared/
constants.ts # Building costs, Unit stats
types.ts # Shared interfaces
// Grid to Screen
function cartesianToIsometric(x: number, y: number) {
return {
x: (x - y) * TILE_WIDTH_HALF,
y: (x + y) * TILE_HEIGHT_HALF
};
}
// Screen to Grid
function isometricToCartesian(isoX: number, isoY: number) {
return {
x: (isoX / TILE_WIDTH_HALF + isoY / TILE_HEIGHT_HALF) / 2,
y: (isoY / TILE_HEIGHT_HALF - isoX / TILE_WIDTH_HALF) / 2
};
}
// Server calculates resources based on time
const elapsed = Date.now() - player.lastUpdate;
const produced = Math.floor(elapsed / 3600000) * farm.productionRate;
player.gold += produced;
// Colyseus schema for synced state
class GameState extends Schema {
@type([Building]) buildings = new ArraySchema<Building>();
@type({ map: Player }) players = new MapSchema<Player>();
}
any without justification