The objective is to modify the ShadowsQualitySettings block to expand the shadow distance while adjusting the cascade transitions to avoid “flickering” artifacts ($F_{shadow}$).
File Path & Setup
- Navigate to:
%AppData%\..\LocalLow\Colossal Order\Cities Skylines II\ - Locate:
Settings.coc(Note: This is a JSON-formatted file despite the.cocextension). - Pro Tip: If you cannot find the file, ensure “Hidden Items” is checked in Windows Explorer. Always create a backup named
Settings.coc.bakbefore editing.
Optimized “Infinite Shadows” Configuration Table
| Parameter | Recommended Value | Technical Purpose |
enabled | true | Ensures the shadow system is active at the engine level. |
shadowQuality | High | Sets the baseline resolution for shadow maps. |
shadowDistance | 4 | The Fix. Overrides the internal float to “Very Far” or custom high. |
shadowCascades | 4 | Increases the number of transition zones for smoother shading. |
terrainQuality | High | Necessary for shadows to cast correctly on distant topography. |
{
"enabled": true,
"shadowQuality": "High",
"shadowDistance": 4000.0,
"shadowCascades": 4,
"shadowProjection": "Stable",
"shadowNearPlaneOffset": 2.0,
"@type": "Game.Settings.ShadowsQualitySettings"
}
HowTo: Engineering the Realistic Shadow Horizon
Follow these GameEngineer.net technical steps to stabilize your 2026 city visuals:
- The Manual Distance Override: In the
.cocfile, find the@type": "Game.Settings.ShadowsQualitySettings"block. By manually entering a float value forshadowDistance(e.g.,4000.0), you can push the shadow rendering well beyond the “Very Far” UI toggle, which is typically capped much lower. - Shadow Cascades and Jitter: Set
shadowCascadesto4. This divides the shadow map into four zones of detail. While this is more GPU-intensive, it prevents the “Shadow Shifting” bug where shadows appear to move or vibrate as you pan the camera ($V_{jitter}$). - Global Illumination (GI) Handshake: For the best results, your
GlobalIlluminationQualitySettingsshould be set to Medium or High. Shadows in CS2 rely on GI data to determine their “darkness” ($D_{val}$); if GI is off, shadows will look like black voids rather than natural occlusions. - Developer Mode Tweak: If the
.cocedits reset, launch the game with the--developerModeflag. Press Tab in-game, navigate to the Lighting tab, and you can live-adjust the “Shadow Distance Scale” to find the exact performance sweet spot for your GPU. - VRAM Management: Pushing shadow distances significantly increases VRAM usage. If you notice textures turning gray or blurry, reduce your
shadowDistanceby $500$ until the texture streaming stabilizes.
Technical Explanation: Cascade Shadow Mapping ($CSM$)
Cities: Skylines 2 uses Cascade Shadow Mapping. The engine renders the world’s shadows in multiple layers—high resolution for what is close to you, and low resolution for the distance.
When you increase the shadowDistance in the Settings.coc, you are stretching these cascades across a larger area. Without increasing the shadowCascades count, this would result in blurry shadows nearby. By balancing both, you maintain a high Sample Density ($S_{den}$) near your city streets while ensuring the skyscrapers in the distance still cast their silhouettes on the terrain, preventing the “floating building” look common in unoptimized setups.