Creator · gamedev-skills
Last updated · Sep 2, 2026
Design NPC and enemy decision-making with finite state machines, behavior trees, steering behaviors, and A* pathfinding — engine-neutral algorithms that pair with the detected engine's navigation API. Use when building enemy AI, an FSM or behavior tree, steering/flocking, or path
Sandbox only
Install targets
Codex install prompt
Install the "game-ai" agent skill from https://github.com/gamedev-skills/awesome-gamedev-agent-skills/tree/main/skills/disciplines/game-ai. Read its SKILL.md or equivalent instructions first, install only the files needed for this workspace, and summarize any required setup before using it. Skill purpose: Design NPC and enemy decision-making with finite state machines, behavior trees, steering behaviors, and A* pathfinding — engine-neutral algorithms that pair with the detected engine's navigation API. Use when building enemy AI, an FSM or behavior tree, steering/flocking, or pathfinding, or when the user mentions state machine, behavior tree, blackboard, A*, navmesh, seek, or patrol/chase. After the install attempt, report the result to https://www.openagentskill.com/api/agent/outcome with POST JSON {"event_id":"install_<unique-id>","skill_slug":"gamedev-skills-game-ai","task":"Install game-ai","agent":"codex","outcome":"success","install_used":true}. Replace event_id with a unique value and outcome with success or failed. Report success only after the skill is installed and a minimal verification passes.Supply asset profile
Design assets, images, video, audio, multimodal media, presentation, and creative production skills.
Scenario
Design and creative
I need my agent to produce design assets, UI directions, presentations, or creative media workflows.
Agent fit
Claude Code + CLI + Codex
Codex, Claude Code, Cursor, CLI, or custom agents.
Install
Ready
npx skills add gamedev-skills/awesome-gamedev-agent-skills --skill game-ai
Maintenance
fresh
15d since push
Risk
Needs review
Financial research output is not financial advice; require human review before any live investment decision
GitHub quality
800
76/100 Quality · 82/100 Trust
Coverage tags
Review notes
Financial research output is not financial advice; require human review before any live investment decision · Financial research output is not financial advice; require human review before any live investment decision.
Agent adoption scorecard
These scores combine public repository metadata, OpenAgentSkill review signals, maintenance freshness, and install readiness. They are a shortlist signal, not a replacement for human review.
Quality
StrongSolid option that is likely worth shortlisting for production workflows.
Trust
Sandbox onlyUseful candidate with missing or mixed trust signals. Keep it in an isolated workspace until the outcome loop proves task fit.
Audit
Needs reviewA machine-readable review of install readiness, security metadata, maintenance, and adoption risk.
OpenAgentSkill Trust Score v5
Run only in a sandbox and compare close alternatives before using it for real work.
Stars
800 GitHub stars
Repo activity
800 stars, 61 forks
Maintenance
15d since push
License
Apache-2.0
Install
npx skills add gamedev-skills/awesome-gamedev-agent-skills --skill game-ai
Install safety
Agent-readable metadata
Use this block or the embedded JSON to decide whether an agent should install this skill, choose an alternative, or ask for human review first.
Suited tasks
Suited agents
Install decision
Trust and risk
Outcome loop
Install command
npx skills add gamedev-skills/awesome-gamedev-agent-skills --skill game-aiDo not use when
Alternative
175.1K Stars
npx skills add anthropics/skills --skill frontend-design
Alternative
85.2K Stars
npx skills add Leonxlnx/taste-skill --skill design-taste-frontend
Alternative
1.8K Stars
npx skills add Alisa0808/vox-director --skill vox-director
Alternative
175.1K Stars
npx skills add anthropics/skills --skill canvas-design
Agent safety v2
Usable candidate, but the agent should surface permission and audit notes before installation.
Require human approval before installing into a real workspace.
medium
Skill likely fetches remote pages, APIs, repositories, or external services.
Agent resolve plan
The Resolve API returns the selected skill, alternatives, safety policy, audit notes, install target, and copy-paste prompt an agent can follow without scraping this page.
Open JSON
/api/agent/resolve?task=Use%20game-ai%20for%20an%20agent%20workflow&agent=codex&max_risk=medium
Resolve text
/api/agent/resolve?task=Use%20game-ai%20for%20an%20agent%20workflow&agent=codex&max_risk=medium&format=text
Install handoff
/api/skills/gamedev-skills-game-ai/install
Agent should check
Copy prompt
Task: Use game-ai in this workspace.
Resolve first: https://www.openagentskill.com/api/agent/resolve?task=Use%20game-ai%20for%20an%20agent%20workflow&agent=codex&max_risk=medium
Review install handoff: https://www.openagentskill.com/api/skills/gamedev-skills-game-ai/install
Install command: npx skills add gamedev-skills/awesome-gamedev-agent-skills --skill game-ai
Before running it, summarize audit warnings, required permissions, and the fallback skill if install is risky.Agent handoff
Use the public install endpoint to fetch the command, safety checklist, target prompts, and canonical links for this skill.
Install handoff
/api/skills/gamedev-skills-game-ai/install
LLM text format
/api/skills/gamedev-skills-game-ai/install?format=text
Find alternatives
/api/skills/search?q=game-ai&limit=3
Agent prompt
Use game-ai for this task. Review https://www.openagentskill.com/api/skills/gamedev-skills-game-ai/install, then install with: npx skills add gamedev-skills/awesome-gamedev-agent-skills --skill game-aiRegistry metadata
This page exposes the same decision, trust, audit, use-case, and install signals through the Registry API, so agents can rank this skill without scraping the UI.
Manifest
/api/registry/manifest/gamedev-skills-game-ai
LLM text
/api/registry/manifest/gamedev-skills-game-ai?format=text
Install alias
/api/registry/install/gamedev-skills-game-ai
Recommend
/api/registry/recommend?task=Use%20game-ai%20in%20an%20agent%20workflow&limit=3
Agent fit
Sports analytics
Use-case tags
Platforms
Claude Code
Audit report
A machine-readable review of install readiness, security metadata, maintenance, and adoption risk.
Agent decision cockpit
Use this as a leading candidate, then validate the README and install path in your own agent stack.
Role in stack
Primary pick
Primary fit
Sports analytics
Trust label
Production-ready
Install path
Command ready
Use when
Evidence
review first
Implementation path
Trust profile
Useful candidate with missing or mixed trust signals. Keep it in an isolated workspace until the outcome loop proves task fit.
GitHub adoption
INFO800 GitHub stars
Stars/forks activity
INFO800 stars, 61 forks; issue activity unavailable in current metadata
Recent maintenance
PASS15d since push
License clarity
PASSApache-2.0
Good signals
Review before install
Recommended action
Run only in a sandbox and compare close alternatives before using it for real work.
Quality profile
Solid option that is likely worth shortlisting for production workflows.
Workflow fit
Analyze matches
I need my agent to analyze football matches, World Cup data, xG, players, teams, and predictions.
Search private knowledge
I need my agent to build a RAG workflow over documents and retrieve reliable context.
Operate web apps
I need my agent to control a browser, fill forms, and verify web app workflows.
Workflow fit
Design, build, test, and ship interfaces
A practical workflow for agents that turn product briefs or Figma designs into polished frontend code, review the result, test it in a browser, and prepare a safe deployment.
Ingest, retrieve, and cite
A workflow for document-heavy agents that ingest files, create searchable knowledge, retrieve relevant context, and answer with grounded sources.
Operate and verify web apps
A workflow for agents that navigate products, fill forms, take screenshots, and verify real user flows across web applications.
Alternative shortlist
Similar skills that may fit this task.
Guidance for distinctive, intentional UI design, typography, visual direction, and non-template-like product interfaces.
Design and implementation guidance for distinctive landing pages, portfolios, product demos, and purposeful redesigns.
Turn one topic into a narrated Vox-style paper-collage explainer or ad video, from script through captions.
Create original visual art, posters, PNG assets, and PDF documents through a clear design philosophy.
--- name: game-ai description: > Design NPC and enemy decision-making with finite state machines, behavior trees, steering behaviors, and A* pathfinding — engine-neutral algorithms that pair with the detected engine's navigation API. Use when building enemy AI, an FSM or behavior tree, steering/flocking, or pathfinding, or when the user mentions state machine, behavior tree, blackboard, A*, navmesh, seek, or patrol/chase. ---
# Game AI: decisions, steering, and pathfinding
Build believable NPC behavior from three separable layers: **decide** (what to do), **steer** (how to move there), and **path** (how to route around the map). Keep them decoupled — a behavior tree picks a target, the pathfinder produces waypoints, steering follows them. This skill teaches the engine-neutral algorithms; bind them to your engine via the related skills below.
## When to use
- Use when implementing enemy/NPC logic: patrols, chase/flee, guard states, group movement, or "find a path to the player". - Use to choose between an **FSM** (few clear states), a **behavior tree** (many reactive behaviors with priorities), or **steering** (smooth local movement). - Use when integrating pathfinding: A* on a grid/graph, or driving an engine navmesh agent.
**When *not* to use:** for the engine's concrete navmesh/agent API and baking, use `unity-navmesh`, `unreal-behavior-trees`, or Godot's `NavigationAgent2D/3D` (see that engine skill). For movement/collision feel, use `physics-tuning`. For spawning waves along lanes, see the `tower-defense` genre skill.
## Core workflow
1. **Pick the decision model by complexity.** 2–5 states with obvious transitions → FSM. Many behaviors, priorities, interruption, reuse → behavior tree. Continuous "how strongly do I want each option" → utility scoring. 2. **Separate decision from motion.** The decision layer outputs an *intent* (target position, action). Steering or pathfinding turns intent into motion. 3. **Path on the right graph.** Grid tiles, waypoint graph, or a baked navmesh. Fewer nodes = faster A*. Prefer the engine's navmesh for 3D; A* on a grid for tile games. 4. **Steer along the path**, not straight to the goal — follow the next waypoint, advancing when close, so agents round corners. 5. **Recompute paths sparingly.** Pathfind on a timer or when the goal moves a tile, not every frame. Cache the path; only the waypoint index advances. 6. **Verify by observation.** Watch the agent: does it reach the goal, get stuck on corners, oscillate between states? Draw the path and current state on screen while tuning.
## Patterns
### 1. Finite state machine (one state object, explicit transitions)
```gdscript # Each state is a small object with enter/update/exit. The machine owns "current". class_name State func enter(agent): pass func update(agent, dt) -> State: return null # return a new state to transition func exit(agent): pass
# --- Chase state: returns Patrol when the player escapes sight range --- class Chase extends State: func update(agent, dt) -> State: if not agent.can_see(agent.target): return Patrol.new() # transition by returning next state agent.move_toward(agent.target.position, dt) return null # null = stay in this state
# --- Driver: call once per frame --- func tick(dt): var next = current.update(self, dt) if next != null: current.exit(self); next.enter(self); current = next ```
Keep transition logic *inside* states (or in a table), never as a growing pile of `if` flags. One state owns one behavior; that is what keeps an FSM readable.
### 2. Behavior tree tick (composite nodes return a status)
```gdscript # A node's tick() returns SUCCESS, FAILURE, or RUNNING (still working this frame). enum Status { SUCCESS, FAILURE, RUNNING }
# Sequence: run children in order; stop at the first non-SUCCESS (logical AND). func sequence_tick(children, agent, dt) -> int: for child in children: var s = child.tick(agent, dt) if s != Status.SUCCESS: return s # FAILURE or RUNNING short-circuits the sequence return Status.SUCCESS
# Selector: try children until one succeeds or is RUNNING (logical OR / fallback). func selector_tick(children, agent, dt) -> int: for child in children: var s = child.tick(agent, dt) if s != Status.FAILURE: return s # SUCCESS or RUNNING stops the search return Status.FAILURE ```
A guard AI reads top-down: `Selector[ Sequence[CanSeePlayer?, Chase], Patrol ]` — chase if visible, otherwise patrol. See `references/behavior-trees.md` for leaf nodes, decorators (Inverter, Cooldown), and a blackboard.
### 3. Steering: seek and arrive (smooth, frame-rate independent)
```gdscript # Seek: accelerate toward a target at full speed. Steering = desired - current. func seek(pos, vel, target, max_speed, max_force) -> Vector2: var desired = (target - pos).normalized() * max_speed return (desired - vel).limit_length(max_force) # a force, not a teleport
# Arrive: like seek, but ramp speed down inside slow_radius so it stops cleanly. func arrive(pos, vel, target, max_speed, max_force, slow_radius) -> Vector2: var offset = target - pos var dist = offset.length() if dist < 0.001: return -vel # already there: kill drift var ramped = max_speed * min(dist / slow_radius, 1.0) var desired = offset / dist * ramped return (desired - vel).limit_length(max_force)
# Per frame: vel += steering * dt; pos += vel * dt (always scale by dt) ```
### 4. A* heuristic must not overestimate (or paths stop being shortest)
```python # Match the heuristic to the movement. An ADMISSIBLE heuristic (never larger # than the true remaining cost) keeps A* optimal. def heuristic(a, b): dx, dy = abs(a.x - b.x), abs(a.y - b.y) # return dx + dy # Manhattan: 4-direction grids (no diagonals) return (dx + dy) + (1.414 - 2) * min(dx, dy) # octile: 8-direction grids # f(n) = g(n) + h(n): g = cost from start, h = heuristic to goal. # Overestimating h is faster but no longer guarantees the shortest path. ```
The full A* loop (priority queue, `came_from` reconstruction, grid + waypoint graphs) is in `references/pathfinding.md`.
## Pitfalls
- **Pathfinding every frame** tanks the frame rate. Recompute on a timer or only when the target moves to a new tile; follow the cached waypoints in between. - **Steering straight to the goal** instead of to the next waypoint makes agents hug walls and corners. Follow the path; advance the waypoint when within radius. - **Inadmissible A\* heuristic** (e.g. Euclidean distance scaled up, or Manhattan on a diagonal grid) returns fast but *non-shortest* paths. Pick the heuristic that matches your allowed moves. - **Behavior tree leaves that never return RUNNING** for multi-frame actions (walking, playing an animation) cause the tree to restart the action every tick. Return RUNNING until the action completes. - **FSM transition spaghetti**: scattering `if state == ...` checks everywhere recreates the mess an FSM exists to prevent. Keep transitions in the state. - **No line-of-sight or stuck check** → agents grind into walls forever. Add a timeout that forces a repath or a state change.
## References
- `references/pathfinding.md` — complete A* (priority queue, reconstruction), grid vs waypoint graphs, when to defer to an engine navmesh. - `references/behavior-trees.md` — node taxonomy, leaf/decorator implementations, blackboard, and FSM-vs-BT selection.
## Related skills
- `unity-navmesh`, `unreal-behavior-trees` — concrete engine AI/navigation APIs. - `physics-tuning` — movement, collision response, and agent radius. - `procedural-gen` — generating the graph/level the AI navigates. - `tower-defense`, `fps-shooter` — genres that compose this skill.
Source provenance
Decision snapshot
800 GitHub stars
Audit
Install and adoption review
Agent-proven evidence
Outcome reports after resolve, review, install, and one narrow run.
No agent outcome data yet. The first agent run can report success, setup needs, risk blocks, failure, or not-relevant through /api/agent/outcome.
Install
Free and open source. Review the report before installing into production agents.
Growth loop
Scenario-led draft for game-ai, ready for a manual X post.
game-ai: Design NPC and enemy decision-making with finite state machines, behavior trees, steering beh... 800 stars https://www.openagentskill.com/skills/gamedev-skills-game-ai?ref=x
Listing + install path for game-ai: https://www.openagentskill.com/skills/gamedev-skills-game-ai?ref=x Install: npx skills add gamedev-skills/awesome-gamedev-agent-skills --skill game-ai
Listing source
This listing was indexed from public sources and is not marked official until a maintainer claim is approved.
Attribution links to the public repository or creator profile. Creators can claim the listing to update ownership signals.
Claim this skillOwner claim
This Registry indexed listing is attributed to gamedev-skills but is not marked official yet. Claim it to add a verified owner signal and make future launch, install, and audit updates easier to trust.
Creator backlink kit
Show the canonical listing, current trust and audit signals, and real Agent-Proven evidence where developers evaluate the repository.
[](https://www.openagentskill.com/skills/gamedev-skills-game-ai?ref=github&utm_source=github&utm_medium=referral&utm_campaign=creator_badge)
[](https://www.openagentskill.com/skills/gamedev-skills-game-ai?ref=github&utm_source=github&utm_medium=referral&utm_campaign=creator_badge)
[](https://www.openagentskill.com/skills/gamedev-skills-game-ai/audit)
[](https://www.openagentskill.com/skills/gamedev-skills-game-ai?ref=github&utm_source=github&utm_medium=referral&utm_campaign=creator_badge)gamedev-skills
@gamedev-skills
Share whether this skill looks useful for your agent workflow. Aggregated feedback improves rankings over time.
Sandbox only
Frontend Design
Guidance for distinctive, intentional UI design, typography, visual direction, and non-template-like product interfaces.
175.1K StarsTaste Skill: Anti-Slop Frontend
Design and implementation guidance for distinctive landing pages, portfolios, product demos, and purposeful redesigns.
85.2K StarsVox Director
Turn one topic into a narrated Vox-style paper-collage explainer or ad video, from script through captions.
1.8K StarsCanvas Design
Create original visual art, posters, PNG assets, and PDF documents through a clear design philosophy.
175.1K StarsPermission surface
network or browser access
Agent outcomes
No agent outcome data yet
Docs
Usable metadata, review docs
Risk summary
Install readiness