Home > Blog >

Wall Worm, the Angry Teapot and the Art of Xen

Posted Jun 5, 2016
Last Updated Jun 5, 2016
Angry Teapot

For years they said it couldn't be done... and now a couple of talented young guys proved them wrong. Yes, you can make a level for Source entirely inside 3ds Max: Mathias Solheim and Devin Ulrich proved that when they won the Old School Level Design Contest, claiming the first ever Angry Teapot Awards (this name was slapped onto the competition awards after it was completed).

To be fair, others have made levels inside Max before now, including Joris Ceoen and myself (and possibly other closet Worms). But this was the first contest that I know of where designers were tasked with making visually interesting maps for Source while being limited to only world geometry and not allowed to use Hammer.

Devin's map gg_futurelobby won with pristine visuals. Mathias came in a close second with bright creativity in fy_delaunay_world—pushing the limits of Source brushes in many ways (see his write-up on making it here). Not only did they win the honor of being the first winners of the Angry Teapot Awards, but they also won a bunch of really amazing software from some of the coolest plugin developers in the world: GrowFX, enRichPro, Zookeeper and more.

With that contest down, another one is here. But that's later in this post.

The Art of Xen

Wall Worm is now playing an important role in the final phase of Black Mesa. Thanks to Black Mesa, a ton of new development has come to Wall Worm since late 2015. And that keeps on going.

There are many things about Black Mesa that I didn't know until I started working on the project. The two things I've learned about the Black Mesa community is that it is a large, positive community of fans, players and artists; and that above all else, they want Xen—the alien world Gordon Freeman visits at the end of the game.

I cannot really discuss the details of what is coming for Xen, but I can share some insight on a little bit of the work going on that will explain where things are headed.

Painting something exotic and stunning onto the canvas of everyone's nostalgia is no small matter—especially when nostalgia may paint its own twist on our memories. I personally hadn't played Half-Life 1 for fifteen years when I came on-board with Black Mesa—and when I did I was surprised with how much I still enjoyed the original game but shocked with how poor the original graphics are. It wasn't exactly the game I remembered, to put it nicely. The art was not poor for its time... but of course it doesn't live up to today's standards.

Black Mesa isn't exactly Half Life—although for some of the older members on the team the development may seem like it's taken half their lives. Of course the graphics are much better. But there is more to it, including new twists and turns. Certainly, the Black Mesa Compound (where most of the game takes place) now feels more like real place than it did in HL1. And that is part of where Xen is being driven—it has to feel more alive and visceral than the original.

One of the things that has impressed me with the Black Mesa team is the high level of passion and dedication that drives the great talent. The team leaders have set some very high standards for the final phase of Black Mesa and Xen. The modelers have been creating some beautiful props and the level designers have been compositing a world that I can't wait for everyone to explore.

One of the big updates that came to Black Mesa publicly came with a content update recently with the remake of the Surface Tension chapter. Aside from the added new game play, there was a new feature added into Black Mesa by the programmers—cascading shadow maps (CSM). The level designers were lusting over it since long before I came on board; historically, a lack of CSM has been one of the reasons why Source Engine games often have poor lighting. CSGO has CSM, which is one of the factors in making CSGO so beautiful. And now Black Mesa does too.

Surface Tension Uncut

CSM was critical for the polish of Black Mesa and the art standards of Xen.

So as a little treat for the Wall Worm users, I asked Chetan Jaggi to answer some questions about the development of CSM. Chetan, along with Mark Abent, were the principal programmers who implemented CSM into Black Mesa. Chetan took some time to answer the following questions:

Why do we need shadows in Game ?
Shadows are one of the most important aspects of making a virtual scene look realistic and making games more immersive. They provide key details of object placements in the virtual world and can be pretty crucial to gameplay as well.

For example, it plays an important role in Counter-Strike by allowing us to see enemies around corners, coming through doors, etc.

Why was CSM important?
The Source Engine (at least the version of the engine we have) doesn't have a high-quality shadows system that works flawlessly on both static and dynamic objects. Even the static shadows from the VRAD aren't that great unless we use some crazy high resolutions for light maps which greatly increases both the compile times and the map size. And shadows on models just doesn't work properly since they are all vertex lit. So we needed some sort of dynamic and a very high quality shadow system, which is something very common nowadays in any real-time rendering application or game.

One of the most popular ways of implementing shadows is through shadow mapping algorithm. CSM or Cascaded Shadow Maps is the further extension of the algorithm  to generate high-quality shadows avoiding aliasing artifacts and other limitations of vanilla shadow mapping. For more details check this.

What was the challenge to implementing it?
First of all the Shader explosion was a big hurdle for us. According to our estimates, if we would have done things in traditional forward rendering way it would have taken 20+ days to compile one set of the shaders (on cloud with 24 core system and 128 gigs of ram) and if you encounter a bug, the whole process would have to start over. I tackled this problem by implementing shadows in a deferred way which decoupled the shadow sampling pass from the core shaders, reducing both shader complexity and instruction count in the core shaders.

Anything interesting you learned/experienced while working on it.
Before I joined this project I thought I knew Source, but I was being so naive. On the code side messing around with some weapons, adding a few entities or modifying some UI during free time in college days doesn't count as experience for this kind of job.

I have learned a lot about the Source Engine at the core level in past few months; I now understand the love-n-hate relationship developers have with this engine.

To implement something like CSM you need to know the engine inside out, you need to be familiar with all the core parts of the engine. I learned as I implemented parts of CSM, often fighting the engine. Figuring out good ways to pass data along the pipeline without breaking stuff dealing with the limitations and bugs, etc. Fun fact: all objects go through 3 different coordinate systems and/or matrix conversions before being rendered on the screen. I spent a lot of time debugging code base finding out many of these fun facts.

But it was all worth it!

As I said before taking on this task, it doesn't matter how difficult it will be to do shadows in this game because what's the point of spending so much time and effort learning all this game development stuff if I can't even use it to improve Half-Life? The game that inspired me to get into game development.

The work the programmers and artists are putting into Black Mesa is really exciting. And there is a lot of love, passion and talent pouring into bringing Xen to life in a way that pays dutiful respect to us older gamers while making the levels relevant and exciting for new players.

Wall Worm Development

As noted, a good portion of the development in Wall Worm has been driven by some of the needs in Black Mesa. Among the main new changes have been enhancements with the pipeline when working with mixed DCC applications (not all of the artists at Black Mesa use 3ds Max). The function that will make the most WW users happy is that scale is no longer a problem with exporting models—which we had to solve because FBX files generated in Maya or Blender might not come in with zero scaling. So you won't need to Reset Xform every time you scale a model.

There are other tools too. In the last newsletter I shared the Bitmaps to Materials function. That tool has been expanded with a new Blend Map generator that creates shaders inside 3ds Max that replicates triplanar mapping. This is convenient for making procedural materials that utilize 2D bitmaps without needing to add a bunch of UV modifiers to your objects. That tool plays heavily into a new plugin I'm releasing soon called Rocky.

Video: Blended Mapping Workflow

Another new addition in Wall Worm is a tool that works kind of like Propper (which I've never actually used but know all about). For ease in converting some of the levels in Surface Tension into models for 3d skybox models, Black Mesa wanted a tool to do this. So now there is a tool called Convert Scene to Model that will collapse and optimize a scene imported via VMF into one or more models (yet another goodie that Black Mesa has offered to the modding communities via Wall Worm).

The last new change I want to mention is that Displacements in Wall Worm were recently overhauled. The changes made in the displacement system increased performance massively. However, these changes also made displacements incompatible with being quadrified—so although you now can create and commit sculpt meshes far faster than ever before, you must be careful to never use the Quadrify function in the Graphite Toolbar on any displacement or sculpt mesh—or you will break that displacement completely.

There are more new features and tweaks, but you can go to the forums or changelog to see all of those. But here are a few videos relating to some new features or old features that were never well-documented.

Video: Wall Worm Basics

Video: Using Hull Helper

Video: Dynamic Material Generation

Angry Teapot will Make You Happy

At the beginning of this post I mentioned the first ever Angry Teapot Awards which were hosted by Wall Worm and sponsored by several other awesome plugin developers. To my great excitement, all of the original sponsors have committed to the next contest—and even more have signed on. Visit Angry Teapot to see the list of sponsors and prizes.

The first contest was specifically limited to brush geometry. That was a calculated limitation to dispel some myths about 3ds Max, Wall Worm and Source. The next contest will not be limited in that fashion. In fact, the name of the next contest is Something Beautiful. Your main goal is to make something that shocks people with how beautiful the level is. There are very few rules, but they are located on the contest thread. If you want to participate, announce yourself on that thread.

The prizes for this contest are amazing. The top three winners will win software—and the first place will win over $2K in commercial licenses! I'm very honored that these other developers have joined in on this adventure. As part of the chance to win, one of the submission requirements is that designers must use the demo version of any software offered by the sponsors (provided the software has a demo version available) to create at least one element of your submission. This gives the sponsors some added exposure while introducing you to some of the tools that you may not otherwise have known about.

So what are you waiting for? Update Wall Worm, fire up Max, and start making something beautiful!

Newsletter Subscription