Showcasing new Northlight technology in Alan Wake 2
The Northlight team is super-excited to have Alan Wake 2 out there. We've created and polished off a lot of new tech so that Alan Wake 2 looks great and plays great. Here are the key highlights of the new features and tools that we'd like to give a moment in the spotlight. We're keeping the description to a fairly high level here; our engineers will be back with more in-depth topics in due course.
Northlight switched to a completely new data-oriented game object framework during the development of Alan Wake 2. The new entity component system (ECS) based model enables memory-efficient storage and makes parallel execution efficient and safe. This means that the engine can support a varying number of target hardware cores efficiently, enabling bigger, more dynamic and fuller worlds. ECS also played a supporting role for our tools development, simplifying the building of the new Scattering tool for mass-authoring vegetation - ECS allowed us to simply have a lot more entities without the need to invent any custom solution for scattering objects in the world.
The ECS framework also made it to our gameplay programmers' "favorite tech" list as it helped implement the Case Board - Saga's visual storyboard for gathering evidence. ECS meant that iteration was quick because adding new or modifying existing systems or game objects was easy, and performance gains were clear when saving and loading the Case Board.
Alan Wake 2 called forth reimagining character control in Northlight. We built a new Voxel-Based Character Control that enables smooth navigation in cramped, complex and dynamic environments; it makes character movement more natural and fluid. Our marketing folks would say the characters are more responsive and lifelike than ever before; our internal dev notes described it as "the characters won't bump or get stuck into objects in tight spaces".
Our animation tech made some major changes into how Non-Player Characters (NPC) move. The revamped NPC locomotion means that in Alan Wake 2 all NPCs utilize animation-driven movement combined with new distance-based Motion Matching. This new tech improves movement quality and gives us more control over how and when animations are used.
More realistic wind was on the must-have tech list for Alan Wake 2 - and that's we have, wind that realistically affects physics, particles, and cloth.
For example, game designers can now easily define indoor and outdoor areas that have different wind speeds, with smooth, stateless transitions between the two types of areas. The indoor vs. outdoor area definitions are used, for example, to ensure that there's no wind inside the car that Saga and Casey are driving. This is done through defining a moving "wind box" that specifies that the inside of the car is a wind-free indoor area.
The wind system tech is built on Signed Distance Fields (SDF) methods where wind boxes are used as primitives that define a smooth, global wind strength field. The wind boxes act like basic building blocks that define how strong the wind is in different areas, creating realistic and smoothly varying wind patterns between indoor and outdoor areas.
We developed a new Scattering tool to allow for mass-authoring vegetation and propping environments on a grand scale. In Alan Wake 2 it was used to create denser, richer and more life-like environments with the longer-than-before draw distances (i.e. what defines how far the player can see objects and details in the game world).
We switched our scripting language from a proprietary language into Luau, embeddable scripting language derived from Lua by our friends at Roblox. It exposes a comprehensive set of engine functionality and supports live-editing. Luau is used for level scripting and also for various gameplay systems such as the weapon upgrade system. Luau allowed the game team to prototype and implement various game features and VFX effects without needing help from engine programmers.
We've also cooked up our own VS Code language server extension, so that it all integrates seamlessly into Remedy’s development pipelines. And adopting Luau helped us boot out some 80 000 lines of code we no longer need to maintain.
Alan Wake 2 showcases Northlight's brand-new GPU-driven rendering pipeline. It allows us to push more geometry into the world without sacrificing performance. With GPU-driven rendering using mesh shaders, we can now do occlusion culling down to a single-pixel precision and use everything in a scene as an occluder. This ability to only draw what is visible means that the world of AW2 has more geometric detail than we’ve ever shipped before.
Diving a bit deeper into how it works: we also cull meshlets, in addition to the mesh. Meshlets are smaller, more optimized, groups of triangles extracted from the mesh. In the images below you can see what meshlets look like around Cauldron Lake's convenience store location.
The expansive primordial forest environments of Alan Wake 2 are brought to life through our new shader-based vegetation system. It's based on a new skinning system that runs entirely on GPU and supports "art-driven" bone shader animations. In Alan Wake 2 it enabled us to use full character-style rigs on all the foliage visible in the environments.
We're calling the new system art-driven here because the bone shaders expose an API with which artists can write their own shader code that hooks into the underlying system. So technically artists could use it to animate anything they'd like: foliage, objects bobbing up and down on water, power cables wobbling in the wind, etc.
Alan Wake 2 fully supports HDR. We've made sure that the game looks great out-of-the-box with default settings, regardless of whether your display supports SDR or HDR.
On the tech side, adding HDR support was about taking on a new paradigm on how to do tonemapping. Very significant effort was done also on the creative side. Alan Wake 2 is authored in HDR, meaning that the color grading was done by actual human colorists to ensure that the unique art styles and aesthetics, the storytelling and mood of Alan Wake 2 is amplified in both HDR and SDR.
The pervasive fog scenes in Alan Wake 2 are built upon improvements into how we render transparency. We're using MBOIT (Moment-Based Order-Independent Transparency) to make see-through surfaces blend together smoothly, even when they have different levels of detail.
During Alan Wake 2's development, Northlight did a complete overhaul of transparent rendering. We now draw transparency in three resolutions with MBOIT, which makes it possible to blend fog, transparent geometry and effects seamlessly. In addition to better blending of fog and other transparent elements, we’ve improved pipelines to allow more fine-grained control over fog placement in the world. Combining all this to per-pixel transparent lighting and fog-affected reflections makes opaque and transparent elements fit together better than in our previous projects.
Our fog also approximates multiple light scattering, giving it a thick and realistic look that improves atmosphere.
Effects are an essential part of Alan Wake 2’s visuals and expand on what we achieved in Control. The node-based VFX tools in Northlight have evolved significantly in terms of supported features and runtime performance. Visual effects artists are now able to author complex and dynamic effects like rain, wetness, water simulation, and character wounds. VFX tools also benefit from GPU-driven rendering and can push a lot of geometry through the GPU. This is required, for example, when rendering rain blocker objects to a dynamic mask that prevents rain from appearing indoors or under cover.
We have added support for fully ray-traced direct lighting and combined this with improved denoising and indirect lighting algorithms with Nvidia. Ray tracing in Alan Wake 2 is more accurate and robust than what has been seen in Control. Ray tracing also makes the animated foliage look amazing, now that all the geometry animation (foliage) is authored and simulated using skinning.
With Alan Wake 2, PC players can experience (GPU and CPU setup permitting) the latest Nvidia DLSS innovations - DLSS Frame Generation, DLSS Ray Reconstruction, Path Traced Indirect Lighting - all the things that enable us to say 'never before' once more.