You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This commit introduces support for spritesheets, allowing sprites to use frames from a spritesheet texture atlas instead of standalone images.
Key changes include:
- **Sprite Class:** Added `spritesheetResourceName` and `spritesheetFrameName` properties to the `Sprite` class to store spritesheet information.
- **Serialization:** Updated `Direction::UnserializeFrom` and `SaveSpritesDirection` to handle saving and loading spritesheet data.
- **Resource Management:**
- Introduced `SpritesheetResource` to represent spritesheet files in the project.
- Added `PixiSpritesheetManager` in GDJS to load and manage spritesheet JSON data and PIXI.Spritesheet objects.
- Integrated spritesheet loading into `ResourceLoader` and `ArbitraryResourceWorker`.
- **Runtime:**
- Modified `SpriteAnimator` and `SpriteAnimationFrame` to handle spritesheet frames.
- Updated `PixiAnimationFrameTextureManager` and `PixiRenderer` to retrieve textures from spritesheets.
- Added `getSpritesheetFrameTexture` to `CustomRuntimeObject3DRenderer` (though 3D objects do not support spritesheets).
This feature enhances the flexibility of sprite animations by enabling the use of more efficient texture atlases.
Co-authored-by: florian <[email protected]>
0 commit comments