Repository navigation
v0.4.0 - Comptime Atlas & Generic Sprite Storage
What's New
Comptime Atlas Loading (#35)
Load sprite atlas data at compile time from .zon files - no JSON parsing at runtime!
const character_frames = @import("characters_frames.zon");
// Load atlas from comptime data - baked into binary
try engine.loadAtlasComptime("characters", character_frames, "assets/characters.png");Generic Sprite Storage (#32)
Flexible internal sprite storage with generational indices. Define custom sprite data types:
const MySpriteData = struct {
x: f32 = 0,
y: f32 = 0,
generation: u32 = 0, // Required
active: bool = false, // Required
};
const Storage = GenericSpriteStorage(MySpriteData, 10000);
var storage = try Storage.init(allocator);Other Improvements
- Updated documentation (CLAUDE.md, README.md)
- Extracted sprite storage tests to dedicated test file
- Cleaner API without backwards compatibility wrappers
Breaking Changes
SpriteStoragewrapper removed - useGenericSpriteStoragedirectly- Sprite storage now uses
allocSlot()pattern for allocation