The crash reporter pops up. Or the game hangs at a black screen. Or you get that dreaded “low-level fatal error” right after the shader compilation bar finishes. Most players jump straight to GPU driver reinstallation or verifying game files. That’s not wrong, but it skips the root cause: corrupted shader cache. Star Wars Zero Company builds a shader cache on first launch. If that cache becomes corrupt—and it does, often—the game will crash repeatedly until you wipe it clean. Here’s exactly how to do that with Windows Disk Cleanup, and why the standard advice misses a few critical details.
Why Shader Cache Corruption Causes Crashes
Shader compilation translates high-level graphics instructions into GPU-specific machine code. Modern games like Star Wars Zero Company compile shaders once and cache the result to avoid stutter on subsequent launches. But the cache is stored on disk as binary files. Disk writes can be interrupted by a power loss, a driver crash, or even a game update that changes the compiled shaders. The result: a corrupted file that the game tries to load, fails, and then throws a crash reporter error.
The crash often looks like a GPU driver issue—the error message may say “GPU crash dump triggered.” That’s because the graphics driver is the first layer to detect the invalid data. But reinstalling the driver won’t fix a bad cache file. You have to clear it first.
Windows Disk Cleanup: The Standard Method (and Its Quirk)
The recommended approach from most troubleshooting guides is straightforward:
- Open Windows Disk Cleanup (search for it in the Start menu).
- Select the drive where your Windows installation lives (usually C:).
- Click “Clean up system files” (this gives you access to additional categories).
- Scroll down the list and check “DirectX Shader Cache.”
- Click OK, confirm, wait for the cleanup to finish.
- Restart your PC. Then launch the game.
That works. But there’s a nuance the guides don’t tell you: Disk Cleanup only clears the DirectX shader cache, not other types. Vulkan shader caches, for instance, live in different folders. Star Wars Zero Company runs on Unreal Engine 5, which uses DirectX 12 by default. So Disk Cleanup is the right too. But if you’ve ever forced the game to run on Vulcan (via launch options like - vulkancodecodecodecodecodecode) or if you’re using an AMD GPU that caches shaders separately, you need to go deeper.
When Disk Cleanup Isn’t Enough
I’ve seen cases where clearing the DirectX cache via Disk Cleanup did nothing. Here are the reasons why, and what to do:
- The game’s own cache folder: Unreal Engine stores shader compilation logs and intermediate files inside the game’s installation directory (e.g.,
SteamsteamappscommonZero CompanySavedShaderCachecodecodecodecodecodecode). Disk Cleanup doesn’t touch these. You must delete them manually. Navigate to that folder, delete everything inside, then re-launch the game. It will rebuild the shaders from scratchaaaa—first launch will be slower. - Nvidia’s separate shader cache: Nvidia drivers also maintain their own cache at
%LocalAppData%NVIDIA CorporationNV_Cachecodecodecodecodecodecode. This is not cleared by Disk Cleanup. To be thorough, clear that folder too (stop any Nvidia services first, then delete, then reboot). - AMD’s shader cache: On AMD GPUs, the cache lives in
%LocalAppData%AMDDataShaderCachecodecodecodecodecodecode. Same deal. - The steam overlay interaction: If you have the Steam overlay enabled, it can interfere with shader compilation. Disable it temporarily (Steam > Settings > In-Game > uncheck “Enable the Steam Overlay while in-game”). Then clear the cache and try agan.
Other Fixes That Complement Shader Cache Clearing
Clearing the shader cache is step one. If the crash persits, you’re dealing with a different problem—but often one that manifests because the cache corruption was a symptom, not the cause. Here are the fixes from the source material that you should run after clearing the cache, in rough order of effectiveness.
Verify Integrity of Game Files on Steam
Corrupted game files can write bad data into the shader cache during compilation. Run a verify:
- Right-click Star Wars Zero Company in your Steam library.
- Select Properties > Installed Files > Verify integrity of game files.
- Wait for it to finish. It will replace any mismatched files.
This is fast and solves about 20% of remaining crashes. Always do it after clearing the cache.
GPU Driver Clean Installation
Standard “update driver” from Device Manager isn’t enough. Use DDU (Display Driver Uninstaller) in Safe Mode to fully remove the old driver. Then install the latest driver from Nvidia, AMD, or Intel. This eliminates any driver-level corruption that might be re-creating the shader cache issue.
Disable Overlays and Background Apps
Discord, Nvidias GeForce Overlay, Xbox Game Bar, and even hardware-monitoring tools like MSI Afterburner can intercept shader compilation and cause hangs. Turn them off. The source material mentions that closing browsers and recording software helps. Also, disable Steam’s overlay for this specific game (Steam Library > right-click Star Wars Zero Company > Properties > disable “Enable the Steam Overlay while in-game”).
Advanced: Manual Shader Cache Deletion via Command Line
If you’re comfortable with a terminal, you can automate the cache wipe with a single script. This is useful if you clear the cache repeatedly while testing other fixes. Open PowerShell as Administrator and run:
“`powershell
Remove-Item -Path “$env:LOCALAPPDATANVIDIA CorporationNV_Cache*” -Recurse -Force
Remove-Item -Path “$env:LOCALAPPDATAAMDDataShaderCache*” -Recurse -Force
Remove-Item -Path “$env:LOCALAPPDATATempD3DSCache*” -Recurse -Force
“`
Then delete the game’s own cache folder. The game’s path varies by store, but for Steam it’s: SteamsteamappscommonZero CompanyZeroCompanySavedShaderCachecodecodecodecodecodecode. Delete the entire ShaderCachecodecodecodecodecodecode folder. Restart.
This nukes every common shader cache location. First launch will take 5–10 minutes of compilation—that’s normal.
FAQ
Q: After clearing the shader cache, the game took forever to load. Is that bad?
No. Shaders need to be recompiled. Subsequent launches will be faster. If it keeps taking long, check that your drive has enough free space (at least 20 GB) and that you’re using an SSD.
Q: I cleared the cache, but the crash still happens. What now?
Increase virtual memory (search “advanced system settings” > Performance > Advanced > Virtual Memory > set a custom size equal to 1.5× your RAM). Also, run sfc /scannowcodecodecodecodecodecode followed by DISM /Online /Cleanup-Image /RestoreHealthcodecodecodecodecodecode from an Admin Command Prompt. Corrupted Windows files can also cause shader compilation failures.
Q: Does this affect my game performance?
Temporarily, yes — the first few minutes after a cache clear will have stutter as shaders compile on the fly. After that, performance returns to normal (often better, because the old corrupted cache was causing frame drops).
Q: I have a laptop with integrated and dedicated graphics. Any special steps?
Force the game to run on the dedicated GPU via Windows Graphics Settings (Settings > System > Display > Graphics > find Star Wars Zero Company > Options > High performance). Then clear the cache. Integrated graphics create a separate cache that can collide with the dedicated cache.
The Edge Case Nobody Talks About
Here’s a scenario the standard guides ignore: you cleared the cache, verified files, updated drivers—still crashing. Check your Windows pagefile. A pagefile that’s too small (under 4 GB) can cause shader compilation to fail silently. The game writes compiled shaders to disk, and if the paging file is full, the write fails, corrupting the cache. Set the paging file to “System managed size” or manually set it to at least 8192 MB. Then clear the cache once more.