Sabbatical Log: November 8thPosted: 2018/11/16
This blog series is running about a week behind my actual work, giving me time to clean things up. The date the actual work was done is in the title, horizontal lines indicate when I stopped writing and started coding.
Time to get to work on some flowers! These should be a basic entity with nothing fancy, just a position (existing component) and a frame counter (new component). The lion’s share of the work is going to be making room instances instead of just using room “templates”.
I’ve got animated, collision-less, objects loading into rooms now. Doesn’t look that impressive, but it’s laid the groundwork for much more complicated things.
Rooms now exist (and have state), there’s a new AnimationSystem that handles advancing frames for anything animating, and GameState now manages room instances rather than only tracking the name of the room your in. RoomTemplates also grew a notion of objects with properties, so things can be placed in rooms with Tiled.
There’s really nothing fancy enough to be worth showing in the code. I still need to make animations configurable (right now they’re hard coded), and convert the collision demo and player to use animations instead of being “known” by the renderer.
I’ve changed animations to actually be backed by files on disk. Like everything else, I went through the trouble of getting hot loading working so changes to the definition files are reflected immediately.
The format is just a frequency followed by frames, nothing fancy.