Greetings and salutations!
For this week's screenshots, a look at the progress made on the first of the lower tombs, and a glimpse of the room beyond:
The week just past once again focussed primarily on building the first level--but there were a few technical challenges and changes, too.
Monday, May 29. 2017
Of Animal Signs, Room-Work, and Technical Challenges
First of all, as shown above, the first of the lower tombs is, I think, nearing completion. Aside from the new sarcophagus (which I believe was added in the week before last), a bookcase has been added, along with books (some well-preserved, some not), a handful of other items, and a mark on the top--more on which later. The breach in the wall is filling out: there's now fallen soil around it, and fallen blocks. Interestingly, these blocks aren't scattered as one might expect them to be after a fall--they're lined up in front of the breach, and otherwise stacked to one side...
I've also worked somewhat on the room beyond the breach. To some degree this had been previously begun, primarily in applying some of the common elements of the tombs: the tiled floor, the columns, and the sarcophagi. This week--because of the mark mentioned above, as I recall--I added a pair of shelves holding books, and completed the unbroken walls of the room. The room's columns have been completed, too, placed in what will likely be their final positions, and made significantly larger.
Those shelves (well, one of them--I realise now that I didn't do so for the other! ^^; ) have that same mark found on the bookshelf mentioned above. It's a little different here, however. It glows.
Those marks aren't just decorations, neither on the shelves nor the bookshelf. Indeed, they're one of my favourite elements of this setting: animal signs.
The animal signs are images of animals, each represented a specific way. Applying one to a surface confers a boon, the exact effect depending on the animal depicted--one might conceal, another might provide great stamina, while yet another might grant protection from biting insects, for example. No-one knows exactly how or why they work, as far as I know; they're unconnected to magic, or the mist-world. In addition, they only work in areas where the animal in question is well-established. Their effects are very temporary, but can be renewed.
I was somewhat excited to finally be setting about implementing animal signs, as I recall. The basics went fairly smoothly: they're essentially decals, with the colour-texture of the object on which they sit applied to them, and with a normal map that produces the impression that they're carved.
Adding the basis of the glow effect was fairly straightforward, I believe. The tricky bit was adding the details of that glow. Animal signs are supposed to glimmer, almost twinkle--think of blue starlight, and you might have a roughly-appropriate mental image.
The obvious thought is perhaps a particle effect, or a shader-based analogue. However, I was hesitant to take this approach--it seemed a bit heavy-handed, I think. I also didn't want to use too many texture-lookups in the shader. Conversely, I didn't want something that was too static, or that "flowed" too much.
In the end, what I did was use an image composed of layers of "sparkles", in four gradations each of red, green, and blue. This is saved as part of a "mask" image that I was already using to define the area in which the glow appeared, confining that mask to the alpha channel. This is then read in the shader as a single pixel-value, and the red, green, and blue channels carved up into four values each. These values are applied to a set of sine-functions that cause them to fade in and out.
The effect doesn't stand up to really close scrutiny, but I think that it looks rather good, overall. Take a look:
On the technical side, I made a minor change to the player's lantern-light: it now shifts up and down a little with the vertical angle of the player's view: when the player looks up, it's held higher, and when the player looks down, it's held lower. I find that this makes it a little easier to see things a little above and below the player's position, both in terms of lighting the object and in terms of reducing problematic shadows.
Still on technical matters, I discovered a potentially-significant problem in the week just past: I leave gaps between the cells used for portal-culling. This means that an object placed in such a gap may be assigned to no cell. While the resultant lighting issues may be fixed by manually specifying the relevant light, this also means that such objects aren't affected by the portal-culling system.
I'm not yet sure of what to do about this--I've asked after the matter on the Panda3D forum, for now.
Returning to art, I reworked one of my "tiling stone" normal maps. For a while I had been somewhat dissatisfied with the look of certain stone surfaces, in particular the large slabs used in various parts of the tombs: they looked a little like they'd had camouflage paint applied to them, I think. In the week just past, I replaced these, and I'm rather happier with the new version, I believe!
Note that this new normal-map doesn't entirely replace the old: there are some places in which the old normal-map works well, I think.
Finally, as per usual, there were a number of minor changes not mentioned here.
That's all for this week--stay well, and thank you for reading! ^_^
I've also worked somewhat on the room beyond the breach. To some degree this had been previously begun, primarily in applying some of the common elements of the tombs: the tiled floor, the columns, and the sarcophagi. This week--because of the mark mentioned above, as I recall--I added a pair of shelves holding books, and completed the unbroken walls of the room. The room's columns have been completed, too, placed in what will likely be their final positions, and made significantly larger.
Those shelves (well, one of them--I realise now that I didn't do so for the other! ^^; ) have that same mark found on the bookshelf mentioned above. It's a little different here, however. It glows.
Those marks aren't just decorations, neither on the shelves nor the bookshelf. Indeed, they're one of my favourite elements of this setting: animal signs.
The animal signs are images of animals, each represented a specific way. Applying one to a surface confers a boon, the exact effect depending on the animal depicted--one might conceal, another might provide great stamina, while yet another might grant protection from biting insects, for example. No-one knows exactly how or why they work, as far as I know; they're unconnected to magic, or the mist-world. In addition, they only work in areas where the animal in question is well-established. Their effects are very temporary, but can be renewed.
I was somewhat excited to finally be setting about implementing animal signs, as I recall. The basics went fairly smoothly: they're essentially decals, with the colour-texture of the object on which they sit applied to them, and with a normal map that produces the impression that they're carved.
Adding the basis of the glow effect was fairly straightforward, I believe. The tricky bit was adding the details of that glow. Animal signs are supposed to glimmer, almost twinkle--think of blue starlight, and you might have a roughly-appropriate mental image.
The obvious thought is perhaps a particle effect, or a shader-based analogue. However, I was hesitant to take this approach--it seemed a bit heavy-handed, I think. I also didn't want to use too many texture-lookups in the shader. Conversely, I didn't want something that was too static, or that "flowed" too much.
In the end, what I did was use an image composed of layers of "sparkles", in four gradations each of red, green, and blue. This is saved as part of a "mask" image that I was already using to define the area in which the glow appeared, confining that mask to the alpha channel. This is then read in the shader as a single pixel-value, and the red, green, and blue channels carved up into four values each. These values are applied to a set of sine-functions that cause them to fade in and out.
The effect doesn't stand up to really close scrutiny, but I think that it looks rather good, overall. Take a look:
An animal sign, glimmering#ADoorToTheMists #gamedev #indiedev #indiegame pic.twitter.com/PIuxIqIDkh
— Ian Eborn (@EbornIan) May 25, 2017
On the technical side, I made a minor change to the player's lantern-light: it now shifts up and down a little with the vertical angle of the player's view: when the player looks up, it's held higher, and when the player looks down, it's held lower. I find that this makes it a little easier to see things a little above and below the player's position, both in terms of lighting the object and in terms of reducing problematic shadows.
Still on technical matters, I discovered a potentially-significant problem in the week just past: I leave gaps between the cells used for portal-culling. This means that an object placed in such a gap may be assigned to no cell. While the resultant lighting issues may be fixed by manually specifying the relevant light, this also means that such objects aren't affected by the portal-culling system.
I'm not yet sure of what to do about this--I've asked after the matter on the Panda3D forum, for now.
Returning to art, I reworked one of my "tiling stone" normal maps. For a while I had been somewhat dissatisfied with the look of certain stone surfaces, in particular the large slabs used in various parts of the tombs: they looked a little like they'd had camouflage paint applied to them, I think. In the week just past, I replaced these, and I'm rather happier with the new version, I believe!
Note that this new normal-map doesn't entirely replace the old: there are some places in which the old normal-map works well, I think.
Finally, as per usual, there were a number of minor changes not mentioned here.
That's all for this week--stay well, and thank you for reading! ^_^
Trackbacks
Trackback specific URI for this entry
No Trackbacks