Proto-driven item registry forbevy_items
Proto-driven item definitions for Bevy games — compiles itemdb.proto into typed Rust structs with a searchable ItemDb registry any game can load and query.
One proto, every game
itemdb.proto is the single source of truth — prost-build generates the Rust structs at build time, the same proto feeds a Zod schema, and human-authored Astro MDX content served as /api/itemdb.json loads at runtime via ItemDb::from_json().
What it gives you
Features
Proto-driven schema
itemdb.proto is the single source of truth; prost-build generates the Rust item structs at build time.
Searchable ItemDb resource
Query items by slug, ULID, type flags, or rarity.
JSON loading
ItemDb::from_json() parses /api/itemdb.json, handling string-to-enum conversion automatically.
Game-agnostic
The same registry serves Isometric, DiscordSH, and other Bevy games.
Optional inventory adapter
The inventory feature wires in bevy_inventory.
Get started
Usage
[dependencies]
bevy_items = { path = "packages/rust/bevy/bevy_items" }Questions
Frequently asked
What does the bevy_items crate do?
It compiles the shared itemdb.proto schema into typed Rust structs via prost and wraps them in a searchable ItemDb Bevy resource, so any game can load the same item registry and query it by slug, ULID, type flags, or rarity.
Where do bevy_items item definitions come from?
The itemdb.proto file is the source of truth. Human-authored content lives in Astro MDX files at kbve.com/itemdb, is served as /api/itemdb.json at build time, and ItemDb::from_json parses that JSON into proto structs with automatic string-to-enum conversion.
Is bevy_items tied to a specific game?
No. It is game-agnostic — Isometric, DiscordSH, and other Bevy games load the same proto item registry, keeping item data consistent across the KBVE ecosystem.