I'm going to do a mirror thread here about my little RPG project.

The previous step was this: twitter.com/Froyok/status/1518

Like I mentionned before I have the following map which is exported as an "unprocessed" json.
This time I added a second layer (rocks and flowers).

The idea next is to build a texture with the indexes of the map for each layer.
I'm not sure yet how exactly I'm going to encode the data into the RGBA texture (currently using 16bit pngs) because of how well I will be able to decode them on the shader size. 🤔

Since I'm planning to only store the indexes, the texture will be small.

This map of 10x10 square can fit in a 16x16 pixel texture for example. So I can easily have 2 or 4 layers side by side (so 64x16 texture).

I could also split the map in more clever ways horizontally as well to stay around the 4K limit.
Only downside is that I want an uncompressed texture in memory, to ensure indexes are preserved.

Took the time to fiddle a bit during lunch, and got the basics to have two layers side by side. :D
Numpy arrays seem to be put sideways, so I had to swap cooridnates.

Decided to do a little break from the map system and instead add a new postprocess pass (circular blur), because I never have enough of them, all while watching one of my guilty pleasure movie: The Core. :D

Adjusted the vignette mask for the blur and its radius, now I have something a bit more subtle.

Of course, I had to put some Chromatic Aberration in the blur pass. ;D
That blur pass is now the heaviest part of the post-process system, more than the bloom itself !

Alright, I always struggle with math but I'm finally making progress here. I'm finally able to draw my tiles index image in a single screenspace pass now, at the right size ! :)


@TomF More like "where should that UV coordinate go" in this case. :D

Sign in to participate in the conversation
Gamedev Mastodon

Mastodon server focused on game development and related topics.