🎉 Celebrating 25 Years of GameDev.net! 🎉

Not many can claim 25 years on the Internet! Join us in celebrating this milestone. Learn more about our history, and thank you for being a part of our community!

Weekly Updates #31 - Reflections

Published February 09, 2019
Advertisement

Hi there! This is yet another blog in your favourite weekly updates!

This time there's only two new big features along with a big internal refractory and what not, so let's get right to it!

Crystals Reloaded

In our design document, we wanted to have crystals. These crystals were going to be used as tools to pass certain obstacles.

However, after a bit of thinking, it was clear that this mechanic wouldn't work, as it was really situational and didn't make sense outside of these situations...

So a brainstorming was in session, and one of the most attractive ideas was to use these crystals as persistent currency. With it, the player could buy things like boost packs and unlock many different relics to be available in runs (much like Enter the Gungeon). I even could fit my Temple and Pawnshop rooms as these heavily used crystals to function (the first trades crystals for health while the latter trades crystals for actual money).

The first step of doing this was to scrap every script related to crystals, which was really easy. Then, it was a matter of choosing a colour and maybe a ruleset on how these would be obtained.

Because I've previously used an iridescent shader I decided to reuse this to shade the crystals, which is pretty good if you ask me

image.thumb.png.4eb985e2ee2640929f070482d79fc7fd.png 

Next up was to set up conditions on how these would spawn, which was also a no-brainer.

The idea is that if the player clears the level perfectly (i.e. without taking any damage) then once the boss was killed a random amount of crystals would spawn.

But that wasn't enough.

I wanted to reward the player for looking around and being actually aware of its surroundings. To do so I've decided to use a similar mechanic of that of The Binding Of Isaac, which is to have certain props marked with some type of visual effect which would indicate special loots is inside

latest?cb=20111022205409

If the player is lucky then there's a chance one of the rooms destroyable prop will be marked as so. However, it needed to be a subtle effect, as a too flashy one would be too obvious and could potentially distract players.

After toying around with ideas (like making props darker and whatnot) I've decided to instead mix a normal shader with that iridescent shader I've made.

The result is actually quite good.

image.thumb.png.a917ac4412571bf6bcc7c248c07dcff3.png

When the player breaks one of these a random amount of crystals will spawn out of these. So you better look out and get some of those sweet sweet crystals...

Reflections

Another big update is actually related to reflection (probes).

I've previously mentioned that I always had problems with building reflection probe, as switching their enable/disable state would actually clear their buffer. I've then decided to put those probes outside the room geometries and keep those probes active. 

While doing this I've also thought that I could also use probes in regular rooms, which would be really interesting.

But there was one big hurdle to jump over. Because I've followed this tutorial then most of my geometries were generated at once. There's literally no concepts of rooms, which made using reflection probes almost futile.

That's because when a model overlaps two or more reflection probe then these would blend. Thus, if a model spans multiple probes (such as the models used in the tutorial) then it would literally be just a blurry mess that doesn't nicely represent the room.

To fix this I've decided to split all geometries so that they're put in their respective rooms.

After doing this it made room seems much more plausible and also altered most of my specular colours here and there too.

Take a look at this ice: 

image.thumb.png.ee1367121284553a37ba15b2f692e89b.png

It can really look good and makes the room feel more present and coherent altogether.

Another plus is that now that each geometry is split per room I could technically hide the geometries of hidden rooms much more easily, meaning more optimization of me!

Also, when I'm ready, I could also implement some type of dynamic occlusion which would save me even more memory. But that's for another day...

Minor Updates

  • There's a major refactory
    • Most of the repo's structure was reworked, meaning a more clean and organized one.
    • There was a lot of class hierarchy refactories, which made some scripts lighter and removed a lot of duplicated code too.
    • Because of this, there was also a lot of bugs that were consequently fixed.
      • We're talking really dumb ones like typo and such.
  • Optimized some shaders.
  • Fixed a bug with the skybox shader not showing the right sun colour in reflection probes

Next Week

I'm currently in the process of preparing some kind of demo, so it's gonna be refactoring, bugfixes and minor updates all the way.

There might also be some new features here and there but nothing big.

Otherwise, it's the usual suspects again.

2 likes 0 comments

Comments

Nobody has left a comment. You can be the first!
You must log in to join the conversation.
Don't have a GameDev.net account? Sign up!
Profile
Author
Advertisement
Advertisement