Project Bolero Devlog 22

Testing Multiple background layers with parallax scrolling, map wrap-around, and tile animations — all conveniently not conveyable with a still screenshot. Here’s a tweet with a video if you’re curious.

Work Since Last Devlog

  • Moved sprite animation state out of actors and into another structure, so other parts of the engine (namely UI widgets) can use them as well.
  • Edited the packaging script to graft the version number, release platform / target and project name into included .txt files.
  • Added map wrapping. If you are on the edge of a map, the draw function will loop back to the other edge. This doesn’t cover the logic to wrap actors as well, but it would be suitable for a looping a background over and over, say, during a cutscene.
  • Added simple tile animations, which can play forward, or forward-and-reverse.
  • Finally relented, and added support for multiple map layers and parallax scrolling. Everything really pops out now. At some point, I had written that I wanted to minimize parallax scrolling and layers, and also background tile animation as a stylistic choice, but I guess it depends on the context.

 

Thoughts

Browsing GUI toolkit options for Lua. Most of them either haven’t been updated in a while (not that that’s necessarily a bad thing), or require building from source on Linux. I did however notice that Python’s Tkinter library has been installed this whole time, and a simple Hello-World program works with no issues. So I’ve been running through some tutorials on how to build forms and attach callbacks in it.

Historically, Tkinter only supported a few image formats like GIF. As of 8.6, it also supports PNG out of the box.

I found a form editor, PyGubu, for designing Tkinter GUIs. Unsure if I’ll be using it at this time, but good to know it’s there.

Lupa allows evaluating Lua code from Python, so maybe I can share parts of the core Lua game engine with external editors this way. Or… maybe it’s good to not to stick too tightly to a single language or environment. I guess there’s also Kivy, which I had been using originally, and which has a really nice-looking UI.

I just noticed that GraphicsGale’s alpha transparency is working. I swear it’s been broken in Wine for a while. Not that I’m complaining, but… what changed? If it stays this way, then I no longer need to run a pass over all of the spritesheets with Pillow to add the alpha.

Plans For Next Post

  • Finish going through Tkinter tutorials and try making a sprite animation editor.