Nov 27, 2015

Suzy Cube Update: Friday November 27, 2015

#suzycube #gamedev #indiedev #madewithunity 

One more level draft in the can and another well under way! After a slow and self loathing start to the week, I managed to kick myself in the butt and end things in a good place.

Getting Pretty Buzzed

So, first of all, I completed the first draft pass of Level 1-3, now with fun bee enemies!

That stings!

I think the level has come together well. Well enough to move on for the moment anyway!

Misty Forest Hike

At the top of the post, you can see a screen shot of another early level in the game, Level 1-2. This is all part of getting the game show ready in time for the Game Developer Conference in San Francisco next March. I want to get the first world of the game done and looking polished up to show it off to folks at the conference without constantly having to explain that "this level is just a stub..." or "that level hasn't been tested yet..." By giving the game's first world the "release-ready" treatment, I can confidently hand the game over to press with the simple caveat that "I'm not ready to show levels beyond World 1 at this time..."

Like Being Lost in the Fog

So, I'm a little surprised to be showing off a cute little bit of time saving tech today as I really wasn't planning to do so! Just this morning something occurred to me: I can save myself some tedious work down the road with a little bit of work right now.

So, in the top screenshot, you can see how the trees seem to recede into the fog. This is a combination of three simple techniques working together, the camera background colour, the scene fog and my custom gradient objects. Here are each of these elements recoloured in red.

Camera background colour

The camera background colour is simply that, it's the colour drawn to the screen when there is no other geometry to be drawn.

Scene fog colour

The scene fog has the effect of tinting objects as they get farther away from the camera, giving the impression that they are disappearing into a distant fog.

Custom gradient objects

And, finally, I created a set of gradient objects that I am using, here, to tint only the bottoms of the tree trunks, giving the impression that they are sinking into a low hanging fog.

When you put them all together you get a nice misty effect.

All three combined

As you can see, the effect is only convincing as long as the three elements share the exact same colour. Well, that's where the nice little piece of code comes in. In short, all it does is force the scene fog and gradient object colour to match the camera background colour when the level is loaded. For the custom gradients, I simply created a new material called "Shared_Fog_Gradient" which I can now use whenever I want to make a gradient object match the background colour. Easy!

I've mentioned it before, but since I'm working on my own, little time savers like this are really worth their weight in gold in the long run! And, I've basically just made it three times more likely that I'll bother no tweak a level's background colour to get it just right as now all I need to tweak is ONE colour!

Next week, I should have the draft for Level 1-2 done and be started on Level 1-4... Or maybe the World 1 boss level? Check back in next week to find out!

No comments:

Post a Comment