Compare commits

..

8 Commits

Author SHA1 Message Date
Status102
75e425dae0 fix: 超出范围的Rect使用{0, 0, 0, 0}代替原样返回, x, y为负值时width和height改正错误 (#15695)
* fix: 超出范围的Rect使用{0, 0, 0, 0}代替原样返回

* fix: x, y为负值时width和height改正错误

* fix: 全出去的直接0
2026-02-26 15:42:48 +08:00
status102
01ca2090fc perf: Wpf 增加未找到 CrashDumps 文件夹 Log, correct_rect 增加 rect.empty() log 2026-02-26 15:41:22 +08:00
status102
887a5c174f fix: 修复自动战斗中待部署区干员匹配标志rect后处理越界 2026-02-26 15:38:53 +08:00
status102
40d60a4395 Revert "fix: 超出范围的Rect使用{0, 0, 0, 0}代替原样返回, x, y为负值时width和height改正错误 (#15695)"
This reverts commit e14af2f630.
2026-02-26 12:33:21 +08:00
萨拉托加
b1057db5e0 ci: 添加PC端标签 2026-02-26 11:52:59 +08:00
status102
2136597697 fix: 移除多余检查 2026-02-26 11:40:13 +08:00
萨拉托加
3b85a920f1 ci: 修复无法正确识别日志上传失败 2026-02-26 10:32:35 +08:00
github-actions[bot]
ef57632adf chore: Auto update by pre-commit hooks
https://github.com/MaaAssistantArknights/MaaAssistantArknights/actions/runs/22416032302
[skip changelog]
2026-02-25 21:11:06 +00:00
7 changed files with 31 additions and 18 deletions

View File

@@ -129,6 +129,12 @@ labels:
- name: remove client-ZH_TW
content:
regexes: "[Rr]emove (?:[Ll]abels? |)(?:`|)(?:[Cc]li(?:ent|): |)ZH_TW(?:`|)"
- name: skip client-PC
content:
regexes: "[Ss]kip (?:[Ll]abels? |)(?:`|)(?:[Cc]li(?:ent|): |)PC(?:`|)"
- name: remove client-PC
content:
regexes: "[Rr]emove (?:[Ll]abels? |)(?:`|)(?:[Cc]li(?:ent|): |)PC(?:`|)"
- name: skip ambiguous
content:
@@ -408,6 +414,18 @@ labels:
- remove client
- remove client-ZH_TW
# `client: PC`
- name: "client: PC"
regexes: '(?:[Pp][Cc]|[Ww]indows|[Ww]in)\s*(?:版|端|客户端)'
skip-if:
- skip all
- skip client
- skip client-PC
remove-if:
- remove all
- remove client
- remove client-PC
# `ambiguous`
- name: pr-ambiguous
# 不符合 commitizen 的 PR
@@ -522,7 +540,7 @@ labels:
# `incomplete`
- name: incomplete
content: incomplete
regexes: '(?:\[Uploading asst(?:.bak|)(?: - 副本|)(?:.log|)(?:.zip|)…\]\(\))|<!-- Uploading "(log|report)[^"]*\.zip"\.\.\. -->'
regexes: '(?:\[Uploading asst(?:.bak|)(?: - 副本|)(?:.log|)(?:.zip|)…\]\(\))|<!-- (?:Failed to upload|Uploading) "(log|report)[^"]*\.zip"(?:\.\.\.)? -->'
mode: add
skip-if:
- skip all
@@ -547,7 +565,7 @@ labels:
comments:
- name: Log upload failed
regexes: '\[Uploading asst(?:.bak|)(?: - 副本|)(?:.log|)(?:.zip|)…\]\(\)|<!-- Uploading "log[^"]*\.zip"\.\.\. -->'
regexes: '(?:\[Uploading asst(?:.bak|)(?: - 副本|)(?:.log|)(?:.zip|)…\]\(\))|<!-- (?:Failed to upload|Uploading) "(log|report)[^"]*\.zip"(?:\.\.\.)? -->'
content: "你的日志没有上传成功,请重新上传。\n\n\
Your log did not upload successfully, please re-upload it."
mode: add

View File

@@ -3816,7 +3816,7 @@
},
"BattleOpersFlag": {
"templThreshold": 0.65,
"roi": [0, 588, 1280, 18],
"roi": [35, 588, 1210, 18],
"maskRange": [1, 255]
},
"BattleAvatarReMatch": {

View File

@@ -711,9 +711,6 @@ bool asst::BattleFormationTask::check_and_select_skill(const battle::OperUsage&
return true;
}*/
if (oper.requirements.skill_level == 0) {
return true; // 无技能等级要求
}
auto result = m_quick_formation_ui.find_oper_skill(oper.skill, oper.requirements.skill_level == 0);
if (!result) {
LogError << __FUNCTION__ << "| Skill" << oper.skill << "not found in quick detection";

View File

@@ -103,7 +103,7 @@ std::vector<battle::DeploymentOper> BattlefieldMatcher::deployment_analyze() con
battle::DeploymentOper oper;
oper.rect = flag_res.rect.move(click_move);
Rect role_rect = flag_res.rect.move(role_move);
Rect role_rect = correct_rect(flag_res.rect.move(role_move), m_image);
oper.role = oper_role_analyze(role_rect);
if (oper.role == battle::Role::Unknown) {
Log.warn("Unknown role");
@@ -113,10 +113,10 @@ std::vector<battle::DeploymentOper> BattlefieldMatcher::deployment_analyze() con
if (oper.rect.x + oper.rect.width >= m_image.cols) {
oper.rect.width = m_image.cols - oper.rect.x;
}
Rect avatar_rect = oper.rect.move(avatar_move);
Rect avatar_rect = correct_rect(oper.rect.move(avatar_move), m_image);
oper.avatar = m_image(make_rect<cv::Rect>(avatar_rect));
Rect available_rect = flag_res.rect.move(avlb_move);
Rect available_rect = correct_rect(flag_res.rect.move(avlb_move), m_image);
oper.available = oper_available_analyze(available_rect);
#ifdef ASST_DEBUG
@@ -310,12 +310,7 @@ BattlefieldMatcher::MatchResult<std::pair<int, int>> BattlefieldMatcher::kills_a
}
if (kills_text.length() <= pos + 1) {
Log.error(
"kills_text length is too short: text='{}', length={}, pos={}",
kills_text,
kills_text.size(),
pos
);
Log.error("kills_text length is too short: text='{}', length={}, pos={}", kills_text, kills_text.size(), pos);
return {};
}

View File

@@ -81,6 +81,7 @@ Rect VisionHelper::correct_rect(const Rect& rect, const cv::Mat& image)
return rect;
}
if (rect.empty()) {
LogWarn << __FUNCTION__ << "roi is empty, use whole image";
return { 0, 0, image.cols, image.rows };
}
if (rect.x >= image.cols || rect.y >= image.rows || rect.x + rect.width < 0 || rect.y + rect.height < 0) {

View File

@@ -221,6 +221,10 @@ public class Bootstrapper : Bootstrapper<RootViewModel>
_logger.Information("Crash dumps are copied to {DumpDir}", dumpDir);
}
}
else
{
_logger.Information("%LocalAppData%/CrashDumps not found");
}
string[] lines = File.ReadAllLines(crashFile, Encoding.UTF8);

View File

@@ -48,9 +48,7 @@
{
"name": "macos-arm64",
"displayName": "macOS arm64 Release",
"$comment": [
"see .github/workflows/res-update-game.yml"
],
"$comment": ["see .github/workflows/res-update-game.yml"],
"generator": "Ninja",
"binaryDir": "${sourceDir}/build",
"cacheVariables": {