Toxa is a Game Boy developer who’s been working hard in the background coming up with some amazing tools that will expand the capabilities of GB Studio. While many of those features have been made public (we wrote about some of them earlier this year), there have been some really cool developments that have been shared with the GB Studio Central team that we’d like to detail. Keep in mind that these don’t necessarily imply that they will for sure be included in GB Studio, but they are still inspiring to look at and think about what the future of the platform could look like. With that in mind, here’s our first installment of “Tinkering with Toxa”.
You can think of this as “Large Sprites”. Currently, an actor in GB Studio is limited to a 16×16 pixel sprite. While there are tricks and workarounds to getting larger actors to function (basically by combining multiple actors), they tend to be buggy or come with limitations. With meta-sprite integration, you’ll not only be able to build larger multi-part sprites, but also define a series of different animations for different actions using those parts. This more robust toolset can also be used for cutscenes or idle animations. Chris Maltby (the creator of GB Studio) also teased the progress in this area on his Twitter account with these posts:
Further to the ability to make large sprites, this new way of building sprites will allow for pixel accurate collision detection (important for action/adventure games and shoot ’em ups). Each sprite component will also have an anchor point that can be changed. This is much more convenient for more complex animations, as the current system’s “0,0” coordinates is always in the bottom left corner of an actor.
In the above tweet, Chris also hinted at multi-color sprites. As the Game Boy uses two bits per pixel palettes (or four colors total), when a sprite requires transparency, one of those colors must be dedicated to be “clear”. GB Studio implements this by dropping the “dark green” option for sprites (which is available in the backgrounds) and provides a “bright green” color which represents transparency much in the same way a green screen would work. It is possible however to have four color sprites when making Game Boy games outside of GB Studio. With the new meta-tiles toolset you can have four color sprites for traditional Game Boy games and up to twenty-four colors for a sprite in Game Boy Color games (although to get that high would take a lot of effort). The coins in Chris’ tweet above show four colors in a traditional Game Boy game.
Related somewhat to the tools listed above, updating tiles implies that both actors and background tiles can be changed and updated as a script runs. This could virtually eliminate many frame limits for scenes, with the caveat being potentially bloating a ROM with extra data. But the really interesting effect with this tool is the ability to animate backgrounds. Many GB Studio users have come up with nifty ways around this, either by sacrificing actors or using palette cycling tricks. If this tool becomes officially implemented, animated water or plants blowing in the breeze will be possible. This will also allow for entire sprite sheet replacements of both actors and the player sprite, opening up a lot of possibilities.
Here’s an example by Pautomas that uses updating tiles for name entry. Considering that 25 frames is the current limit for all actors in one scene, having both upper and lower case letters or all 26 for that matter was only possible with other tricks. This is all baked into the new system.
It’s already (hopefully) understood that due to the 8-bit architecture, 256 tiles is the absolute limit for any background in game. If you use text on screen, then 64 tiles get used for that and you are left with 192 as the limit. But what if there was a way to increase that tile limit? Well it turns out there is! Every pixel on the Game Boy’s 160×144 screen is addressable, so if you know how, you can actually display 360 unique tiles. Eishiya sent us an example which has 280 tiles displayed without any glitches or buggy artefacts. The trade off is these screens can’t scroll, so they would be limited to title screens, or possibly point and click style scenes. You still have 24 sprite tiles available for interactive portions of your game.
That’s all for now. We’ll be coming back for more cool behind the scenes peeks at some of the cool things Toxa’s working on next month. If you don’t want to miss an article, make sure to subscribe our Newsletter.
Audio Engineer, Mac Technologist and Video Game Developer. Managing Editor of GBStudio Central. (he/him)