biggreenpepper
DotA2’s Razor

Methodical Rigor II: Diving Deeper

In 2012, I broke down Valve’s rendering techniques. Five years later, I’m on an adventure to briefly peel back a few more layers.

Previous entries:
Methodical Rigor I: Revisiting Valve’s Game Design

 

In the second part of this series, we’ll be taking a look at Source 2, Valve’s pride and joy. What’s a game engine do, and why should we care?

 

Remember, you can’t see without light — it’s an important aspect to video games we take for granted. What’s the difference between baked and real-time?

 

Glance value’s been a perpetual discussion of visual design in DotA2. Is Valve losing their touch, or is there a balance that should exist?

 

In the beginning Valve created GoldSrc and Half-Life.

Source 2 is Valve’s current game engine. This is a term that is thrown around a lot, yet never really explored in-depth within the context of DotA2, or Valve in general. Tens of millions of people (not just gamers) around the world utilize Source 2 and have heard of Source Engine.

 

Much like how paintings need a canvas of some sort, games need a game engine. A game engine makes everything run properly and in an efficient manner — without it, developing a video game becomes substantially more difficult. A game engine allows for entities within a video game (or 3D space) to be created using software. Foundation-level stuff, such as the game’s world, NPCs, the like — anything rendered within a game. Like an engine to a car.

 

Starting in ’98 with GoldSrc for Half-Life, a heavily-modified Quake engine, game engines have been a very large part of Valve’s reputation and success within the industry. A little over half a decade later, Source Engine was released, and would change the industry with Half-Life 2.

 

Valve
Something so simple as water completely blew the entire gaming industry away.

 

Exceptional in-game physics and textures via heavy use of Euclidian vectors (think magic related to direction), facial animation that shocked players beyond belief, engaging gameplay, and next-level presentation — it was all there. Valve also tells stories through mediums other than writing — technical and calculated choreography creation, better known as scenes.

 

Remember, the physics middleware used in Source 1 was not developed by Valve; it was developed by Havok. Source 2’s Rubikon was developed by Valve.

 

Valve’s Source 2 engine broke ground in around ’11, with a stable release coming three years later, finally being announced in ’15. A more modular engine with heavy mod-support as always, what set itself apart from Source 1 was the idea of something we call baked vs. real-time. Nearly two decades after Half-Life’s release, the Quake engine’s influence is still evident in view vectors, a formal term directly relative to directionality. Things could be changed more easily with newer technology.

 

I reached out to a very respected mapmaker and Workshop creatorInvalid Nick, for his thoughts on Source 2 in general and some more technical details:

 

One of the reasons that Source [2] is so popular is because of the success of games that are made by it. Source modding, or Source game developers are a small number compared to say, Unity… and even if Source is old, there has been a few cool AAA-title games coming out such as Titanfall 2, etc.

 

From what I’ve seen in Source 2, it’s pretty different from Unity or Unreal, in the way that the tools are still focused around the level designer and hammer. When it was announced for DotA2, I was ecstatic and have used it ever since.

Tool-wise it is a complete reboot compared to Source [1], similar to how GoldSrc and Source [1] differs, retaining the good and dumping the bad.It’s a big investment from Valve, and I’m sure they will continue to build upon it.
While the updates for DotA2 have been minimal, they’ve gotten a lot of new stuff in the past six months. Their entire VR community is now in Source [2]. If CS:GO will ever be ported to Source 2, it will probably be from a Steam VR branch, or something similar. Source 2 will be a huge success, not because of the engine itself, but because of the games [developed on it].

In Source 1, everything was a room — outside environments were closed boxes with textures to give the illusion of being outside. Walls and ceilings made up the sky, and any holds within these textures while rendering would cause fault. Newfound tactics to prevent claustrophobic 3D space also came with Source 2. This was a huge advancement, considering Valve’s ambition, and assisted in improving the rate of content creation. No longer were users confined to limited spaces. As another friend said:

 

Outside areas aren’t closed within rooms; they are just infinite space.

 

With all new technology on hand (including moving away from BSP files and making it significantly easier for mapmakers and creators to import things), it was in the best interest of Valve to cater to its prized possession, DotA2, and give it a well-deserved facelift.

 

MapCore
This is how light is diffused within the Source 1 Engine.

Source 2: Baked, Real-Time, and Radiosity

Radiosity is a method where magic is injected into a computer using a crowbar, and out comes light, diffusely strewn about, resulting in a pretty looking surface mimicking real life physics and light paths (we hope).

 

Baked, relative to something that is cooked, is something set in stone or preset to a default value or extent in regards to the game engine. Real-time means things can change dynamically.

 

To put it simply, we’re bridging the gap between a statue (immobile, set in stone) and a human that can move freely (dynamic, no boundary).

 

In this case, three lightmaps were baked into Source 1, one for each axis, story different values to diffuse light across surfaces of in-game textures. Half-Life 2took advantage of this, and the results were extremely well-defined surfaces, despite sometimes having direction of light as an issue.

 

Source 1 did indeed have real-time rendering to an extent, though — the flashlight in Half-Life 2, among several other small instances, used projected textures (despite not being reflective) and is technically considered real-time rendering. However, in Source 1, radiosity fell short. In other words, the way light was treated improved significantly between Source 1 and Source 2.

 

Workshop
Baked textures.

 

The core idea of Radiosity Normal Mapping is the encoding of light maps in a novel basis which allows us to express directionality of incoming radiance, not just the total cosine weighted incident radiance, which is where most light mapping techniques stop.

 

Again, putting in extra work to get ahead of the industry. We have to remember these ideas were being employed and shown to the public nearly 15 years ago, when video games were not remotely close in comparable in-game physics or animations. It was something to highly revere and appreciate, while staring at as eye candy all at the same time.

 

The way that light hits objects is important when playing a video game, more than we realize. Why? Immersion, detail, and overall presentation of a video game’s design — the end product that a game developer is selling to the consumer. If details like this are flawed, the end product loses value.

 

Source 2 applies a hybrid balance between pre-calculated and truly dynamic lighting, which when simplified, means shadows are significantly more realistic than they were in Source 1. Remember: Valve’s OpenGL never was true OpenGL; they employed a wrapper which used a Direct X to OpenGL converter, somewhat of a lazy move to integrate compatibility.

 

For DotA2, interactive environments, moving players, NPCs and other objects within the Map’s landscape are shifting constantly. An improvement to real-time textures and rendering using new technology is a great addition to the overall game itself.

 

Workshop
Gabe Newell

Breaking Color Theory With Glance Value

This is very dependent on Source 2’s lighting and overall feel for visual design. It all ties together. Glance value is the technical term used to describe the identity of a character or object (in this case, a hero in DotA2) at first sight. It’s been memed and complained about by many people, and the complaints are justified.

 

No game is perfect, and DotA2 is no exception. Originally, the Workshop guide went on extensively about different types of shading and color sets used for heroes to go in line with color theory and different themes within the game.

 

We spoke about this last time, and although these are indeed highly praised aspects of the game and very technical and higher levels, sometimes the way Valve approaches the design of a character’s items (or approved items in the Workshop) completely breaks their philosophy and stance on this.

 

Remember this is not necessarily game-breaking, nor is it a massive issue within the community, but it is something worth talking about and recognizing for the sake of integrity. Many video game artists very carefully craft different pieces of gear and other in-game items to revolve around lore and support story-driven content.

 

World of Warcraft has also gotten heat for not necessarily staying true to class fantasy over the past few expansions. Fans have praised Legion however, the latest expansion pack to the series, for improving upon this flaw.

 

GameSpot
It actually fits…

 

There has to be a balance, however. We need to remember that it is difficult to vet items coming in from the Workshop and approve them for release and sale.

 

A solution to this may be a toggle system similar to World of Warcraft, where users can choose new updated models, or old original models. This also is able to remove glow effects in-game and particle effects, which could be implemented in a similar way to show just base heroes without any added gear while in-game with others.

 

GamePedia
Looks great, but… completely breaks the original design choice.

Take a request by reddit user everstillghost into consideration: the set mentioned completely changes the original hero, but for what reason?

 

This is subjective, but ties into the Workshop point. What should Valve do, only vet pieces that are in line with the color of the original hero? That seems a bit harsh, and a system to toggle sets like this, which are obtusely contrasting and confusing, would be a great alternative. Until something is implemented and efficiently integrated into the game, complaints will remain justified.

 

Methodical Rigor II: Diving Deeper