Releases: katharostech/bevy_retrograde
v0.2.0 - Bevy Transform and Heron Physics
This latest release comes with a few big improvements! 🎉
Transform System
Previously, Bevy retro used it's own transform and hierarchy system. This was done so that we could specify sprite positions as integer pixel positions. We initially thought that this might be helpful, so that you could never represent half-of-a-pixel movement and so that all pixels would be perfectly alligned. After using the system a bit, though, we realized that it was much harder to move objects at variable speeds because we couldn't use floating point positions.
In light of this, we decided to switch to using Bevy's built-in transform system. This makes positioning things in Bevy Retrograde work just like they do in out-of-the-box Bevy, and now entity movement algorithms are much simpler and sprite positions are still rounded to snap them to the grid and perfectly align them.
Un-aligned Sprites
Another big change is the advent of non-perfectly aligned sprites. By default all sprites are snapped to the grid, so to speak, making the pixels of each sprite line up perfectly with all the others, but now there is additionally an option to make individual sprites not aligned. This allows for your characters or enemies, for instance, to move smoothly, if desired, not requring that they snap to the retro-resolution pixels.
Physics Integration
We also integrated the Heron physics engine ( powered by Rapier ), along with our own plugin to enable automatically creating convex collision shapes from sprite outlines. This replaces our old, cumbersome collision detection system and enables a lot of new features such as ray-casting and simulation.
Check out the new examples to learn how to use the new physics system!
Epaint Integration
We have also added a work-in-progress epaint
integration that can be used for debug drawing. While the rendering is not perfect and text is not supported yet, we hope that it can be useful for certain types of debug visualization that can be used while developing a game. For instance, in our case, we used it to troubleshoot pathfinding algorithms by drawing the navigation mesh and the calculated path of the enemy during the game.