copilot-instructions
Documents the architecture, rendering, quest system, and build command for a C#/.NET 10 ASCII console adventure game with a C++ native library.
What this file does
Documents the architecture, rendering, quest system, and build command for a C#/.NET 10 ASCII console adventure game with a C++ native library.
When to use it
- Starting a new ASCII console game in C# with flicker-free rendering
- Designing a quest system with per-level objectives
- Setting up a mixed C# and C++ project with native sound effects
- Defining project conventions for a team or open-source game
Assumes this stack
Copilot Instructions - Sariq: Thief of the Ancient Sands
Project Overview
Sariq (Arabic for Thief) is a Middle East-themed ASCII console adventure game built with C# (.NET 10) and a C++ native library. The player is a desert thief navigating 5 levels.
Architecture
- Program.cs - Entry point
- GameEngine.cs - Main loop, state machine, ANSI escape setup, quest integration
- Player.cs - Player state (icon: crossed swords)
- Enemy.cs - 7 enemy types with factory methods
- EnemyAI.cs - Per-type AI behaviors
- Item.cs - Collectibles: Gold, Potion, Key, Compass, Gem, Scroll
- LevelFactory.cs - 5 hand-crafted levels
- Renderer.cs - Buffer-based ANSI renderer (flicker-free)
- CombatSystem.cs - Turn-based combat with crits/dodges/flee
- NativeSoundEngine.cs - Sound effects via kernel32 Beep
- AsciiArt.cs - All ASCII art assets
- QuestSystem.cs - Per-level quest definitions and tracking
Rendering (Flicker-Free)
- Uses ANSI escape sequences in a StringBuilder
- Single Console.Write call per frame
- EnableAnsiEscapes() enables VT processing on Windows
Quest System
Each level has 3 quests: KillAll, CollectGold, CollectItems, ReachPortal, FindKey, SurviveAboveHp
Conventions
- .NET 10, C# 14, C++17
- Top-level statements, file-scoped namespaces, collection expressions
- Player icon is crossed swords - no religious symbols
- Static factory methods for Enemies/Items
Building
dotnet run --project Nataf/Nataf.csproj
What's inside
Project overview, architecture with 12 files, rendering technique, quest system, conventions, and build command.
Change this for your project
- Replace
Nataf/Nataf.csprojwith your own project path - Replace
shankar-sachin/sariqwith your repository name - Replace
SariqandSariq: Thief of the Ancient Sandswith your game title
Where it goes
Keep it in your repository where the agent or team that needs it will read it.
Related Documents
System Prompt
Defines the identity, capabilities, response style, and spec workflow for an AI assistant named Kiro that helps developers build features incrementally.
World Engine AI Coding Instructions
Defines game scope, architecture, ESLint rules, git workflow, and open-source research policy for a strategic fantasy RPG project.
GitHub Copilot Instructions
Defines coding standards, architecture rules, PR expectations, and output format for a Laravel + Inertia + Vue 3 project.
Business Intelligence Dashboard - Comprehensive GitHub Copilot Instructions
Defines the full stack, setup commands, security rules, and testing strategy for a Next.js SaaS analytics platform with multi-tenant isolation.