Using AttachPoint, you can create "attach points" on the frames of your sprites. You can then export the code and use it in your game to attach an object to another.
- Import sprite sheet(s)
- Set up attach points and their angles
- Export code
When you export, it asks you the name of the state/sprite, which is used for the array's name.
The attach points for that state/sprite are also saved to disk, so you can later load them by using the "Load Points" button and entering the name.
The Export Code button will export a nested array structure, in this format:
[ Sprite : [
Frame0 : [x, y, angle],
Frame1 : [x, y, angle],
Frame2 : [x, y, angle],
// More frames...
// More sprites (if more than one imported)
By default, the coordinates are relative to the middle-center point of each frame.
- Load multiple sprites, each having their own frames
- You can load multiple, directional animation sheets, and set the angles to be relative to the direction
- You can change the origin to either top-left or middle-center
- Inverted crosshair for placing attach points, for easier visiblity
- Preview your attach points by loading a preview sprite
Mouse wheel: Zoom
Can use Alt+Mouse for this
Middle-click drag: Pan
Can use Shift+Mouse for this
Left mouse button: Modify attach point position
Right mouse button: Modify attach point angle
Arrow keys: Navigate frames
What kinds of sprite sheets does it support?
At this point, it only supports horizontal sprite sheets for animation.
Loading frames as separate images will treat them as separate sprites, not an animation.
However, you can still make that work.
Thanks to Samuel Venable for his DLLs!