Skip to content

DOC-04 · Troubleshooting

What broke, and whose fault it is

Five failures that keep coming up during development. Three of them are not the mod’s fault at all, and that is exactly why they waste the most time.

redscript_rCURRENT.log is never created

Not the mod

If r6\logs\redscript_rCURRENT.log does not appear at all after you launch the game, redscript never ran, which means RED4ext never loaded it. The problem is RED4ext, not the scripts, and it is always the first thing to suspect.

Next, check red4ext\logs\. If that folder is also empty or missing, nothing is hooking into the game, and no amount of reading the mod’s code will explain it.

Changes do not show up in game

Expected

redscript has no hot reload of its own, but RedHotTools adds one, and it works: change the body of a function that already exists and the change reaches the game without a restart. To reload, open the CET overlay and go to Hot Reload → Scripts → Reload scripts. Confirmed working since 4 September.

Three changes still need a full game restart: a new Event class, a new @addMethod on one of the game’s own classes, or a new field on a class that already has a live instance — that last one crashed the game on reload.

Compilation errors after an update

Stale cache

If the errors point at code you no longer have, or at lines that do not match the file in front of you, you are looking at a stale modded cache, not a real compilation failure. Clear it and launch again.

r6\cache\modded      # delete this folder
.\tools\clean-cache.ps1   # or run the script that does it

The game crashed

Check the crash type first

Open the crash report before you blame any script. A DX12 device-removed crash names the GPU API outright:

Message: Gpu Crash for unknown reasons!
File: ...\src\common\gpuApi\src\dx12\gpuApiDX12Error.cpp(42)

That is a graphics driver fault, not a script fault. Scripts cannot trigger a device-removed crash directly. An access violation is a different animal and worth investigating; a device removal comes down to a driver, a clock or a card.

A CDPR patch broke it

Degrade, do not crash

Every patch breaks hashes and offsets, and always will. Native tooling has to be rebuilt against the new binary before anything built on top of it can run.

The mod is written to degrade rather than crash: a system that can no longer find what it needs switches itself off instead of taking the game down with it. After a patch, expect some features to go quiet, and expect to update RED4ext and redscript first.

Hit one that is not listed?

Report it on Discord. Say which game patch you are on and what you did before it happened: all five failures above were narrowed down from someone describing exactly that. Support is answered there too, by the person who writes the code.