Structure a Bevy app around its Entity Component System: build the App with plugins, define Component/Resource types, write systems with Query/Res/Commands, filter and order systems, and use the…

Apache-2.0Auto-check passedDevelopment

Install Bevy Ecs

skills CLI
$ npx skills add gamedev-skills/awesome-gamedev-agent-skills --skill bevy-ecs -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install gamedev-skills/awesome-gamedev-agent-skills bevy-ecs --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/gamedev-skills/awesome-gamedev-agent-skills.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/other-engines/bevy-ecs .claude/skills/bevy-ecs && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
bevy-ecs
GitHub stars
1.4k
Token cost
~2.5k tokens
SKILL.md length
827 words
Files
2 (incl. references)
Skills in repo
53
Repo updated
First seen
Licence
Apache-2.0

At a glance

Structure a Bevy app around its Entity Component System: build the App with plugins, define Component/Resource types, write systems with Query/Res/Commands, filter and order systems, and use the…

  • Works in 6 steps: Cargo.toml + minimal App → Components, resources, and spawning → A system with a query + the Time resource → …
  • Debugging a Bevy game in Rust — when the user mentions Bevy
  • SKILL.md covers When to use, Core workflow, Patterns and Pitfalls, plus 2 more sections
  • Calls cargo

What it does

Bevy Ecs is an agent skill from gamedev-skills/awesome-gamedev-agent-skills. Structure a Bevy app around its Entity Component System: build the App with plugins, define Component/Resource types, write systems with Query/Res/Commands, filter and order systems, and use the Time resource for frame-rate-independent motion. Use when building or debugging a Bevy game in Rust — when the user mentions Bevy, ECS, App::new, addsystems, Query, Commands, components/systems, or a Cargo.toml depending on bevy.

Its SKILL.md is about 2.5k tokens, which your agent loads only when the skill is triggered. The skill folder holds 2 other files, including reference files (for example `references/queries-and-scheduling.md`).

It sits in Development. It works with Rust. The repository describes itself as: 74 game-dev skills for AI coding agents — Godot, Unity, Unreal, Phaser, PixiJS, three.js, Bevy, pygame, LÖVE, Roblox. Portable SKILL.md Agent Skills (the format Anthropic… The licence is Apache-2.0.

When your agent uses it

  • Debugging a Bevy game in Rust — when the user mentions Bevy
  • Components/systems
  • A Cargo.toml depending on bevy

Example prompts

  • “/bevy-ecs”

Workflow steps

6 steps, taken from the step headings in SKILL.md.

  1. Cargo.toml + minimal App
  2. Components, resources, and spawning
  3. A system with a query + the Time resource
  4. Query filters (With / Without / Changed)
  5. Resources: read and write
  6. Ordering, run conditions, and plugins

What it can do on your machine

Read from SKILL.md and the folder at commit 0a70cfc. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • cargo

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Bevy Ecs loads about 2.5k tokens when it runs, and up to ~5.3k if it reads all its reference files. Until then it costs about 109 tokens; SKILL.md has 827 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~109
When it runs · the whole SKILL.md, loaded when a task matches
~2.5k
With references · SKILL.md plus every file in references/, read only if the agent opens them
~5.3k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from gamedev-skills/awesome-gamedev-agent-skills at commit 0a70cfc, republished under its Apache-2.0 licence (© gamedev-skills). 827 words, ~2,467 tokens.

Download SKILL.mdSave it as .claude/skills/bevy-ecs/SKILL.md (or your agent's skills folder). This skill also uses 1 other file; get the full folder from GitHub.
name
bevy-ecs
description
Structure a Bevy app around its Entity Component System: build the App with plugins, define Component/Resource types, write systems with Query/Res/Commands, filter and order systems, and use the Time resource for frame-rate-independent motion. Use when building or debugging a Bevy game in Rust — when the user mentions Bevy, ECS, App::new, add_systems, Query, Commands, components/systems, or a Cargo.toml depending on bevy.

Bevy ECS

Structure a Bevy game in Rust around the Entity Component System: the App and plugins, components and resources, systems with queries, scheduling, and frame-rate-independent updates. New examples target Bevy 0.20. If the project already pins another release, keep that release and use its matching migration guide.

When to use

  • Use when wiring a Bevy App, defining Component/Resource types, writing systems that query entities, ordering/filtering systems, or fixing borrow-conflict panics and frame-dependent movement.
  • Use when Cargo.toml depends on bevy and code calls App::new(), add_systems, Query, or Commands.

When not to use: this is the ECS core. Deep rendering, custom shaders/ pipelines, UI layout, and audio are separate concerns. For engine-agnostic AI or procedural algorithms, pair with game-ai / procedural-gen.

Core workflow

  1. Detect and pin the version. Read Cargo.toml and Cargo.lock first. For a new project use bevy = "0.20"; never silently migrate an existing project across a Bevy minor release. Treat the matching docs and migration guides as truth.
  2. Build the App. App::new().add_plugins(DefaultPlugins) gives windowing, input, rendering, time, etc. Register systems into schedules: Startup (once) and Update (every frame).
  3. Model data as components, globals as resources. #[derive(Component)] for per-entity data; #[derive(Resource)] for one-of-a-kind data (score, settings, the Time clock). Since 0.19 Resource extends Component and each resource is stored on its own entity, so do not derive both.
  4. Write systems as plain functions. Parameters declare data access: Query<...> for entities, Res<T>/ResMut<T> for resources, Commands for deferred spawn/despawn. Systems run in parallel when their accesses don't conflict.
  5. Drive motion by time.delta_secs() so speed is frame-rate independent.
  6. Order only what must be ordered with .chain() or explicit constraints; gate systems with run_if. Group related setup into Plugins. Build with cargo run and read the panics — Bevy reports conflicting queries at startup.

Patterns

1. Cargo.toml + minimal App
toml
# Cargo.toml — pin the version; the API differs across minor releases.
[dependencies]
bevy = "0.20"
rust
// main.rs
use bevy::prelude::*;

fn main() {
    App::new()
        .add_plugins(DefaultPlugins)            // window, input, render, time, ...
        .add_systems(Startup, setup)            // runs once at startup
        .add_systems(Update, move_players)      // runs every frame
        .run();
}
2. Components, resources, and spawning
rust
#[derive(Component)]
struct Player;

#[derive(Component)]
struct Velocity(Vec2);

#[derive(Resource)]
struct Score(u32);

fn setup(mut commands: Commands) {
    commands.insert_resource(Score(0));

    // Camera2d is a component with required components (bundles removed in 0.16);
    // spawning it pulls in Transform, Camera, etc. automatically.
    commands.spawn(Camera2d);

    // Spawn an entity as a tuple of components.
    commands.spawn((
        Player,
        Velocity(Vec2::new(150.0, 0.0)),
        Transform::from_xyz(0.0, 0.0, 0.0),
    ));
}
3. A system with a query + the Time resource
rust
// Iterate every entity that has BOTH Velocity and Transform; mutate Transform.
fn move_players(time: Res<Time>, mut query: Query<(&Velocity, &mut Transform)>) {
    for (velocity, mut transform) in &mut query {
        // delta_secs() is f32 seconds (renamed from delta_seconds() in 0.16).
        transform.translation += velocity.0.extend(0.0) * time.delta_secs();
    }
}
4. Query filters (With / Without / Changed)
rust
// Only entities tagged Player (the Player component itself isn't read).
fn aim_player(mut q: Query<&mut Transform, With<Player>>) { /* ... */ }

// Disjoint two mutable Transform queries so they don't conflict at runtime.
fn separate(
    mut players: Query<&mut Transform, With<Player>>,
    mut enemies: Query<&mut Transform, Without<Player>>,
) { /* ... */ }

// React only when Health changed since last run (change detection).
fn on_health_change(q: Query<&Health, Changed<Health>>) {
    for health in &q { /* update the HUD, etc. */ }
}
5. Resources: read and write
rust
fn add_points(mut score: ResMut<Score>) {
    score.0 += 10;                 // ResMut = write access
}

fn show_score(score: Res<Score>) {
    info!("score: {}", score.0);   // Res = read access
}
6. Ordering, run conditions, and plugins
rust
fn main() {
    App::new()
        .add_plugins((DefaultPlugins, GameplayPlugin))
        // .chain() forces order: damage resolves before death is checked.
        .add_systems(Update, (apply_damage, check_deaths).chain())
        // run_if gates a system on a condition each frame.
        .add_systems(Update, spawn_wave.run_if(wave_timer_finished))
        .run();
}

struct GameplayPlugin;
impl Plugin for GameplayPlugin {
    fn build(&self, app: &mut App) {
        app.insert_resource(Score(0))
           .add_systems(Startup, setup)
           .add_systems(Update, (move_players, add_points));
    }
}

Pitfalls

  • delta_seconds() not found → it was renamed to time.delta_secs() (and elapsed_secs()) in 0.16. Using the old name fails to compile.
  • Movement speed scales with frame rate → multiply per-frame changes by time.delta_secs(). Never assume a fixed frame time.
  • Panic error[B0001]: "... accesses component(s) Transform in a way that conflicts with a previous system parameter" → two Querys in one system both write the same component, or one reads while another writes overlapping entities. Make them disjoint with With/Without, or use ParamSet.
  • Camera2dBundle/SpriteBundle not found → bundles were deprecated in 0.15 and removed in 0.16. Spawn the components directly (Camera2d, Sprite, Transform); required components fill in the rest.
  • "trait Component is not implemented" → you forgot #[derive(Component)] (or #[derive(Resource)] for a resource).
  • Spawned entity not visible to a later query in the same frame → Commands are deferred and applied at the next sync point. Read the entity in a subsequent system, not the one that spawned it.
  • System order assumed but not enforced → systems run in parallel by default. If B must follow A, add (A, B).chain() or an explicit ordering constraint. To find order dependencies that only work by accident, shuffle the schedule in tests with ScheduleBuildSettings::shuffle_seed (0.20, debug feature; see the reference).
  • "conflicting implementations of trait Component" after deriving both Resource and Component → since 0.19 Resource extends Component; derive Resource alone.
  • "Despawn everything" panics, or Query<EntityMut> next to a Res<T> panics with error[B0002] → since 0.19 every resource lives on an entity tagged IsResource, so Query<Entity>/EntityRef/EntityMut match those entities too. Query your own marker component, or add Without<IsResource> (use bevy::ecs::resource::IsResource).
  • On<Add, Player> fails with "struct takes 1 generic argument but 2 generic arguments were supplied" → 0.20 moved the component into the lifecycle event: write On<Add<Player>> (likewise Insert<T>, Discard<T>, Remove<T>, Despawn<T>).
  • OnExit/OnEnter run again when "switching" to the current state → NextState::set always runs the transition schedules. Use set_if_different to skip same-state transitions (renamed from set_if_neq in 0.20; calling set_if_neq on a ResMut<NextState<_>> picks up the unrelated change-detection method and fails with "can't compare NextState").
  • "text does not live long enough" from Name::new(text.as_str()) → since 0.20 Name takes a &'static str literal or an owned String, not a borrowed &str; pass Name::new(text.clone()) or Name::new(format!("Enemy {id}")).
  • Overlapping sprites swap draw order after upgrading to 0.20 → sprites now render through the Mesh2d backend, and draw order at equal z was never guaranteed. Give sprites that can overlap distinct Transform z values.
  • Copy-pasting older Bevy snippets → APIs shift between minor versions. The buffered event system became the message system: EventReader/EventWriter/ add_event no longer exist, so use #[derive(Message)], MessageReader/ MessageWriter, and app.add_message::<T>(). Verify against the docs and migration guide for your pinned version; don't mix versions.
Show full SKILL.md (63 more words)Show less

References

  • For schedules and SystemSet ordering (including 0.20 weak ordering and schedule shuffling), States/OnEnter/OnExit and state-scoped despawning, change detection, Commands lifecycle and sync points, ParamSet and resource-entity conflicts, iter_many results, and messages/observers in 0.20 syntax, read references/queries-and-scheduling.md.
  • game-ai — FSMs/behavior trees/steering as portable concepts to implement in ECS.
  • procedural-gen — noise/RNG/generation algorithms to drive from systems.
  • pygame-core / love2d-core — lighter-weight engines for smaller projects.

© gamedev-skills, Apache-2.0. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 1 other file (references) in skills/other-engines/bevy-ecs of gamedev-skills/awesome-gamedev-agent-skills.

  • SKILL.md
  • references/queries-and-scheduling.md

Open the folder on GitHubat commit 0a70cfc

Compare with similar skills

Bevy Ecs next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Bevy Ecs compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Bevy Ecs this skillgamedev-skills/awesome-gamedev-agent-skills1.4k—~2.5kAutomated safety check: PassApache-2.0
Dojo Contributingdojoengine/dojo478—~356Automated safety check: PassApache-2.0
Commitmxpv/openusd132—~982Automated safety check: PassMIT
Releasemxpv/openusd132—~2kAutomated safety check: PassMIT
Migrate Core Code to Submodulestinyhumansai/openhuman42k—~2.6kAutomated safety check: PassGPL-3.0
OpenLogi macOS Permissions TriageAprilNEA/OpenLogi23k—~2.5kAutomated safety check: NotesApache-2.0

Similar skills

  • Dojo Contributing

    dojoengine/dojo

    Contributor workflow for dojoengine/dojo. An agent skill from dojoengine/dojo.

    478 GitHub stars~356 tokensUpdated 5 mo ago
    DevelopmentAuto-check passed
  • Commit

    mxpv/openusd

    Stage and commit changes with pre-flight checks, doc updates, and roadmap tracking.

    132 GitHub stars~982 tokensUpdated today
    DevelopmentAuto-check passed
  • Release

    mxpv/openusd

    Publish a new release of the openusd workspace crates. An agent skill from mxpv/openusd.

    132 GitHub stars~2k tokensUpdated today
    DevelopmentAuto-check passed
  • Migrate Core Code to Submodules

    tinyhumansai/openhuman

    Plans and carries out moving non-host-specific code and its tests from the OpenHuman core into vendored tiny submodule libraries, then releases the submodule and re-pins the host.

    42k GitHub stars~2.6k tokensUpdated today
    DevelopmentAuto-check passed
  • Decides whether an OpenLogi device problem on macOS is a privacy-permission (TCC) problem, using agent log lines, and says which identity needs which grant.

    23k GitHub stars~2.5k tokensUpdated today
    DevelopmentAuto-check: notes
  • Guide for writing idiomatic Rust code based on Apollo GraphQL's best practices handbook.

    5.6k GitHub starsUsed in 3 repos~1.1k tokens
    DevelopmentAuto-check passed

More from gamedev-skills/awesome-gamedev-agent-skills

All 53 skills in this repo
  • Create Game Assets

    gamedev-skills/awesome-gamedev-agent-skills

    Plan, generate, source, normalize, and validate cohesive visual game assets.

    1.4k GitHub stars~2k tokensUpdated 2 days ago
    Auto-check passed
  • Roblox UI

    gamedev-skills/awesome-gamedev-agent-skills

    Build production Roblox interfaces with ScreenGui/PlayerGui lifecycle, responsive UDim2 layouts, safe insets, reusable editable Instances, cross-device input and selection, restrained motion…

    1.4k GitHub stars~2.9k tokensUpdated 2 days ago
    Auto-check passed
  • AI Behavior Trees Utility AI

    gamedev-skills/awesome-gamedev-agent-skills

    Build a production behavior-tree runtime (Blackboard, action/condition leaves, sequence/selector/parallel composites, decorators) and a Utility AI system (response curves — linear, exponential…

    1.4k GitHub stars~2k tokensUpdated 2 days ago
    Auto-check passed
  • Card Game

    gamedev-skills/awesome-gamedev-agent-skills

    Build a card game: card data, deck/hand/discard zones, draw/shuffle/reshuffle, a turn structure, costs, and effect resolution.

    1.4k GitHub stars~1.6k tokensUpdated 2 days ago
    Auto-check passed
  • Fps Shooter

    gamedev-skills/awesome-gamedev-agent-skills

    Build a first-person shooter: move+mouse-look controller, hitscan or projectile shooting, weapons, health, and enemy AI.

    1.4k GitHub stars~1.5k tokensUpdated 2 days ago
    Auto-check passed
  • Godot 2D Movement

    gamedev-skills/awesome-gamedev-agent-skills

    Implement 2D kinematic character movement in Godot 4.7 with CharacterBody2D and moveandslide(): platformer run/jump with gravity, top-down 8-direction motion, slope handling, and reading collisions.

    1.4k GitHub stars~1.5k tokensUpdated 2 days ago
    Auto-check passed

Works with

Questions about Bevy Ecs

What does Bevy Ecs do?

Structure a Bevy app around its Entity Component System: build the App with plugins, define Component/Resource types, write systems with Query/Res/Commands, filter and order systems, and use the…. Bevy Ecs is an agent skill from gamedev-skills/awesome-gamedev-agent-skills. Structure a Bevy app around its Entity Component System: build the App with plugins, define Component/Resource types, write systems with Query/Res/Commands, filter and order systems, and use the Time resource for frame-rate-independent motion.

When should I use Bevy Ecs?

Bevy Ecs fits situations like: debugging a Bevy game in Rust — when the user mentions Bevy; components/systems; A Cargo.toml depending on bevy.

How do I install Bevy Ecs in Claude Code?

Run `npx skills add gamedev-skills/awesome-gamedev-agent-skills --skill bevy-ecs -a claude-code`. Or copy the skill folder (skills/other-engines/bevy-ecs in gamedev-skills/awesome-gamedev-agent-skills) into .claude/skills/bevy-ecs in your project. Claude Code loads it when a task matches its description.

How do I install Bevy Ecs in Codex?

Run `npx skills add gamedev-skills/awesome-gamedev-agent-skills --skill bevy-ecs -a codex`. Or copy the skill folder (skills/other-engines/bevy-ecs in gamedev-skills/awesome-gamedev-agent-skills) into .agents/skills/bevy-ecs in your project. Codex loads it when a task matches its description.

Can I use Bevy Ecs in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add gamedev-skills/awesome-gamedev-agent-skills --skill bevy-ecs -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/bevy-ecs, .gemini/skills/bevy-ecs, .github/skills/bevy-ecs and .opencode/skills/bevy-ecs in your project.

What does Bevy Ecs need to run?

Going by SKILL.md and its folder, Bevy Ecs needs the command-line tools its instructions call (cargo).

Does Bevy Ecs access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Bevy Ecs safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Bevy Ecs use?

Bevy Ecs is published under the Apache-2.0 licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Bevy Ecs use?

About 2.5k tokens (SKILL.md is roughly 9.9k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 2.8k tokens, read only when the agent opens those files.

What are the alternatives to Bevy Ecs?

Skills that share tags, products or a category with Bevy Ecs: Dojo Contributing (dojoengine/dojo, 478 stars), Commit (mxpv/openusd, 132 stars), Release (mxpv/openusd, 132 stars) and Migrate Core Code to Submodules (tinyhumansai/openhuman, 42k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Bevy Ecs?

gamedev-skills (a GitHub organization) maintains it in gamedev-skills/awesome-gamedev-agent-skills, which has 1,389 GitHub stars. The repository holds 53 skills in this directory. The repository was last updated on October 9, 2026.

Source: gamedev-skills/awesome-gamedev-agent-skills on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.