Corsix, but for VS Code!
Complete VS Code / Windsurf extension for Relic Game Data (.rgd) files used in Dawn of War and Company of Heroes modding.
Merges RGD Editor and RGD CLI into a single package with an embedded hash dictionary.
Download from the Releases page and either:
- Drag and drop the
.vsixinto the Extensions panel, or - Run:
code --install-extension rgd-suite-latest.vsix
- Open
.rgdfiles in a split-pane table editor (tree + property grid) - Edit scalar values (float, int, bool, string) inline
- Save changes back to binary format
- Clickable
$REFlinks to open referenced files
- Persistent RGD tree in the Explorer sidebar
- Inline value editing via input box
- Auto-loads from the active editor
| Command | Description |
|---|---|
RGD: Convert to Text Format |
Binary → .rgd.txt human-readable format |
RGD: Convert Text to Binary |
.rgd.txt → binary .rgd |
RGD: Dump to Lua |
Binary → differential Lua format |
RGD: Compile Lua to RGD |
Lua → binary .rgd |
RGD: Batch Convert Folder to Lua |
Batch Lua dump |
RGD: Batch Compile Folder to RGD |
Batch compile |
RGD: Extract from SGA Archive |
Extract .rgd files from SGA archives |
RGD: Show File Info |
Display file metadata |
Diff a binary .rgd against its Lua source to catch stale builds or manual edits — single file or entire folder.
| Command | Description |
|---|---|
RGD: Check Parity (RGD ↔ Lua) |
Compare one .rgd / .lua pair |
RGD: Batch Parity Check (Folder) |
Recursively check all pairs in a folder |
Results appear in Output → RGD Parity Checker with per-key [PASS] / [FAIL] / [SKIP] lines.
Compare a working-tree .rgd against a git revision at the key/value table level (not a binary hex dump):
| Command | Description |
|---|---|
RGD Suite: Show Git Table Diff |
Open the table editor ready for git compare |
| Table editor toolbar Git Diff | Diff vs HEAD: highlighted tree rows + change list |
CLI table-diff file.rgd [--ref HEAD] |
Machine-readable key-level diff (--format json) |
Rows are colored added / removed / changed; click a list entry to jump to that key in the tree.
The RGD Suite submenu organizes everyday modding workflows (inspired by Corsix Mod Studio):
| Area | Commands |
|---|---|
| Open | Table / text editor, open counterpart, RGD+Lua side-by-side, clone/copy as… |
| Navigate… | Open parent Reference(), find reverse references, search keys, find by name, reveal attrib root |
| Copy… | Attrib path, data/attrib/…, Reference() snippet, hash, file info JSON, names |
| Tools… | Rename pair + rewrite references (optional recompile), compare tables, strip BOM, new RGD, digest, PowerShell CLI |
| Convert | Selection → Lua/RGD/text, dump & open, compile & open |
| Folder | Batch convert, batch validate/parity, key search, find files, new RGD |
| Command | Description |
|---|---|
RGD: Convert Lua to RGD (CLI) |
rgd.fromLua |
RGD: Convert RGD to Lua (CLI) |
rgd.toLua |
RGD: Show RGD Info (CLI) |
rgd.info |
RGD: Validate File (CLI) |
rgd.validate |
- Syntax highlighting for
.rgd.txtfiles - Clickable document links for file paths,
$IDlocale strings, and icon names
| Setting | Default | Description |
|---|---|---|
rgdEditor.dictionaryPaths |
[] |
Additional hash dictionary files |
rgdEditor.preferredLanguage |
Chinese |
Language for UCS string resolution |
rgdEditor.autoConvertOnSave |
true |
Auto-save .rgd.txt back to binary |
rgdEditor.resolveLocaleStrings |
true |
Resolve $ID locale strings when opening RGDs |
rgdEditor.retainWebviewContext |
true |
Keep table editor alive when hidden |
rgdSuite.attribPath |
"" |
Override attrib root path |
rgdSuite.vfsCacheSize |
50 |
Parsed RGD cache size for rgd:// text |
rgdSuite.treeCacheSize |
30 |
Parsed RGD cache for tree sidebar |
rgdSuite.parityWorkers |
0 |
Worker threads for batch parity (0 = auto) |
rgdSuite.batchWorkers |
0 |
Worker threads for batch convert/validate |
cd rgd-suite
npm install
npm run build-all # compiles + packages rgd-suite-<version>.vsixnpm run build— compile only (out/extension.js)npm run watch— incremental rebuild during developmentnpm run package— package only (reads version frompackage.json)
This repo defines a Devin Stop hook in .devin/hooks.v1.json that runs aislop scan (scan only — never auto-fix) and injects a short findings summary into agent context. Full output is written to .devin/aislop-last-scan.txt (gitignored).
Requires global aislop (npm i -g aislop). In Devin, run /hooks to confirm the hook is loaded.
The hash dictionary (RGD_DIC.TXT) and the foundational RGD ↔ Lua conversion techniques used in this extension are derived from Corsix's Mod Studio
Without his original research into the Relic binary format and his hash dictionary, none of this would have been possible.
MIT