dsh-hoi4-modding
DeepSeek Harness skill bundle for Hearts of Iron IV 1.19.3 modding: scaffold a mod, focus trees, events, decisions, ideas, characters, technologies, MIO, special projects, GUI, localisation, DDS, static verifier, installer and error.log triage. Bundled Python tools; no game assets.
Install
dsh plugin --profile web add dsh-hoi4-modding
Sandbox test results
| Stage | Result |
|---|---|
| 1 install | ✓ |
| 2 list | ✓ |
| 3 mount | ✓ |
| 4 boot | — |
Four stages run in an isolated sandbox: install (network on) → list → mount → boot (last three with no network).
README
dsh-hoi4-modding
English | [中文](#中文)


A DeepSeek Harness skill bundle for Hearts of Iron IV 1.19.3 modding. It registers one skill,
hoi4-modding, and ships the working notes, references and Python tooling behind it, so the agent can
take an HOI4 mod from an empty folder to a verified, installed, error.log-clean mod — and debug the
parts that actually go wrong: tech-tree pages, the tank designer, icons, CJK fonts, scripted GUI and
topbar buttons.
- One skill, no background services. Installing the package only adds skill metadata; nothing runs
until you ask for a task and the agent invokes a bundled script.
- Built from real sessions. Every reference section cites the game/mod file and line it came from;
the 1.4.0 round is a read-only survey of 23 workshop mods (~44 GB) plus four overhauls (Kaiserreich,
The Fire Rises, East Showdown, Road to 56).
- 14 Python tools. All standard library except
dds_helper.py(Pillow) — verifier, installer,
tech-tree/icon/font auditors, designer layout generator, DDS pipeline.
- No game assets, no network calls, no API keys.
Current release: 1.4.1 — see [CHANGELOG.md](CHANGELOG.md). The package is also listed in
dsh-market through the awesome-dsh-plugin index (category skill).
Install
# npm (what a market install does) dsh plugin --profile web add dsh-hoi4-modding # or straight from this repo dsh plugin --profile web add github:a1249070611/dsh-hoi4-modding
Restart / refresh as the host asks. The skill shows up in the session skill catalog; trigger it by
asking for HOI4 work ("做个 HOI4 mod", "加个国策树", "mod 报错了") or explicitly "load hoi4-modding".
The bundle works on DeepSeek Harness 0.2.x (engines.dsh: >=0.2.0 <0.3.0).
If the game is installed somewhere unusual, set HOI4_GAME / HOI4_USER_DIR; otherwise the scripts
auto-detect the Steam install and the player mod/ directory.
What it covers
Area · What the skill knows how to do
Mod authoring · Scaffold descriptor.mod + .mod + localisation + a runnable idea/event (optional focus tree); focus trees, events, decisions, ideas, characters, technologies, states/resources/buildings, dynamic variables and modifiers, MIO, special projects, scripted GUI panels, text/icons/GFX registration
Tech-tree UI · technology_folders.available must use original_tag (flag-based conditions silently drop every connection line); big/small item mixing needs the small item background sprites to point at real small textures; split/merge pages; @ grid macros; gridbox as a draw filter; three debugging recipes
Tank designer · Window/slot position tables, 16- and 18-slot layouts (7+4+7), module_slots data order vs pos_custom_module_slot_window_N, module categories, the fixed-size 1092×553 window background trap, duplicate_archetypes and gui_category
3D tank models · graphic_db → entity (.asset) → pdxmesh (.gfx) → .mesh/.anim/.dds; reuse vanilla entities, repaint, or custom mesh; effect nodes (barrel, tracks, exhaust)
Icon pipeline · Photo/vector → 173×77 .dds with safe area and card preview, background removal (transparent/white/8px checkerboard), white-paint protection, 183×84 card self-check
Scripted GUI & topbar · containerWindowType only (windowType fails), <button>_click effect naming, topbar plate extension and alert/info-bar offsets, the three topbar mounting patterns, why scripted windows are never auto-closed by native windows, TNO-style native-shell tabs
Localisation & fonts · UTF-8 with BOM, key rules, multi-line escaping; the real CJK ???? root cause (interface/core_chinese.gfx bitmapfont_override slices — every .fnt has zero CJK glyphs), 37 safe font names, custom font slices, font_audit.py
Verification & triage · Static lint (syntax/encoding/BOM/localisation/GFX/ID conflicts/.mod), tech-page audit, item-size vs sprite check, error.log triage table, acceptance checklist that requires a real new-game test
Knowledge base · Compact cheatsheet for 15 common tasks, a topic→deep-doc index, the 23-workshop-mod technique survey, and a multi-agent division-of-labour playbook (survey / build / audit write domains, handoff contract)
Bundled tools
Run with the script directory of the installed skill ($S below). Python 3.10+; only DDS work needs
Pillow.
Script · What it does
new_mod.py · Scaffold a runnable mod (.mod, descriptor.mod, BOM localisation, example idea/event, optional focus tree) and lint it
hoi4_lint.py · Static verifier: syntax, encoding/BOM, localisation, GFX references, ID conflicts, .mod structure; builds a vanilla index on first run (--no-vanilla to skip)
install_mod.py · Copy-install into the player mod/ directory and enable in the playset (--uninstall to remove); never touches the game install
build_reference.py · Generate effects/triggers/modifiers/console references from the game's own documentation/*.md
dds_helper.py · Generate or inspect HOI4 DDS icons (Pillow)
pdx_parser.py · Tolerant PDX script parser shared by the linter
tech_tree_audit.py · Audit tech pages: registry vs page/tab/item templates/gridboxes/techs/localisation
tech_folder_available.py · Migrate technology_folders.available from has_country_flag to original_tag (--check / --apply / --revert, backs up)
item_sprite_check.py · Compare item template sizes with the actual item background sprite pixels ("small item looks big")
errorlog_triage.py · Triage error.log into tech-tree / texture / scope / unknown-field / localisation buckets
tank_designer_probe.py · Probe the desi
…(truncated)
Rendered from the README published on npm. Formatted only, not edited.
Versions
Published on npm::9,最后更新 2026-11-05