The evolving look of the game
Over the past week-and-change, I’ve been spending some time looking at MMORPG Tycoon 2’s rendering technology, and I’m getting ready to roll out a pretty major evolution of the game’s general appearance inside the MMORPG simulation itself.
Here’s a simple before and after shot; old shaders are on the left, new shaders are on the right. Drag the circular handle to compare the two.
There are several new things to talk about, here. First, the obvious thing; I’ve added shadows to our graphics.
Shadows are somewhat expensive to support for this game, but my seven-year-old computer can mostly handle them, so anybody who’s using newer hardware ought to be okay. (And my newer computers are positively bored by them) For those using old hardware, the shadows are completely optional, and can be disabled while the game is running, without a quit-and-relaunch cycle.
The problem with shadows is that in order to implement them, you need to render all the objects which are going to cast shadows multiple times; once per light that will cast a shadow, plus once for the final visible scene. In this game, I draw a lot, and most things cast shadows. In the picture below, for example, there are several hundred giant mushrooms visible. And if you look down at them from above, there can be tens of thousands of them, all casting shadows.
The other big change to the game’s look is to how light is handled. Previously, we were using a very primitive lighting model, akin to what was being used in 3D games from the late 1990s. Effectively, it was just simple Gouraud shading, sometimes called “smooth shading”. I didn’t even use specular highlights on the vast majority of models. In my mind, the game’s look was partly inspired by the look of Proteus, with a few tricks inspired by Love (which I’ve never actually played; I should really do that someday).
With the addition of shadows, though, the game began to have a much higher contrast, and I started to wonder if I should really stick with the whole “mostly flat, bright colors” aesthetic I’d been using so far; that maybe it was time to move on to rendering technology that wasn’t twenty years old.
I should mention here that I’ve never really been a “graphics coder”. I worked in the mainstream games industry for about sixteen years, but I was always a “gameplay programmer”. My experience is in cameras, and player control, and animation technology, and game feel; there was always somebody else to handle the rendering issues. But I finally decided that it was something I should really learn more about. So after much research on the internet and pestering of graphics-programmer-specialist ex-colleagues of mine, I finally took a stab at Physically-Based Rendering (PBR, for short).
It’s actually not as scary as the acronyms make it sound, and you’re soon BRDFing with the best of them (Bidirectional Reflectance Distribution).
And since MMORPG Tycoon 2 is a game about a fictitious, simulated world, I don’t need to feel tied down too much to “realism”. So the lighting calculations are doing just enough work now to make everything feel a bit more “present” in the world, without losing the color or becoming a slave to how light bounces in the real world.
I’m pretty pleased with how this is coming out!