跳到主要内容
Work

Insomnia – Spriggan (Full-time Team Project)

Unity HDRP
Scene & Environment
Shader Graph & Tools

Technical art work from the Unity 6 HDRP team project Spriggan, covering vegetation and terrain integration, dynamic lighting and weather tests, Shader Graph effects, rendering issue investigation, and small tools for asset review.

In-game screenshot of a knight standing in a forest scene with dynamic lighting and volumetric fog.

1. Terrain Ecology & Procedural Pipeline (June)

Ecological Data Conversion: Implemented a data conversion workflow to map vegetation generation rules from Gaia Biomes to Storm FeatureSets, enabling automated, community-based vegetation distribution.

Unity Editor View: Gaia Ecological Mask mapped to Storm Vegetation Distribution
Ecological Data After Conversion

Hybrid Modification Strategy: Formulated a “Procedural Generation + Manual Tuning” hybrid workflow. While leveraging procedural generation to ensure ecological diversity and density, I coordinated with level designers to clear or adjust vegetation in specific areas based on gameplay requirements (e.g., pathways, combat zones, monster spawn points).

Game Scene: Procedural vegetation clearing for gameplay pathways
Hybrid Modification: Gameplay Area Clearing

2. Asset Integration & Shader Compatibility (Early July)

Core Contribution: Integrated Storm texture blending with the project’s existing Boxophobic and HDRP/Lit assets in the documented setup.

Shader Merging (HLSL/Graph): Manually merged Storm’s Texture-Based Blending logic into the project’s original Boxophobic and HDRP/Lit Shaders so art assets could use terrain blending while retaining their existing material setup in the documented project.

Shader Graph Logic: Merging Storm Texture Blending Vegetation and ground transition after terrain-blending integration
Shader Merging & Texture Blending
Main Pass: High Fidelity Vegetation Model

Texture-Based LOD (Vegetation Fallback Strategy):

  • The Problem: Distant vegetation (grass/trees) is culled due to LOD strategies, revealing the bare dirt texture of the terrain and causing obvious “visual popping” or bald spots.
  • Approach: Configured a Texture-Based LOD system using Top-down Capture. By baking the vegetation’s color distribution and mapping it to the terrain’s Global Color Map, the terrain texture inherits related vegetation color.
  • Observed result: When physical vegetation meshes are culled, the global color map reduces visible bare patches in the documented views. This page does not include a stable before/after timing baseline.
Top-down Capture Process Demonstration Distant terrain and nearby vegetation after global color-map setup
Texture-Based LOD Strategy

3. Shadow-Pass Setup and Inspection (Late July)

Split Shadow Rendering: Enabled Storm’s Split Shadow Rendering strategy.

  • Technical rationale: The Shadow Pass and Main Pass were sharing high-poly LODs in the initial setup.
  • Action and evidence: Configured vegetation to use ultra-low-poly proxies in the Shadow Pass, then compared the main and shadow passes in Frame Debugger. The project record does not preserve a stable frame-time or Draw Call baseline, so this section documents the implementation and inspection rather than a quantified performance result.
Geometry Comparison: High Poly Main vs. Low Poly Shadow Caster
Frame Debugger comparison: split-shadow setup

4. AI Analysis & Gamescom (August - September)

AI Tuning: Adjusted sensory detection parameters for pack animals (wolves/deer) and tested their group behavior in the project.

Gamescom Exhibition: Assisted the team in exhibiting the demo at Gamescom 2025. I helped construct the team booth and coordinate sub-leased space for other indie developers.

Team Insomnia Group Photo at Gamescom Booth
Team Insomnia at Gamescom Booth

5. Lighting Tests: Lightmaps, APV, and SSGI (October)

Benchmark & Gap Analysis

Initial Attempt: Early in the project, I attempted a “fully-baked” approach—a hybrid pipeline using Baked Lightmaps + APV.

Empirical Evidence: Even with Lightmaps, the visual fidelity fell far short of the Unity official demo Book of the Dead (BotD).

Reference: Unity Book of the Dead Forest Scene
Benchmark Target: Book of the Dead
Early Spriggan Lightmap approach screenshot
Initial Attempt: Spriggan (Flat lighting, lack of depth)

Root Cause Analysis: Lightmaps were not the core solution to the visual gap. BotD’s visual impact comes from a “Trinity” of spatial construction and refined material response, which were missing in my initial attempt:

  1. Occlusion: Lacked strong micro-occlusion; objects felt like they were “floating” on the terrain.
  2. Reflection: Lacked a “deliberately designed” reflection volume placement, failing to render the “oily/waxy” specular quality of leaves and wet rocks seen in BotD.
  3. Volumetric Fog: Fog failed to carry lighting information, unable to extend light/shadow relationships from “surface” to “volume.”
  4. Material Response (SSS): Vegetation materials looked too “plastic.”

Material adjustment (SSS): Adjusted the Diffusion Profile and Normal Intensity, then compared the vegetation response in scene.

Vegetation Material after SSS Fix: Enhanced Translucency

After comparing the approaches, I moved this project setup from Lightmaps toward a dynamic combination of APV, SSGI, reflection data, and volumetric fog.

Dynamic Lighting Setup: SSGI & APV

Challenge (Light Leaking): After switching to Adaptive Probe Volumes (APV) for fully dynamic lighting, pure APV solutions in indoor scenes suffered from low-frequency light leaking and noise due to insufficient sampling precision.

Indoor Light Leaking and Noise in Pure APV setup
Artifacts: APV Low-frequency Light Leaking

Strategy (Dual Complementary): I introduced SSGI as a screen-space detail layer and tested it alongside APV’s lower-frequency lighting data. The setup also used Unity’s fallback mechanism for information that SSGI could not provide off-screen.

(Unity Doc): “Because Adaptive Probe Volumes can cover a whole scene, screen space effects can fall back to Light Probes to get lighting data from GameObjects that are off-screen or occluded.”

Observed result: In the documented test scene, SSGI reduced visible low-frequency artifacts and added screen-space occlusion detail. APV remained the fallback when SSGI tracing missed or went off-screen.

With SSGI Enabled: Smoothed artifacts, enhanced micro-occlusion
Solution: SSGI Smoothing + APV Fallback

Reflection Strategy (“Subtraction” Logic)

Addressing the “lack of designed reflections,” I did not blindly increase probe density. Instead, I followed the documentation’s logic to “subtract”:

(Unity Doc): “Unity can use the data in Adaptive Probe Volumes to adjust lighting from Reflection Probes so it more closely matches the local environment…”

Configuration: I reduced the number of Reflection Probes and tested a Global Probe with APV correction data (Normalization/Occlusion). In the recorded forest views, this produced a more locally consistent reflection response. This page does not claim a project-wide performance gain.

APV-Guided Reflection Occlusion

Atmospheric Synergy: High-Precision Volumetric Fog

To fix the “ineffective Volumetric Fog,” I used Gaia to identify locations near water sources, at terrain curve valleys, and within forests to procedurally spawn a large number of Local Fog Volumes.

Gaia Procedural Generation: Local Fog Volume Distribution
Procedural Placement of Local Fog Volumes

(Unity Doc): “If you use volumetric fog, the per-pixel probe selection provides more accurate lighting for the variations in a fog mass.”

Visual comparison: The combination moved the documented forest views closer to the Book of the Dead reference in lighting depth, fog response, and wet-surface highlights. This is a visual comparison, not a claim of equivalent project-wide fidelity.

Final Look: Comparison against the “Book of the Dead” reference

6. Deep Debugging & Workflow Support (January 2026)

Project Pivot & Refactoring: During this period, the project underwent core personnel changes and a 1.5-month hiatus. I participated in code and asset handovers, legacy code and scene cleanup, multiplayer-module removal, and core gameplay-loop restructuring.

Pipeline Blockers & Engine Limitations: During multi-terrain tile loading, objects drifted into incorrect chunks and Play Mode initialization exceeded 30 minutes in the observed project setup.

  • Action: Following team discussions, I applied a single-scene, single-tile fallback while we awaited plugin fixes.
  • Terrain material issue: Investigated black-terrain rendering and material-reference issues, then revised the affected references in the documented case.

Workflow Stabilization:

  • Investigated and fixed an issue where Gaia failed to serialize generated data into Prefabs.
  • Wrote validation steps for Gaia, Storm, and related plugin workflows.
  • Prefab Preview Tool: Developed a custom Grid-based Prefab array viewer for asset auditing and visual validation by Level Designers (LDs) and Environment Artists.

7. Dynamic Weather & Environment Synergy (February 2026)

Volumetric Noise & Water Integration:

  • Volumetric Fog Noise Compute Shader: Wrote a lightweight Compute Shader to generate 3D noise textures for the Local Volumetric Fog system, then evaluated the resulting density and atmosphere in scene.
  • KWS2 Water System: Integrated KWS2 for ocean, river, and lake content, including the water-interaction and buoyancy features used by the project.

Weather Systems & Sun Orbit:

  • HDRP Time of Day: Configured multiple weather states and debugged the third-party integration, including parameter flow and legacy naming issues recorded in the project.
  • Nordic Latitude Sun Orbit: Rewrote the sun-orbit logic for Nordic latitudes and exposed core HDRP Time of Day APIs for Gameplay Programmers.

Global Wind & Shader Injection: Passed shared global wind data into Boxophobic assets and custom team shaders so their local animation could respond to the same source.

Decal Projector: Corruption Shader

Memory & Rendering Debugging:

  • Memory Leak Fix: Tracked a scene/weather transition leak to unreleased Render Textures (RTs) and fixed the observed release path.
  • Artifact Cleanup: Fixed residual “zombie meshes” on affected assets; in the documented case this also resolved several pink-shader interaction errors.

8. Workflow Decoupling & Stylized Visual Prototyping (March 2026)

LUT Workflow Decoupling:

  • Built a standalone LUT authoring and test workflow for the Art team.

RT-Driven Dynamic Interactions:

  • Leveraged Boxophobic’s Render Texture mechanisms to drive dynamic environmental interactions (e.g., physical vegetation displacement reacting to player movement, wind-driven emissive color shifts).
  • Applied this mechanism to the Corruption Point visuals to add vegetation displacement and emissive color changes around the crystals and surrounding environment.

Screen-Space Post-Processing FX:

  • Wrote a custom Crystalline UV Refraction screen-space post-effect. This allows Level Designers to dynamically scale the refraction polygon count and intensity when a player enters specific Corruption Volumes.

NPR Stylized Lighting Prototype (Medieval High-Contrast):

  • Developed a screen-space post-processing prototype based on an extremely stylized, non-physical lighting benchmark. Provided the Art team with two Time-of-Day environmental curves for Color Mapping, ensuring ground highlight colors and light source characteristics consistently maintained a specific, high-contrast color science filter.