702 Commits

Author SHA1 Message Date
Saratoga-Official
78f092f855 fix: YJ暗改用户中心间距 2026-07-13 20:48:44 +08:00
Zian Wen
7746f07fc4 fix: 修正多作业 H 关 OCR 替换 / correct H-stage OCR replacement (#17326)
## 说明

多作业模式进入 H10-1 关卡详情页后,OCR 可能会把关卡名识别为 `H1O-1`。现有替换规则没有将它还原为 `H10-1`,而是处理成了
`-1`,导致关卡校验失败并重新开始导航。

本 PR 将 `ClickStageName` 和 `ClickedCorrectStage` 中的 `$010` 改为
`${1}0`,明确区分捕获组 1 和后面的字符 `0`。

## 原因

原规则的本意是保留捕获组 1,再补一个 `0`:

```json
["(H\\d+)O(?=-)", "$010"],
["(-\\d+)O", "$010"]
```

OCR 后处理使用 `boost::regex_replace`。这里的 `$010` 会被解析为捕获组 10,而不是捕获组 1 后接
`0`。这两个正则都没有第 10 个捕获组,因此 `H1O-1` 最终被处理成 `-1`。

修改后的规则使用无歧义写法:

```json
["(H\\d+)O(?=-)", "${1}0"],
["(-\\d+)O", "${1}0"]
```

## 验证

- `resource/tasks/tasks.json` 可以正常解析。
- 四处相关替换均已改为 `${1}0`,`git diff --check` 通过。
- 使用 MAA `v6.14.1`、明日方舟 PC 端、2560 × 1440 分辨率测试 H10-1 多作业导航。

修复前:

```text
CharOcr: H1O-1
Proceed: -1
confirm stage name failed after retrying 3 times, stage name: H10-1
```

修复后,同样的 OCR 输入可以正确进入编队流程:

```text
[2026-07-12 14:12:08.499][TRC] CharOcr: H1O-1
[2026-07-12 14:12:08.499][TRC] Proceed: H10-1
[2026-07-12 14:12:09.545][INF] task: BattleStartPre, text: 开始行动
[2026-07-12 14:12:11.670][INF] SubTaskStart: BattleFormationTask
```

本次测试中没有再出现 `confirm stage name failed`。

<details>
<summary>English</summary>

## Summary

In multi-copilot mode, the stage name on the H10-1 detail panel may be
recognized as `H1O-1`. The existing replacement rules turn it into `-1`
instead of restoring `H10-1`, so stage confirmation fails and navigation
starts over.

This PR changes `$010` to `${1}0` in both `ClickStageName` and
`ClickedCorrectStage`, making the boundary between capture group 1 and
the literal `0` explicit.

## Root cause

The original rules were intended to preserve capture group 1 and append
a literal `0`:

```json
["(H\\d+)O(?=-)", "$010"],
["(-\\d+)O", "$010"]
```

OCR post-processing uses `boost::regex_replace`, where `$010` is parsed
as capture group 10 rather than capture group 1 followed by `0`. Since
these expressions do not contain a tenth capture group, `H1O-1` is
reduced to `-1`.

The replacement now uses the unambiguous `${1}0` form.

## Verification

- Parsed `resource/tasks/tasks.json` successfully.
- Confirmed all four affected replacements use `${1}0`; `git diff
--check` passes.
- Tested H10-1 multi-copilot navigation with MAA `v6.14.1` on the
Arknights PC client at 2560 × 1440.
- The same `H1O-1` OCR result was corrected to `H10-1`, after which MAA
clicked `BattleStartPre` and entered `BattleFormationTask`.
- No `confirm stage name failed` entry was produced during the post-fix
attempt.

</details>

Refs #16888
2026-07-12 15:18:15 +08:00
Saratoga-Official
9cb0ed6803 fix: 因网络原因跳过肉鸽结局剧情出错
fix #17319
2026-07-11 14:55:48 +08:00
Saratoga-Official
3f3a936508 fix: 折桠识别
fix #17317
2026-07-11 12:48:50 +08:00
uye
a5e468a608 feat: 自动战斗多作业模式支持异体字关卡导航(需更新版本) (#16984)
## Summary by Sourcery

通过基于模板的关卡导航来处理活动关卡与支线关卡,当没有可用模板时回退到 OCR。

新功能:
- 添加一个辅助工具,用标准化关卡代码解析活动关卡模板路径,并在资源存在时使用模板匹配进行关卡导航。
- 为多协助作战关卡选择和支线复刻关卡选择启用基于模板的导航,以提升关卡识别的稳定性。

改进:
- 在资源加载阶段,按完整相对路径索引所有模板图片文件,以便在 C++ 代码中动态查找关卡导航模板。

<details>
<summary>Original summary in English</summary>

## Summary by Sourcery

Introduce template-based stage navigation for event and side-story
stages, falling back to OCR when no template is available.

New Features:
- Add a helper to resolve event stage template paths from standardized
stage codes and use template matching for stage navigation when
resources exist.
- Enable template-based navigation for multi-copilot stage selection and
side-story reopen stage selection to improve stage recognition
reliability.

Enhancements:
- Index all template image files by full relative path during resource
loading to allow dynamic lookup of stage navigation templates from C++
code.

</details>

新功能:
- 为事件关卡引入基于模板的导航机制,通过从标准化路径解析每个关卡的截图模板,并在可用时优先使用模板而不是 OCR。
- 将基于模板的导航应用于多协助器(multi-copilot)关卡选择以及支线故事重开关卡选择,以在这些流程中提供更稳健的关卡识别支持。

增强:
- 在加载模板资源时按相对路径索引所有模板图片文件,以便可以从 C++ 代码中动态查找关卡导航模板。

<details>
<summary>Original summary in English</summary>

## Summary by Sourcery

通过基于模板的关卡导航来处理活动关卡与支线关卡,当没有可用模板时回退到 OCR。

新功能:
- 添加一个辅助工具,用标准化关卡代码解析活动关卡模板路径,并在资源存在时使用模板匹配进行关卡导航。
- 为多协助作战关卡选择和支线复刻关卡选择启用基于模板的导航,以提升关卡识别的稳定性。

改进:
- 在资源加载阶段,按完整相对路径索引所有模板图片文件,以便在 C++ 代码中动态查找关卡导航模板。

<details>
<summary>Original summary in English</summary>

## Summary by Sourcery

Introduce template-based stage navigation for event and side-story
stages, falling back to OCR when no template is available.

New Features:
- Add a helper to resolve event stage template paths from standardized
stage codes and use template matching for stage navigation when
resources exist.
- Enable template-based navigation for multi-copilot stage selection and
side-story reopen stage selection to improve stage recognition
reliability.

Enhancements:
- Index all template image files by full relative path during resource
loading to allow dynamic lookup of stage navigation templates from C++
code.

</details>

</details>
2026-07-04 20:02:34 +08:00
萨拉托加
727905f54a fix: 萨米肉鸽特里蒙旅行社特派团识别错误
fix #17253
2026-07-04 00:09:45 +08:00
Rin
812e764bfb fix: 基建产物收取时因loading遮挡跳过 (#17232)
* fix: 基建产物收取时因loading遮挡跳过

* fix: 修正通知收取后的 loading 分支

Co-authored-by: Status102 <102887808+status102@users.noreply.github.com>

---------

Co-authored-by: Status102 <102887808+status102@users.noreply.github.com>
2026-07-03 23:09:17 +08:00
Aliothmoon
efb3c7a567 fix: 部分设备界园树洞是非境识别错误 (#17181) 2026-06-24 10:58:48 +08:00
uye
a2d1cd93a2 chore: "text": ["苍暮", "山", "地"]
[skip changelog]
2026-06-15 18:27:59 +08:00
SherkeyXD
110baa4fdf fix: 修正落叶落叶逐火入口OCR文本 2026-06-15 17:30:23 +08:00
SherkeyXD
f3e8070e1d feat: 添加落叶逐火复刻入口任务 2026-06-15 17:01:50 +08:00
Saratoga-Official
4034bc58e4 fix: 肉鸽战斗结束后招募误入StartExplore
fix #17120
2026-06-15 12:38:20 +08:00
github-actions[bot]
0dde389e34 chore: Auto Update Game Resources - 2026-06-15
https://github.com/MaaAssistantArknights/MaaAssistantArknights/actions/runs/27521713212

[skip changelog]
2026-06-15 03:12:52 +00:00
Saratoga-Official
3f18299322 fix: 水月大海的遗产和狗眼婆娑事件名识别错误 2026-06-15 11:07:41 +08:00
Saratoga-Official
e47d6a56a3 fix: GetDrop增加LoadingText等待
fix #17118
2026-06-15 10:59:14 +08:00
Saratoga-Official
d74fa22fb6 fix: 修复CloseEvent和CloseCollection同时出现导致的问题
fix #17121
2026-06-15 10:36:12 +08:00
Saratoga-Official
1dfac534d0 fix: 界园移时换物放弃探索
fix #17055
2026-06-13 14:14:06 +08:00
status102
99167c3298 fix: 水月肉鸽事件DiceConfirm后事件不处理 2026-06-12 19:57:13 +08:00
Rin
018e4ba38f fix: 处理界园事件内通宝交换后的事件结束页 (#16936)
* fix: 处理界园事件内通宝交换后的事件结束页

* fix: 优化事件内放弃通宝的#next
2026-06-11 17:12:30 +08:00
uye
be1087846b chore: 调整部署速度 2026-06-10 12:02:42 +08:00
uye
127fed5318 chore: 足球需要更多的 325 2026-06-10 11:59:35 +08:00
uye
3a9e059299 chore: 阵地足球开始后增加动画延迟,避免点入编队界面 2026-06-10 11:53:58 +08:00
github-actions[bot]
7d5648fe1a chore: Auto Update Game Resources - 2026-06-09
https://github.com/MaaAssistantArknights/MaaAssistantArknights/actions/runs/27222080798

[skip changelog]
2026-06-09 17:09:13 +00:00
uye
da7fabd57e feat: 添加阵地足球锦标赛小游戏 2026-06-10 00:13:27 +08:00
Rin
0b3f97dea9 fix: 增加贸易站订单切换重试和产物确认逻辑 (#16954) 2026-06-09 11:25:39 +08:00
status102
9b951cbabf perf: 优化部分情况下自动战斗导航OCR结果中会出现误识别的前缀 2026-06-09 01:54:04 +08:00
Status102
353c0ec972 fix: 修正特克诺干员名 OCR 误识别 (#17030)
## 问题与修复
issue 日志中,排序重选阶段 OCR 将“特克诺”识别为“持克诺”,导致后续按精确干员名匹配时无法命中。
在全局干员名 OCR 替换表中加入规则,仅将完整识别结果“持克诺”替换为“特克诺”。

```
15912:[2026-06-06 11:07:15.290][TRC][Px20248][Tx37564] asst::WordOcr [{ text: 褐果, rect: [ 0 (80), 0 (1), 40, 19 ], score: 0.999965 }] by OCR Rec , cost 16 ms
15913:[2026-06-06 11:07:15.290][TRC][Px20248][Tx37564] Proceed [{ text: 褐果, rect: [ 80, 1, 40, 19 ], score: 0.999965 }]
15914:[2026-06-06 11:07:15.290][WRN][Px20248][Tx37564] asst::VisionHelper::correct_rect roi is empty, use whole image
15915:[2026-06-06 11:07:15.307][TRC][Px20248][Tx37564] asst::WordOcr [{ text: 持克诺, rect: [ 0 (60), 0 (1), 60, 19 ], score: 0.881702 }] by OCR Rec , cost 16 ms
15916:[2026-06-06 11:07:15.307][TRC][Px20248][Tx37564] Proceed [{ text: 持克诺, rect: [ 60, 1, 60, 19 ], score: 0.881702 }]
15917:[2026-06-06 11:07:15.307][WRN][Px20248][Tx37564] asst::VisionHelper::correct_rect roi is empty, use whole image
15918:[2026-06-06 11:07:15.354][TRC][Px20248][Tx37564] asst::WordOcr [{ text: 凯尔希思衡托, rect: [ 0 (6), 0 (2), 114, 16 ], score: 0.992512 }] by OCR Rec , cost 45 ms
15919:[2026-06-06 11:07:15.354][TRC][Px20248][Tx37564] Proceed [{ text: 凯尔希·思衡托, rect: [ 6, 2, 114, 16 ], score: 0.992512 }]
```

fixes #17018

## Summary by Sourcery

错误修复:
- 通过在全局替换表中将误识别的“持克诺”映射为“特克诺”,纠正对运营商名称的 OCR 识别。

<details>
<summary>Original summary in English</summary>

## Summary by Sourcery

Bug Fixes:
- Correct OCR recognition of the operator name by mapping the misread
form “持克诺” to “特克诺” in the global replacement table.

</details>
2026-06-07 03:26:53 +08:00
ZiyinLin
4e5a234ece fix: 修正特克诺干员名 OCR 误识别 2026-06-07 00:57:00 +08:00
github-actions[bot]
2abb30e373 chore: Auto Update Game Resources - 2026-06-06
https://github.com/MaaAssistantArknights/MaaAssistantArknights/actions/runs/27067590574

[skip changelog]
2026-06-06 16:28:19 +00:00
uye
0a551b95f9 feat: 切换主题时保存当前画面截图 (#16993)
* feat: 切换主题时保存当前画面截图

* chore: SwitchTheme tasks 定义移到子文件夹中
2026-06-07 00:17:54 +08:00
status102
1247e9a308 fix: 绿票商店状态回退错误 2026-06-06 01:35:14 +08:00
status102
0ae5fceb87 fix: 绿票商店2阶段check
Co-authored-by: ZiyinLin <xuanbing1464129430@gmail.com>
2026-06-06 01:35:13 +08:00
Status102
204542620c rft: 肉鸽弹窗类事件处理重构 CloseCollectionClose (#17005)
* rft: 界园 part

* rft: 水月part

修改后未使用: StageEncounterEnter, CloseEvent, DropsFlag; 仅使用了: ChooseOperFlag, Stages
原始
```
"next": [
    "Mizuki@Roguelike@StageEncounterEnter",
    "Mizuki@Roguelike@Stages#next",
    "Mizuki@Roguelike@DropsFlag",
    "Mizuki@Roguelike@CloseEvent",
    "Mizuki@Roguelike@ChooseOperFlag"
]
```

* rft: 萨米part

* rft: 萨卡兹part

* rft: ChooseOper处的CloseCollectionContinue统一调整至上一级的ChooseOperFlag
2026-06-04 18:21:31 +08:00
status102
fa60340ed0 rft: ChooseOper处的CloseCollectionContinue统一调整至上一级的ChooseOperFlag 2026-06-04 17:05:38 +08:00
status102
8971768c33 rft: 萨卡兹part 2026-06-04 16:58:28 +08:00
status102
8610f11890 rft: 萨米part 2026-06-04 16:12:48 +08:00
status102
e4af06ea9c rft: 水月part
修改后未使用: StageEncounterEnter, CloseEvent, DropsFlag; 仅使用了: ChooseOperFlag, Stages
原始
```
"next": [
    "Mizuki@Roguelike@StageEncounterEnter",
    "Mizuki@Roguelike@Stages#next",
    "Mizuki@Roguelike@DropsFlag",
    "Mizuki@Roguelike@CloseEvent",
    "Mizuki@Roguelike@ChooseOperFlag"
]
```
2026-06-04 15:37:10 +08:00
status102
a132f80158 rft: 界园 part 2026-06-04 15:22:49 +08:00
Status102
bba3f3281a rft: 基于灰度阈值预处理的自动战斗导航, 适配H关及怪猎2期 (#16990)
* rft: 基于灰度阈值的自动战斗导航, 适配H关及怪猎2期

* perf: 清理

* fix: replace

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>

* fix: loule

---------

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
2026-06-04 09:54:16 +08:00
uye
f3a2d90472 chore: 延长 TD-Open 延迟 2026-06-02 04:53:53 +08:00
uye
c533a44a9a chore: TDChapterToTD 添加重试 2026-06-02 04:48:47 +08:00
SherkeyXD
c277a69110 feat: 界面主题「出猎」 2026-06-01 22:19:04 +08:00
uye
7bca192a21 fix: roi 2026-06-01 21:22:48 +08:00
Rin
1d46ff16a1 feat: 增加怪猎联动二期 TD-6/7/8 (#16962)
* feat: 增加怪猎联动二期 TD-6/7/8

* chore: revert stage.json

* chore: 移除多余逻辑

---------

Co-authored-by: uye <99072975+ABA2396@users.noreply.github.com>
2026-06-01 21:18:32 +08:00
Saratoga-Official
22635a7b60 fix: 御龙装置识别 2026-06-01 14:19:30 +08:00
Rin
9bd27f7968 Revert "fix: 调整基建干员名 OCR 区域" (#16937)
* Revert "fix: 调整基建干员名 OCR 区域 (#16905)"

This reverts commit 89377eba94.

* revert: EN changes no longer needed

---------

Co-authored-by: Constrat <56174894+Constrat@users.noreply.github.com>
2026-05-31 22:34:18 +08:00
Status102
7d6ad3b4c1 rft: 水月萨卡兹肉鸽 关闭next弹窗 (#16918)
* rft: 水月肉鸽 关闭next弹窗

* rft: 萨卡兹part

* perf: 简化模板声明
2026-05-30 17:21:21 +08:00
Rin
89377eba94 fix: 调整基建干员名 OCR 区域 (#16905)
- 扩大笑脸锚点派生的干员名识别范围
2026-05-30 01:10:32 +08:00
Rin
4b520aaac9 fix: 修复宿舍自定义干员+信赖补位的bug&外服同步修复&提升代码可读性 (#16659)
* fix: 修复宿舍自定义干员+信赖补位的bug

* chore: EN

* fix: 补充宿舍筛选全部按钮的日韩识别文本

补充日服“全て”和韩服“전부”,用于取消宿舍“未进驻”筛选时点击“全部”选项。

* refactor: improve infrast dorm task readability

---------

Co-authored-by: Constrat <56174894+Constrat@users.noreply.github.com>
Co-authored-by: Roland125 <oroland125@outlook.com>
2026-05-30 00:56:57 +08:00
github-actions[bot]
952c97d9a6 chore: Auto Update Game Resources - 2026-05-28
https://github.com/MaaAssistantArknights/MaaAssistantArknights/actions/runs/26589446911

[skip changelog]
2026-05-28 17:00:23 +00:00