This skill helps an agent structure a Bevy 0.20 game around its ECS. It starts by reading the Bevy version pinned in Cargo.toml and Cargo.lock, models per-entity data as components and shared data as resources, and writes systems as ordinary functions with declared access.
It includes patterns for spawning and filtering, ordering with chain and run conditions, plugins and a headless App test driven by manual time. A long gotcha list covers query-conflict panics, deferred Commands, and renamed APIs from older releases such as EventReader, SpriteBundle and delta_seconds.
What You Get
- A five-step workflow from reading the pinned Bevy version to modelling data, writing systems, ordering them and verifying
- Rust patterns for spawning with required components, disjoint queries, plugins, ordering and run conditions
- A headless cargo test that uses MinimalPlugins and manual time so movement checks are deterministic
- A gotcha list for B0001 and B0002 panics, deferred spawns, resources as entities since 0.19, and renamed events, bundles and state methods
Common Use Cases
- Fixing a B0001 query-conflict panic
- Updating code that uses EventReader, SpriteBundle or Camera2dBundle
- Adding states, run conditions and system ordering to a game
- Writing a headless test for a gameplay rule
What Makes It Unique
Bevy breaks its API in every minor release, so the skill makes the pinned version decide which syntax is right and never mixes snippets from two minors. Its panic texts and the headless test were compiled and run against a real Bevy release, and each old API name is mapped to its replacement.
Under The Hood
The agent loads the SKILL.md and, when needed, a reference on queries, schedules, states and change detection. It reads Cargo.toml and Cargo.lock, edits Rust source files in your project and runs cargo check, cargo test and cargo run, which build code and may download crates through Cargo. It reads the first panic from the run and reports which of these it ran. It fetches no web pages itself and calls no APIs; for visual changes it asks you to run the game and describe what you see.