Terminus for Half-Life 2: Episode 2
The prompt from Planet Phillip was simple: a single-player assassination mission against a designated target, built using the Half-Life 2: Episode 2 version of Valve's Source engine. The time limit: 10 days. This is the brief story of how I had some really good ideas and had time for almost none of them.
Design Experiments
Some backstory: having played the Half-Life games since the first release, I have generally been more comfortable with the movement and physics of the GoldSrc and Source engines more than any other. Until Dishonored.
Dishonored in the Source engine
Running rampant through the city of Dunwall could only be described as liberating. Upon first playing it, I was immediately taken by the gloriously simple freedom of movement offered by Arkane's stealthy magic n' murder sim, especially vertically. The basic ability to climb up onto things was immensely satisfying, with particular regard to how it facilitate stealth, hiding just out of sight above or below enemies' line of sight. It's a style that the Half-Life games have occasionally toyed with -- the junkyard in Episode 2 being a notable example -- though admittedly in a hyper-controlled fashion. To me, the most pressing question now was whether a Dishonored-style stealth assassination mission could be made within Half-Life 2.
Endless Impossibilities
I jotted down a long-list of ideas for Dishonored-style mechanics: multiple paths, striders as tallboys, combine energy walls as Walls of Light, NPC patrols, spotlights, multiple ways to kill the target. Some could be fun to attempt and play against. Others were likely impossible given the limitations of the code base. Others were simply unwise due to how they would run contrary to established mechanics, such as having combine energy walls deal damage when they never had before.
Step One was to become familiar with the limitations of the Half-Life engine, particularly with regard to AI and stealth. These were significant: Combine soldiers' horizontal field of vision is a whopping 204 degrees. Their vertical field of vision is effectively 360 degrees. They can see up to 128 feet away. They can instantly notify other Combine of the player's presence. They pay no mind to the ambient light level, seeing perfectly well in both lightness and darkness. They are, it turns out, really damn perceptive.
It is possible to make volumes in which the player is "hidden" using a Block NPC Line of Sight texture. Simply placing the volume under a desk, for example, would create a place that the player could crouch without being spotted by enemies. Unfortunately, I was unable to find an effective way to turn it on or off depending on whether the player has been spotted. Even in direct combat, the player would simply disappear from the enemy view.
So hiding in the shadows was out, as was hiding just out of sight -- under desks below eye level, on rafters above eye level, etc. There was some small degree of stealth possible by smart positioning of fixed guards, having them facing away from where the player was likely to approach from. While AI can “hear” in the Source Engine, I was unable to determine specifics such as whether different weapons are louder and more audible than others. Executing idle combine soldiers from behind with a single pistol shot to the head was often enough to take them down without drawing additional attention. Stealth was not Stealth-Lite.
The Coast
Selected a setting was mostly a matter of rejecting possibilities: I knew that I didn't want to try depicting a location not seen in the Half-Life saga, as I preferred to have the full library of existing assets at my disposal. I knew that I did not want to set the mission within the canals, or City 17 at all, or Ravenholm, or Nova Prospekt, or the Citadel. I was torn between the coast and white forest area, eventually deciding on the former in order to make use of water as a simple boundary. It offered a nice variety as well -- sand, grass, rock, old wooden buildings and old plaster buildings. It also provided an opportunity to become more comfortable with displacements by forcing myself to construct an environment comprised largely of realistic landforms, in contrast to the flat, geometric urban sprawl that I had built for my Left 4 Dead 2 campaign.
The Return of Sandtraps
I also decided that Antlion Sand needed to make a comeback. In a game full of memorable moments and experiences, that sequence in Half-Life 2 was always an engaging and refreshing change of pace from normal combat. There was no need to try anything as daunting as Valve's expansive, debris-strewn beach, but I saw great potential for it to be used as an alternative route towards the target -- safer from combine, but still challenging.
Initially, the energy walls were to be completely impassable, a way of forcing players to find alternate routes. Similarly, the main entrance to the destination building would be forever sealed. In an effort to add some small degree of complexity to what is a fairly open environment, the doors and walls were connected to combine generators that could be turned on or off. This concept needed to be introduced to the player, so the introductory energy wall was added to the bridge. It's direct, unsubtle, and awkward, but time did not permit improving it.
The Clock, And Racing Against It
This was my first experience participating in a timed mapping competition, and as such forced upon me a new and terrifying demand for focus and recklessness in the face of a looming deadline. As a frustrated perfectionist, it was quite difficult to have almost no time to rework sections of the level. Very quickly, triage becomes necessary. Many alternate routes around the environment were left unfinished, or skipped before they were even attempted. Even much of the remaining level is off slightly, with some areas the wrong shape, or the wrong dimensions. Not quite right. Many issues with AI linger. There are bugs. Oh so many bugs.
As fewer and fewer days remained, I was able to formulate a reasonable timeline for final passes of the map. The final gunship battle (which became necessary when successfully killing the target was deemed too anticlimactic) was added perhaps three days out from the contest deadline. The ambient soundscapes were added a little over two days from the end. The reflective cubemap points were added shortly thereafter. The AI navigation paths were added in the last 8 hours. The skybox was created within the last two. All throughout, various AI, gameplay, and visual bugs were resolved as rapidly as possible.
I still wish I could have done more, but it was a personal victory to do as much as I did within the time frame.
Stray Thoughts
Rather than being placed atop the combine tower, the rocket cache should have been inside the final coastal building, a floor or two below, where the player would pass by (and hopefully notice it) on the way up to the target.
Lessons Learned
- Introduction to basic Half-Life 2 AI and pathfinding
- Prioritization on a tight deadline
- Further experience with Source displacement terrain