dsh-hoi4-modding 1.1.1 → 1.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,32 +1,69 @@
1
- # Changelog
2
-
3
- ## 1.1.1
4
-
5
- - 文档同步补丁:README 增加「Publishing」小节(2026 年可用 granular token 直发;**2027-01 起该方式移除**,
6
- 改用 stage only + `npm stage publish` 或 GitHub Actions Trusted Publishing),CHANGELOG 记录同项。
7
- 1.1.0 已包含全部功能与脚本,本版仅同步文档,避免 npm 包与仓库不一致。
8
-
9
- ## 1.1.0
10
-
11
- 科技树 UI 专题(来自一次 2900 科技/多国科技页大型 Mod 的真实排障,全部结论经游戏内对照实验验证):
12
-
13
- - **新增** `references/tech-tree-ui.md`
14
- - `technology_folders.available` 必须用 `original_tag`:用 `has_country_flag` 时引擎建页画线阶段的
15
- 运行时二次求值失败,**整页连线被静默丢弃**(方框在、日志干净、旧存档正常而新开档必现)。
16
- - 大框/小框混排三件套:`force_use_small_tech_layout` + `techtree_<folder>_small_item` 模板 +
17
- `GFX_technology_<folder>_small_*_item_bg` **指向真正的小图**(模板 size 只管排版,贴图按像素绘制)。
18
- - 拆页/合并页 6 步配方、网格原点统一规则、跨页 path 不画线的必然性。
19
- - 三种调试手法:留痕法(改名 gridbox 判断页面是否被建)、对半分实验、对照探针。
20
- - **新增脚本**
21
- - `tech_tree_audit.py`:科技页完整性审计(注册表 ↔ 页面/页签/item 模板/网格/科技/本地化)
22
- - `tech_folder_available.py`:`has_country_flag` → `original_tag` 批量迁移(check/apply/revert)
23
- - `item_sprite_check.py`:item 模板尺寸 vs 背景精灵实际像素(专治"小框显示成大框 + 偏位")
24
- - `errorlog_triage.py`:error.log 分诊(科技树/贴图/scope/未知字段/本地化),并给出"日志干净即静默跳过"的判语
25
- - **SKILL.md**:铁律新增 2 条(科技页可用性、大小框三件套);排错表新增 3 行症状;验收清单新增 2 条;
26
- 工具与配方索引补充新内容。
27
- - README:脚本清单、更新记录(中英)。
28
- - README:补充 npm 发布方式说明(2027-01 起 granular token 直发被移除,改用 stage only / Trusted Publishing)。
29
-
30
- ## 1.0.0
31
-
32
- - 首个版本:HOI4 1.19.3 Mod 全流程技能(骨架/国策/事件/决议/理念/角色/科技/州/MIO/特殊项目/GUI/本地化/DDS/校验/安装/排错/发布)。
1
+ # Changelog
2
+
3
+ ## 1.2.0
4
+
5
+ 坦克设计器 + 3D 模型 + 图标流水线专题(来自一次 30 科技德国坦克树 / 16 槽设计器改造的真实工程,
6
+ 全部结论经游戏内对照验证):
7
+
8
+ - **新增** `references/tank-designer.md`
9
+ - 设计器文件地图:`interface/tank_designer_view.gui`(窗口 1091×542、`equipment_modules` 13/146 512×350、
10
+ 9 个 `pos_custom_module_slot_window_*`)、`equipmentdesignerview.gui`(槽位按钮模板 **76×47**)、
11
+ 每底盘蓝图 GUI(`equipment_designer_<底盘>` → archetype 回退)。
12
+ - 数据侧:槽位 = `module_slots` 书写顺序;模块类别由 `category =` 隐式创建;装备可自定义 `module_slots`。
13
+ - 16 槽布局(上 7 + 第二排 2 + 下 7,窗口不加高 542)完整坐标与取舍。
14
+ - **窗口背景固定尺寸坑**:`GFX_tank_designer_popup_bg` 是 1092×553 贴图,只改窗口 size 会让内容溢出;
15
+ 给出“顶部原样 + 中间平铺 + 底部原样”生成加高 DDS 的配方。
16
+ - 隐藏升级区/自动按钮的安全做法(position 移出屏幕;`auto_upgrade_button` 可能被代码自动摆放)。
17
+ - **新增** `references/tank-models-3d.md`
18
+ - 四层链路 `graphic_db` → `entity`(`.asset`)→ `pdxmesh`(`.gfx`)→ `.mesh/.anim/.dds`;
19
+ - 原版德国实体清单(`GER_iw/light/medium/heavy/super_heavy_armor_entity`)、特效节点
20
+ `barrel`/`left_tracks`/`right_tracks`/`left_exhaust`/`right_exhaust`;
21
+ - 复用原版 / 换贴图 / 自制 mesh 三条路线,导出器(Maya 官方、Blender 社区)与排错表。
22
+ - **新增** `references/icon-dds-pipeline.md`
23
+ - 科技卡几何:183×84 卡、`Icon` 中心 x=74 → 内容右移 8px(左 20 / 右 4 / 上下 2,最大 149×73);
24
+ - 去背(透明/白底/8px 棋盘格)、白色涂装保护规则(亮度≥235 且 relY<0.8)、批量别名表、卡片预览自检、踩坑表。
25
+ - **新增脚本**
26
+ - `tank_designer_probe.py`:设计器体检(窗口/槽位位置/槽位模板/背景 DDS 尺寸/模块类别/底盘 archetype 槽数/隐藏元素)
27
+ - `tank_designer_layout.py`:从原版 GUI 生成自定义槽位布局(默认 16 槽紧凑版,支持 16-tall、背景 sprite 替换、dry-run)
28
+ - `tech_icon_import.py`:照片/矢量图 → 173×77 DDS(去背 + 安全区 + 183×84 卡片预览,可调尺寸/边距)
29
+ - **文档补充**
30
+ - `references/tech-tree-ui.md` 新增:多根分支 gridbox(一个页面多个 `_tree`)、生成文件被外部改写导致
31
+ `Found no grid box` 的排查顺序;
32
+ - `references/cheatsheet.md` 新增 §16:坦克设计器 / 3D 模型 / 173×77 图标速查;
33
+ - SKILL.md 铁律 +2 条、配方索引 +3 行、排错表 +3 行、验收清单 +2 条。
34
+
35
+ ## 1.1.2
36
+
37
+ - 发布通道切换为 **npm Trusted Publishing (OIDC)**:`release.yml` 去掉 `NPM_TOKEN` 依赖,改用 OIDC 发布并生成 provenance;
38
+ README 的中英「Publishing」小节同步更新。技能内容与 1.1.1 相同(纯发布/文档变更)。
39
+
40
+ ## 1.1.1
41
+
42
+ - 文档同步补丁:README 增加「Publishing」小节(2026 年可用 granular token 直发;**2027-01 起该方式移除**,
43
+ 改用 stage only + `npm stage publish` 或 GitHub Actions Trusted Publishing),CHANGELOG 记录同项。
44
+ 1.1.0 已包含全部功能与脚本,本版仅同步文档,避免 npm 包与仓库不一致。
45
+
46
+ ## 1.1.0
47
+
48
+ 科技树 UI 专题(来自一次 2900 科技/多国科技页大型 Mod 的真实排障,全部结论经游戏内对照实验验证):
49
+
50
+ - **新增** `references/tech-tree-ui.md`
51
+ - `technology_folders.available` 必须用 `original_tag`:用 `has_country_flag` 时引擎建页画线阶段的
52
+ 运行时二次求值失败,**整页连线被静默丢弃**(方框在、日志干净、旧存档正常而新开档必现)。
53
+ - 大框/小框混排三件套:`force_use_small_tech_layout` + `techtree_<folder>_small_item` 模板 +
54
+ `GFX_technology_<folder>_small_*_item_bg` **指向真正的小图**(模板 size 只管排版,贴图按像素绘制)。
55
+ - 拆页/合并页 6 步配方、网格原点统一规则、跨页 path 不画线的必然性。
56
+ - 三种调试手法:留痕法(改名 gridbox 判断页面是否被建)、对半分实验、对照探针。
57
+ - **新增脚本**
58
+ - `tech_tree_audit.py`:科技页完整性审计(注册表 ↔ 页面/页签/item 模板/网格/科技/本地化)
59
+ - `tech_folder_available.py`:`has_country_flag` → `original_tag` 批量迁移(check/apply/revert)
60
+ - `item_sprite_check.py`:item 模板尺寸 vs 背景精灵实际像素(专治"小框显示成大框 + 偏位")
61
+ - `errorlog_triage.py`:error.log 分诊(科技树/贴图/scope/未知字段/本地化),并给出"日志干净即静默跳过"的判语
62
+ - **SKILL.md**:铁律新增 2 条(科技页可用性、大小框三件套);排错表新增 3 行症状;验收清单新增 2 条;
63
+ 工具与配方索引补充新内容。
64
+ - README:脚本清单、更新记录(中英)。
65
+ - README:补充 npm 发布方式说明(2027-01 起 granular token 直发被移除,改用 stage only / Trusted Publishing)。
66
+
67
+ ## 1.0.0
68
+
69
+ - 首个版本:HOI4 1.19.3 Mod 全流程技能(骨架/国策/事件/决议/理念/角色/科技/州/MIO/特殊项目/GUI/本地化/DDS/校验/安装/排错/发布)。
package/README.md CHANGED
@@ -1,128 +1,146 @@
1
- # dsh-hoi4-modding
2
-
3
- **English** | [中文](#中文)
4
-
5
- A DeepSeek Harness **skill bundle** for Hearts of Iron IV (HOI4) **1.19.3** modding. It registers one
6
- skill, `hoi4-modding`, which turns the agent into a working HOI4 modder: create a mod from scratch,
7
- write focus trees / events / decisions / ideas / characters / technologies / MIO / special projects /
8
- scripted GUI, add localisation and DDS icons, run a static verifier, install into the game, and debug
9
- `error.log`.
10
-
11
- ## Install
12
-
13
- ```sh
14
- # from npm (market install does the same thing)
15
- dsh plugin --profile web add dsh-hoi4-modding
16
-
17
- # or straight from the source repo
18
- dsh plugin --profile web add github:a1249070611/dsh-hoi4-modding
19
- ```
20
-
21
- Restart / refresh as the host asks. The skill appears in the session skill catalog; invoke it by asking
22
- for HOI4 modding, or explicitly “load hoi4-modding”.
23
-
24
- npm: https://www.npmjs.com/package/dsh-hoi4-modding
25
-
26
- ## What is inside
27
-
28
- | Path | Purpose |
29
- |---|---|
30
- | `skills/hoi4-modding/SKILL.md` | The skill body: rules, workflow, error-log triage, acceptance checklist |
31
- | `skills/hoi4-modding/references/cheatsheet.md` | Copy-ready code for 15 common tasks |
32
- | `skills/hoi4-modding/references/deep-dive.md` | Topic → deep-documentation index |
33
- | `skills/hoi4-modding/scripts/new_mod.py` | Scaffold a runnable mod (optional focus tree; runs the linter) |
34
- | `skills/hoi4-modding/scripts/hoi4_lint.py` | Static verifier: syntax, encoding/BOM, localisation, GFX, ID conflicts, `.mod` structure |
35
- | `skills/hoi4-modding/scripts/install_mod.py` | Copy-install a mod into the player `mod/` directory and enable it |
36
- | `skills/hoi4-modding/scripts/build_reference.py` | Generate effects/triggers/modifiers/console references from the game's `documentation/*.md` |
37
- | `skills/hoi4-modding/scripts/dds_helper.py` | Generate / inspect HOI4 DDS icons (needs Pillow) |
38
- | `skills/hoi4-modding/scripts/pdx_parser.py` | Tolerant PDX script parser used by the linter |
39
- | `skills/hoi4-modding/references/tech-tree-ui.md` | Tech tree UI: folder availability, connection lines, big/small item layouts, split/merge recipes, debugging recipes |
40
- | `skills/hoi4-modding/scripts/tech_tree_audit.py` | Audit a mod's tech pages: registry vs page/tab/item templates/gridboxes/techs/localisation |
41
- | `skills/hoi4-modding/scripts/tech_folder_available.py` | Migrate `technology_folders.available` from `has_country_flag` to `original_tag` (check/apply/revert) |
42
- | `skills/hoi4-modding/scripts/item_sprite_check.py` | Compare item template sizes with the actual item background sprite pixels ("small item looks big") |
43
- | `skills/hoi4-modding/scripts/errorlog_triage.py` | Triage `error.log`: tech tree / textures / scopes / unknown fields / localisation |
44
-
45
- ## Requirements
46
-
47
- - DeepSeek Harness with the skill registry (0.2.x).
48
- - **Python 3.10+** for the bundled scripts (stdlib only; `dds_helper.py` needs `pip install pillow`).
49
- - **HOI4 1.19.3** for the verifier's vanilla index, GFX and ID checks. Without the game the skill still
50
- works for scaffolding and code recipes; the game directory is auto-detected (`HOI4_GAME` /
51
- `HOI4_USER_DIR` override).
52
- - No network access, no API keys, no game files are shipped.
53
-
54
- ## Permissions
55
-
56
- The plugin registers skill metadata only. The bundled Python scripts are run by the agent **when the
57
- user asks**; they read the HOI4 install and, for `install_mod.py`, write into the player
58
- `Documents/Paradox Interactive/Hearts of Iron IV/mod/` directory (never the game install itself).
59
- All commands are visible in the conversation before they run.
60
-
61
- ## License
62
-
63
- ## Publishing
64
-
65
- - **Now – December 2026**: a granular access token with **Read and write (publish and stage)** and
66
- **Bypass 2FA** enabled can publish directly with `npm publish --access public`.
67
- npm deprecates this path in **January 2027**.
68
- - **From January 2027**: use a **stage only** token plus `npm stage publish`, or GitHub Actions
69
- **Trusted Publishing** (the bundled `release.yml` already runs on `v*` tags).
70
-
71
- ## Changelog
72
-
73
- - **1.1.0** — Tech tree UI knowledge from a real large-mod debugging session: `technology_folders.available`
74
- must use `original_tag` (flag-based conditions silently drop every connection line on a page in new games),
75
- big/small item mixing requires the small item background **sprites** to point at real small textures,
76
- plus three debugging recipes (marker rename, half-split experiment, control probe) and four new scripts.
77
- - 1.0.0 — Initial release.
78
-
79
- ## License
80
-
81
- MIT. The skill text and scripts are original; no Paradox game assets are included.
82
-
83
- ---
84
-
85
- ## 中文
86
-
87
- **DeepSeek Harness 的 HOI4 1.19.3 Mod 制作技能包。** 安装后注册一个名为 `hoi4-modding` 的技能:
88
- 从零建 Mod、写国策/事件/决议/理念/角色/科技/MIO/特殊项目/scripted GUI、本地化与 DDS 图标、
89
- 静态校验、安装进游戏、按 `error.log` 排错。
90
-
91
- ### 安装
92
-
93
- ```sh
94
- dsh plugin --profile web add dsh-hoi4-modding
95
- # 或从源码仓库:
96
- dsh plugin --profile web add github:a1249070611/dsh-hoi4-modding
97
- ```
98
-
99
- 刷新/重启后,技能出现在技能目录;直接说「做个 HOI4 mod」「加个国策树」「mod 报错了」即可触发,
100
- 也可以显式说「加载 hoi4-modding 技能」。
101
-
102
- ### 本次新增(1.1.0)
103
- - `references/tech-tree-ui.md`:科技树页面可用性 / 连线 / 大小框混排 / 拆页合并 / 三种调试手法(留痕法、对半分、对照探针)
104
- - 4 个新脚本:`tech_tree_audit.py`(科技页完整性审计)、`tech_folder_available.py`(旗帜判定→国家标签,批量修复整页无连线)、
105
- `item_sprite_check.py`(模板尺寸 vs 背景精灵像素,专治"小框显示成大框")、`errorlog_triage.py`(error.log 分诊)
106
-
107
- ### 发布方式(npm)
108
- - 2026 年内:Granular token 选 **Read and write (publish and stage)** 并勾选 **Bypass 2FA**,可 `npm publish --access public` 直发;
109
- npm 已在页面上提示该方式将于 **2027 年 1 月**移除。
110
- - 2027 年起:改用 **stage only** token + `npm stage publish`,或 GitHub Actions **Trusted Publishing**
111
- (仓库里的 `release.yml` 已在 `v*` 标签触发)。
112
-
113
- ### 依赖
114
-
115
- - DeepSeek Harness(含技能注册表,0.2.x)
116
- - Python 3.10+(脚本仅标准库;DDS 工具需 Pillow)
117
- - HOI4 1.19.3(校验器需要;游戏目录自动探测,可用 `HOI4_GAME` / `HOI4_USER_DIR` 覆盖)
118
- - 不含任何游戏本体资源,不需要网络与 API Key
119
-
120
- ### 权限说明
121
-
122
- 插件只注册技能元数据;技能里的 Python 脚本由 agent 在你要求时执行:读取游戏安装目录,
123
- `install_mod.py` 会把 Mod 复制到玩家 `Documents/Paradox Interactive/Hearts of Iron IV/mod/`
124
- (不改游戏安装目录)。所有命令在对话中可见。
125
-
126
- ### 许可
127
-
128
- MIT。技能文本与脚本为原创,不包含 Paradox 游戏素材。
1
+ # dsh-hoi4-modding
2
+
3
+ **English** | [中文](#中文)
4
+
5
+ A DeepSeek Harness **skill bundle** for Hearts of Iron IV (HOI4) **1.19.3** modding. It registers one
6
+ skill, `hoi4-modding`, which turns the agent into a working HOI4 modder: create a mod from scratch,
7
+ write focus trees / events / decisions / ideas / characters / technologies / MIO / special projects /
8
+ scripted GUI, add localisation and DDS icons, run a static verifier, install into the game, and debug
9
+ `error.log`.
10
+
11
+ ## Install
12
+
13
+ ```sh
14
+ # from npm (market install does the same thing)
15
+ dsh plugin --profile web add dsh-hoi4-modding
16
+
17
+ # or straight from the source repo
18
+ dsh plugin --profile web add github:a1249070611/dsh-hoi4-modding
19
+ ```
20
+
21
+ Restart / refresh as the host asks. The skill appears in the session skill catalog; invoke it by asking
22
+ for HOI4 modding, or explicitly “load hoi4-modding”.
23
+
24
+ npm: https://www.npmjs.com/package/dsh-hoi4-modding
25
+
26
+ ## What is inside
27
+
28
+ | Path | Purpose |
29
+ |---|---|
30
+ | `skills/hoi4-modding/SKILL.md` | The skill body: rules, workflow, error-log triage, acceptance checklist |
31
+ | `skills/hoi4-modding/references/cheatsheet.md` | Copy-ready code for 15 common tasks |
32
+ | `skills/hoi4-modding/references/deep-dive.md` | Topic → deep-documentation index |
33
+ | `skills/hoi4-modding/scripts/new_mod.py` | Scaffold a runnable mod (optional focus tree; runs the linter) |
34
+ | `skills/hoi4-modding/scripts/hoi4_lint.py` | Static verifier: syntax, encoding/BOM, localisation, GFX, ID conflicts, `.mod` structure |
35
+ | `skills/hoi4-modding/scripts/install_mod.py` | Copy-install a mod into the player `mod/` directory and enable it |
36
+ | `skills/hoi4-modding/scripts/build_reference.py` | Generate effects/triggers/modifiers/console references from the game's `documentation/*.md` |
37
+ | `skills/hoi4-modding/scripts/dds_helper.py` | Generate / inspect HOI4 DDS icons (needs Pillow) |
38
+ | `skills/hoi4-modding/scripts/pdx_parser.py` | Tolerant PDX script parser used by the linter |
39
+ | `skills/hoi4-modding/references/tech-tree-ui.md` | Tech tree UI: folder availability, connection lines, big/small item layouts, split/merge recipes, debugging recipes |
40
+ | `skills/hoi4-modding/scripts/tech_tree_audit.py` | Audit a mod's tech pages: registry vs page/tab/item templates/gridboxes/techs/localisation |
41
+ | `skills/hoi4-modding/scripts/tech_folder_available.py` | Migrate `technology_folders.available` from `has_country_flag` to `original_tag` (check/apply/revert) |
42
+ | `skills/hoi4-modding/scripts/item_sprite_check.py` | Compare item template sizes with the actual item background sprite pixels ("small item looks big") |
43
+ | `skills/hoi4-modding/scripts/errorlog_triage.py` | Triage `error.log`: tech tree / textures / scopes / unknown fields / localisation |
44
+ | `skills/hoi4-modding/references/tank-designer.md` | Tank designer: window/slot position table, 16-slot layouts, module-slot data, taller-window background trap |
45
+ | `skills/hoi4-modding/references/tank-models-3d.md` | Tank 3D models: `entity`/`pdxmesh`/`.mesh`/`.anim`/`.dds` chain, effect nodes, reuse/repaint/custom-mesh routes |
46
+ | `skills/hoi4-modding/references/icon-dds-pipeline.md` | Tech icon pipeline: photo → 173×77 DDS, de-background, white-paint protection, safe margins, card preview |
47
+ | `skills/hoi4-modding/scripts/tank_designer_probe.py` | Probe designer window, slot table, slot-entry size, module categories, chassis slot counts, background DDS size |
48
+ | `skills/hoi4-modding/scripts/tank_designer_layout.py` | Generate a custom tank-designer slot layout (16-compact preset) into a mod |
49
+ | `skills/hoi4-modding/scripts/tech_icon_import.py` | Photo/vector → 173×77 DDS: de-background, safe-area placement, 183×84 card preview |
50
+
51
+ ## Requirements
52
+
53
+ - DeepSeek Harness with the skill registry (0.2.x).
54
+ - **Python 3.10+** for the bundled scripts (stdlib only; `dds_helper.py` needs `pip install pillow`).
55
+ - **HOI4 1.19.3** for the verifier's vanilla index, GFX and ID checks. Without the game the skill still
56
+ works for scaffolding and code recipes; the game directory is auto-detected (`HOI4_GAME` /
57
+ `HOI4_USER_DIR` override).
58
+ - No network access, no API keys, no game files are shipped.
59
+
60
+ ## Permissions
61
+
62
+ The plugin registers skill metadata only. The bundled Python scripts are run by the agent **when the
63
+ user asks**; they read the HOI4 install and, for `install_mod.py`, write into the player
64
+ `Documents/Paradox Interactive/Hearts of Iron IV/mod/` directory (never the game install itself).
65
+ All commands are visible in the conversation before they run.
66
+
67
+ ## License
68
+
69
+ ## Publishing
70
+
71
+ Releases are published by GitHub Actions using npm **Trusted Publishing (OIDC)** — no `NPM_TOKEN`
72
+ secret and no bypass-2FA token are required:
73
+
74
+ 1. npmjs.com → package `dsh-hoi4-modding` → Settings → **Trusted Publisher** → GitHub Actions
75
+ (repository `a1249070611/dsh-hoi4-modding`, workflow file `release.yml`, "Allow npm publish").
76
+ 2. Release: `npm version patch -m "release %s" && git push origin master --tags`.
77
+ The `release.yml` workflow runs the tests and publishes with provenance.
78
+
79
+ The old granular-token flow (bypass-2FA token + `npm publish`) is deprecated by npm and stops working
80
+ in **January 2027**.
81
+
82
+ ## Changelog
83
+
84
+ - **1.1.0** — Tech tree UI knowledge from a real large-mod debugging session: `technology_folders.available`
85
+ must use `original_tag` (flag-based conditions silently drop every connection line on a page in new games),
86
+ big/small item mixing requires the small item background **sprites** to point at real small textures,
87
+ plus three debugging recipes (marker rename, half-split experiment, control probe) and four new scripts.
88
+ - 1.0.0 — Initial release.
89
+
90
+ ## License
91
+
92
+ MIT. The skill text and scripts are original; no Paradox game assets are included.
93
+
94
+ ---
95
+
96
+ ## 中文
97
+
98
+ **DeepSeek Harness 的 HOI4 1.19.3 Mod 制作技能包。** 安装后注册一个名为 `hoi4-modding` 的技能:
99
+ 从零建 Mod、写国策/事件/决议/理念/角色/科技/MIO/特殊项目/scripted GUI、本地化与 DDS 图标、
100
+ 静态校验、安装进游戏、按 `error.log` 排错。
101
+
102
+ ### 安装
103
+
104
+ ```sh
105
+ dsh plugin --profile web add dsh-hoi4-modding
106
+ # 或从源码仓库:
107
+ dsh plugin --profile web add github:a1249070611/dsh-hoi4-modding
108
+ ```
109
+
110
+ 刷新/重启后,技能出现在技能目录;直接说「做个 HOI4 mod」「加个国策树」「mod 报错了」即可触发,
111
+ 也可以显式说「加载 hoi4-modding 技能」。
112
+
113
+ ### 本次新增(1.2.0)
114
+ - `references/tank-designer.md`:坦克设计器(窗口 / `pos_custom_module_slot_window_N` 槽位位置表 / 底盘 `module_slots` / 模块类别 / 16 槽布局 / 加高窗口背景贴图坑 / 隐藏升级区与自动按钮)
115
+ - `references/tank-models-3d.md`:坦克 3D 模型链路(`entity`→`pdxmesh`→`.mesh/.anim/.dds`、特效节点 `barrel`/`tracks`/`exhaust`、复用原版 / 换贴图 / 自制 mesh 三条路线)
116
+ - `references/icon-dds-pipeline.md`:科技卡 173×77 图标流水线(去白底/棋盘格、白色涂装保护、安全区 20/4、183×84 卡片自检)
117
+ - 新增 3 个脚本:`tank_designer_probe.py`(设计器体检)、`tank_designer_layout.py`(生成 16 槽布局)、`tech_icon_import.py`(照片→图标 DDS)
118
+ - 科技树文档补充:多根分支 gridbox(一个页面多个 `_tree`)、生成文件被外部改写导致 `Found no grid box` 的排查
119
+
120
+ ### 1.1.0 新增(历史)
121
+ - `references/tech-tree-ui.md`:科技树页面可用性 / 连线 / 大小框混排 / 拆页合并 / 三种调试手法(留痕法、对半分、对照探针)
122
+ - 4 个新脚本:`tech_tree_audit.py`(科技页完整性审计)、`tech_folder_available.py`(旗帜判定→国家标签,批量修复整页无连线)、
123
+ `item_sprite_check.py`(模板尺寸 vs 背景精灵像素,专治"小框显示成大框")、`errorlog_triage.py`(error.log 分诊)
124
+
125
+ ### 发布方式(npm)
126
+ - 默认走 **GitHub Actions + Trusted Publishing (OIDC)**,不需要 `NPM_TOKEN`、也不需要 bypass-2FA token。
127
+ 在 npmjs.com 的包设置里把仓库 `a1249070611/dsh-hoi4-modding` 与 workflow `release.yml` 注册为 Trusted Publisher;
128
+ 发版只需 `npm version patch -m "release %s"`,然后 `git push origin master --tags`,CI 会自动测试并带 provenance 发布。
129
+ - 旧的 granular token 直发方式(勾选 Bypass 2FA 后 `npm publish`)已被 npm 弃用,**2027 年 1 月起失效**。
130
+
131
+ ### 依赖
132
+
133
+ - DeepSeek Harness(含技能注册表,0.2.x)
134
+ - Python 3.10+(脚本仅标准库;DDS 工具需 Pillow)
135
+ - HOI4 1.19.3(校验器需要;游戏目录自动探测,可用 `HOI4_GAME` / `HOI4_USER_DIR` 覆盖)
136
+ - 不含任何游戏本体资源,不需要网络与 API Key
137
+
138
+ ### 权限说明
139
+
140
+ 插件只注册技能元数据;技能里的 Python 脚本由 agent 在你要求时执行:读取游戏安装目录,
141
+ `install_mod.py` 会把 Mod 复制到玩家 `Documents/Paradox Interactive/Hearts of Iron IV/mod/`
142
+ (不改游戏安装目录)。所有命令在对话中可见。
143
+
144
+ ### 许可
145
+
146
+ MIT。技能文本与脚本为原创,不包含 Paradox 游戏素材。
package/package.json CHANGED
@@ -1,67 +1,70 @@
1
- {
2
- "name": "dsh-hoi4-modding",
3
- "version": "1.1.1",
4
- "description": "HOI4 1.19.3 modding skill bundle for DeepSeek Harness: create, edit, validate, install and debug Hearts of Iron IV mods (focus trees, events, decisions, ideas, characters, technologies, MIO, special projects, GUI, localisation, DDS) with bundled verifier/installer scripts; plus tech tree UI diagnostics (page availability, connection lines, big/small item layouts).",
5
- "type": "module",
6
- "main": "lib/index.js",
7
- "exports": {
8
- ".": "./lib/index.js",
9
- "./package.json": "./package.json",
10
- "./cordis.patch.yml": "./cordis.patch.yml"
11
- },
12
- "files": [
13
- "lib/index.js",
14
- "cordis.patch.yml",
15
- "skills/**/*",
16
- "README.md",
17
- "LICENSE",
18
- "icon.svg",
19
- "CHANGELOG.md"
20
- ],
21
- "dsh": {
22
- "bundle": {
23
- "patch": "./cordis.patch.yml"
24
- }
25
- },
26
- "peerDependencies": {
27
- "@deepseek-ai/cordis": "^4.0.1",
28
- "@deepseek-ai/dsh-skill": ">=0.1.0-rc.1 <0.3.0-0"
29
- },
30
- "peerDependenciesMeta": {
31
- "@deepseek-ai/cordis": {
32
- "optional": true
33
- },
34
- "@deepseek-ai/dsh-skill": {
35
- "optional": true
36
- }
37
- },
38
- "engines": {
39
- "node": "^22.19.0 || >=24.0.0",
40
- "dsh": ">=0.2.0 <0.3.0"
41
- },
42
- "scripts": {
43
- "test": "node --test tests/smoke.test.mjs"
44
- },
45
- "keywords": [
46
- "deepseek",
47
- "deepseek-harness",
48
- "dsh",
49
- "dsh-plugin",
50
- "skill",
51
- "hearts-of-iron",
52
- "hoi4",
53
- "hoi4-modding",
54
- "paradox",
55
- "modding"
56
- ],
57
- "icon": "./icon.svg",
58
- "license": "MIT",
59
- "repository": {
60
- "type": "git",
61
- "url": "git+https://github.com/a1249070611/dsh-hoi4-modding.git"
62
- },
63
- "homepage": "https://github.com/a1249070611/dsh-hoi4-modding#readme",
64
- "bugs": {
65
- "url": "https://github.com/a1249070611/dsh-hoi4-modding/issues"
66
- }
67
- }
1
+ {
2
+ "name": "dsh-hoi4-modding",
3
+ "version": "1.2.0",
4
+ "description": "HOI4 1.19.3 modding skill bundle for DeepSeek Harness: create, edit, validate, install and debug Hearts of Iron IV mods (focus trees, events, decisions, ideas, characters, technologies, MIO, special projects, GUI, localisation, DDS) with bundled verifier/installer scripts; plus tech tree UI diagnostics and tank designer (module slots, 16-slot layouts, 3D models, tech icon pipeline).",
5
+ "type": "module",
6
+ "main": "lib/index.js",
7
+ "exports": {
8
+ ".": "./lib/index.js",
9
+ "./package.json": "./package.json",
10
+ "./cordis.patch.yml": "./cordis.patch.yml"
11
+ },
12
+ "files": [
13
+ "lib/index.js",
14
+ "cordis.patch.yml",
15
+ "skills/**/*",
16
+ "README.md",
17
+ "LICENSE",
18
+ "icon.svg",
19
+ "CHANGELOG.md"
20
+ ],
21
+ "dsh": {
22
+ "bundle": {
23
+ "patch": "./cordis.patch.yml"
24
+ }
25
+ },
26
+ "peerDependencies": {
27
+ "@deepseek-ai/cordis": "^4.0.1",
28
+ "@deepseek-ai/dsh-skill": ">=0.1.0-rc.1 <0.3.0-0"
29
+ },
30
+ "peerDependenciesMeta": {
31
+ "@deepseek-ai/cordis": {
32
+ "optional": true
33
+ },
34
+ "@deepseek-ai/dsh-skill": {
35
+ "optional": true
36
+ }
37
+ },
38
+ "engines": {
39
+ "node": "^22.19.0 || >=24.0.0",
40
+ "dsh": ">=0.2.0 <0.3.0"
41
+ },
42
+ "scripts": {
43
+ "test": "node --test tests/smoke.test.mjs"
44
+ },
45
+ "keywords": [
46
+ "deepseek",
47
+ "deepseek-harness",
48
+ "dsh",
49
+ "dsh-plugin",
50
+ "skill",
51
+ "hearts-of-iron",
52
+ "hoi4",
53
+ "hoi4-modding",
54
+ "paradox",
55
+ "modding",
56
+ "tank-designer",
57
+ "3d-models",
58
+ "icon-pipeline"
59
+ ],
60
+ "icon": "./icon.svg",
61
+ "license": "MIT",
62
+ "repository": {
63
+ "type": "git",
64
+ "url": "git+https://github.com/a1249070611/dsh-hoi4-modding.git"
65
+ },
66
+ "homepage": "https://github.com/a1249070611/dsh-hoi4-modding#readme",
67
+ "bugs": {
68
+ "url": "https://github.com/a1249070611/dsh-hoi4-modding/issues"
69
+ }
70
+ }
@@ -8,7 +8,8 @@
8
8
  ```
9
9
  hoi4-modding/
10
10
  ├─ SKILL.md # 必需:frontmatter 含 name、description
11
- ├─ references/ # 可选:参考资料(本技能为 cheatsheet.md、deep-dive.md)
11
+ ├─ references/ # 可选:参考资料(本技能为 cheatsheet.md、deep-dive.md、tech-tree-ui.md、
12
+ │ # tank-designer.md、tank-models-3d.md、icon-dds-pipeline.md)
12
13
  ├─ scripts/ # 可选:可执行工具(Python 3.10+,标准库;DDS 需 Pillow)
13
14
  └─ INSTALL.md # 本文件
14
15
  ```