No Game Engine Game Dev: Word Sleuth 072: Sprite Animation for Notebooks opening/closing

4 months ago
17

Streamed on 2024-10-24 (https://www.twitch.tv/thediscouragerofhesitancy)

Game Engines are for sissies!

Today I started working on making a sprite animation for the notebooks to open and close. The easy part was to make the stationary part of the book separate from the front cover.

After that I wrote more Inkscape scripts to generate a rotated cube to represent the front cover as it is opened. We got the cover to rotate through various frames quite nicely. Each frame was exported as a separate image and then imported into GIMP as a new layer for layout. Once the layout was finished it was necessary to re-work our UV embedding code to handle offsets and spacing. There was a bit of debugging involved in that effort as I was writing code to write code, which always has some fun gotchas that you didn't think about or code paths that generate code paths you forgot.

Finally, the blue front cover was put into the Sandbox scene for testing. It looks pretty good as it opens. Once working the way we want, I also put in the green, orange and yellow book covers as well to prove they all work. However, as I was working with the Sprites I came to the determination that I don't want the Sprite to run its own timer; I want the existing Animation to run the Sprite for us. This would give us a lot of existing power without having to duplicate code, for example with easing curves. But that will have to wait for next week.

Loading 1 comment...