Yeah, that one's annoying. You're mid-match, everything's fine, and then it just kicks you to the desktop with that cryptic "Dev Error 118" message. I've seen this on more than a few client rigs, and the good news is it's rarely a hardware failure. The bad news is most people waste an hour reinstalling the game for nothing.
The Fix: Clear the Shader Cache and Update the Driver
Do these in order. Skip the reinstall entirely — I've never seen it help with 118.
Step 1: Delete the shader cache folder
Close the game and Battle.net (or Steam). Then open File Explorer and paste this into the address bar:
%LOCALAPPDATA%\Activision\Call of Duty Modern Warfare II\playersLook for a folder called shadercache and delete it entirely. Don't worry, the game rebuilds it on next launch. This is where 90% of the time the corruption lives.
Also, if you're on Steam, check this path and delete the same folder:
%ProgramFiles(x86)%\Steam\steamapps\common\Call of Duty HQ\shadercacheStep 2: Update your GPU driver
Outdated drivers cause more weird CoD crashes than anything else. Go to your GPU maker's site directly — don't rely on Windows Update.
- NVIDIA: nvidia.com/drivers
- AMD: amd.com/en/support
Download the latest Game Ready driver, do a clean install (choose "Custom" and check the clean install box). Then restart your PC.
Step 3: Relaunch and let the shaders rebuild
First launch after clearing the cache will take a few extra minutes — it's rebuilding. Don't skip it, don't alt-tab to check your email. Let it finish. Then jump into a match.
Why This Works
Dev Error 118 is almost always a shader cache corruption issue. The game stores compiled shaders on disk so it doesn't have to rebuild them every time. But if that cache gets corrupted — which can happen from a driver update mid-session, a crash during a shader build, or even a Windows update interfering — the game tries to load broken data and just bails with a generic error. Deleting the cache forces a fresh build. Updating the driver makes sure the new build is compatible with what your GPU actually speaks.
Had a client last month whose entire print queue died from a driver issue, but that's a different story. For CoD, this combo fixes 118 roughly 8 times out of 10.
Less Common Variations
If clearing the cache and updating drivers didn't do it, here are a few other culprits I've run into:
Overclocking instability
If you're running an OC on your CPU or GPU, even a stable one for other games, CoD can be picky. Reset to stock clocks and try again. If it stops crashing, you know. It's not a permanent fix — just dial it back a notch.
Insufficient VRAM
On older cards (GTX 1060 6GB or similar), the game can hit VRAM limits and throw 118 instead of a clean "out of memory" message. Lower your textures to "Normal" and see if it stops. If it does, you're at the edge.
Corrupt install files (rare but real)
Before you reinstall, try the repair option:
- Battle.net: Click the gear icon next to the game → Scan and Repair
- Steam: Right-click the game → Properties → Local Files → Verify integrity of game files
Prevention
Once you've fixed it, keep it from coming back.
- Update your GPU driver regularly, but not the day a new one drops if you're in a ranked match. Give it a day or two for hotfixes.
- Don't force-close the game while it's building shaders in the background. Let it finish.
- If you use MSI Afterburner or similar, keep your OC modest. No need to push every last frame.
- If you're on an SSD, keep at least 20GB free — CoD's shader cache can bloat unexpectedly.
That's it. You should be back in the fight within ten minutes. If it still crashes after this, you might be looking at a deeper issue like failing RAM or a dying PSU, but that's a whole other rabbit hole.