Compare commits

..

179 Commits

Author SHA1 Message Date
zzyyyl
78c1ff3a5c docs: 公式格式 2025-09-26 15:56:14 +08:00
zzyyyl
53052833f4 docs: 增加 任务流程文档 - 表达式计算 小节中对运算符的描述;将虚任务移至表达式计算小节 2025-09-26 15:41:51 +08:00
zzyyyl
cd17cced22 feat: 不允许虚任务作为 @ 运算的左元 2025-09-26 15:41:35 +08:00
uye
a8ef1420b6 Release v5.26.0-beta.1 (#14231) 2025-09-26 14:13:39 +08:00
github-actions[bot]
1d7a893950 docs: Auto Update Changelogs of v5.26.0-beta.1 (#14232)
* docs: Auto Generate Changelog of Release v5.26.0-beta.1

* docs: Refactor CHANGELOG to remove duplicates and update entries

Removed duplicate entries and updated various documentation items in the CHANGELOG.

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: uye <99072975+ABA2396@users.noreply.github.com>
2025-09-26 14:11:43 +08:00
pre-commit-ci[bot]
ef8964e0a7 chore: Auto update by pre-commit hooks [skip changelog] 2025-09-26 06:02:15 +00:00
Wallsman
775c640dba docs: Update JP(#14227)
* Update readme.md

Doc: Text sync chinese.

* Update others.md

Doc: Sync text for Chinese.

* Update copilot.md

Doc: Sync Text for Chinese.

* Update reclamation-algorithm.md

Doc: Text sync for Chinese.

* Update rewards.md

Doc: Sync text for Chinese.

* chore: Auto update by pre-commit hooks [skip changelog]

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-09-26 13:58:54 +08:00
github-actions[bot]
634ebb55db chore: Auto Templates Optimization
Triggered by 5ac171d40c

[skip changelog]
2025-09-26 05:58:00 +00:00
uye
5ac171d40c feat: 次生预案十里坡剑神 2025-09-26 13:57:33 +08:00
Constrat
0ae323c855 fix: Google Play Games Developer shutdown 2025-09-26 01:24:57 +02:00
MistEO
8aaba7d60e fix: manual set resource version time 2025-09-26 00:58:36 +08:00
github-actions[bot]
caed828770 chore: Auto Templates Optimization
Triggered by 3f252eb12e

[skip changelog]
2025-09-25 08:50:39 +00:00
github-actions[bot]
3f252eb12e chore: Auto Update Game Resources - 2025-09-25
https://github.com/MaaAssistantArknights/MaaAssistantArknights/actions/runs/18002097304

[skip changelog]
2025-09-25 08:49:14 +00:00
Manicsteiner
e8051a6a39 chore: YostarJP Sarkaz roguelike StageEncounter (#14223) 2025-09-25 00:17:07 +02:00
Rbqwow
e0860ed779 docs: 补充vsc插件繁中文档
refer to a872081615
2025-09-23 14:32:12 +00:00
Rbqwow
1324165cfe docs: 修复文档站readme盾换行 2025-09-23 13:58:15 +00:00
Lucien Shaw
96aa7ada11 docs: 调整文档站的标题和尾注文本显示 (#14213)
* chore: 更新plume主题版本

* chore: 更新文档站尾注配置

* i18n: 调整多语言的默认网站标题

* docs: 调整首页的网页标题

* docs: 文档站首页MAA标题加阴影
2025-09-23 21:36:58 +08:00
Rbqwow
ca3160bd72 docs: 更新网页开发相关文档 (#14167)
* docs: vuepress-theme-hope --> vuepress-theme-plume

* docs: website --> docs

* chore: 添加 preview 图片

* feat: 添加回图片相关插件

* perf: logo 超级压缩

* perf: preview 也超级压缩

* docs: 找 GPT-5 Thinking 翻译了一下日语的本地部署

* chore: 预览图还是得走一下网页镜像

* i18n: JP

* docs: 修复损坏的超链接

* chore: Auto update by pre-commit hooks [skip changelog]

* chore: 这东西是怎么混进来的

---------

Co-authored-by: Manicsteiner <Manicsteiner@outlook.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-09-23 17:49:19 +08:00
Manicsteiner
c3bac8b504 chore: YostarJP sami roguelike 720p (#14210) 2025-09-23 10:53:52 +02:00
zzyyyl
642c62498c docs: 完善任务流程协议文档 (#13232)
* docs: 完善任务流程协议文档

* docs: English version of task-schema.md

* docs: markdown-lint
2025-09-23 14:21:37 +08:00
zzyyyl
56cf52808d docs: markdown pre-commit 2025-09-23 14:16:39 +08:00
pre-commit-ci[bot]
5d47ede186 chore: Auto update by pre-commit hooks [skip changelog] 2025-09-23 13:52:02 +08:00
萨拉托加
a48fe44663 chore: 水月萨米肉鸽不期而遇避战
fix #14207
2025-09-23 13:32:47 +08:00
nekosu
a872081615 docs: add extension's evaluating feature 2025-09-23 11:43:42 +08:00
Constrat
485ef8fcbf fix: prettier 2025-09-23 00:28:47 +02:00
Manicsteiner
c450e596f7 chore: YostarJP Mizuki StageEncounter (#14206) 2025-09-22 23:27:18 +02:00
SherkeyXD
f9c16319a8 docs: 回调消息协议文档视觉更新 2025-09-23 03:01:56 +08:00
SherkeyXD
5db20fe2c4 docs: 集成文档视觉更新 2025-09-23 02:41:13 +08:00
SherkeyXD
e12c7f948d docs: 文档启用b站视频播放功能 2025-09-23 02:03:57 +08:00
SherkeyXD
cb546b4370 docs: 文档添加字段容器功能 2025-09-23 02:01:29 +08:00
SherkeyXD
c193b26b62 docs: 文档添加功能 2025-09-23 01:56:38 +08:00
SherkeyXD
91c8a22d1c docs: 更新文档编写指南 2025-09-23 01:56:38 +08:00
SherkeyXD
b8205b5593 docs: add telegram icon 2025-09-23 01:56:38 +08:00
MistEO
68248df197 docs: 标题MAA统一采用缩写 2025-09-23 01:41:48 +08:00
MistEO
db98bb370e chore: 再次调整文档站标题( 2025-09-23 01:35:56 +08:00
MistEO
bf2375a44f chore: 调整文档站标题 2025-09-23 01:32:20 +08:00
Rbqwow
d12fb7d565 refactor: devcontainer.json (#14169)
* chore: cleanup devcontainer.json

* chore: 配置devcontainer环境

* build: 更新conda配置

* chore: 更新pnpm包的安装允许列表

---------

Co-authored-by: Lucien Shaw <myxlc55@outlook.com>
2025-09-23 00:53:41 +08:00
Lucien Shaw
9838dec4fd fix: 文档首页语言选择按钮的宽度定义方式 (#14199) 2025-09-22 22:11:54 +08:00
uye
793d03d47b feat: 设置指引添加更新设置 2025-09-22 20:31:35 +08:00
uye
56d796c92e feat: 统一显示效果 2025-09-22 19:36:00 +08:00
uye
aae995aef5 feat: 设置指引添加性能设置 2025-09-22 19:36:00 +08:00
萨拉托加
9159e5d979 fix: 傀影肉鸽无法识别四结局 (#14193)
* fix: 傀影肉鸽无法识别四结局

既然MAA能打就加个模板比较好?

* chore: Auto update by pre-commit hooks [skip changelog]

* chore: 四结局必要不期而遇进战斗

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-09-22 16:27:54 +08:00
萨拉托加
705c5a4c68 fix: GamePassSkip2识别到错误的跳过
看录屏发现的,GamePassSkip1之后可能会出现一个一闪而过的GamePassSkip2被maa识别到,好抽象
2025-09-22 16:14:37 +08:00
Rbqwow
a563b14f47 refactor: 重写完成后动作仅一次的ui字符串 (#14196) 2025-09-22 14:44:49 +08:00
uye
400fd6bf53 chore: 贸易站没其他好用的人再用锏 2025-09-21 19:07:33 +08:00
萨拉托加
2915338cac fix: 萨米肉鸽不期而遇避战
fix #14192
2025-09-21 16:53:48 +08:00
uye
09dc393c98 docs: Update CHANGELOG with recent changes and fixes 2025-09-21 14:06:55 +08:00
uye
0650cdb64e Release v5.25.0 (#14184) 2025-09-21 13:54:51 +08:00
github-actions[bot]
385c521eb4 docs: Auto Update Changelogs of v5.25.0 (#14185)
* docs: Auto Generate Changelog of Release v5.25.0

* docs: 更新 v5.25.0 版本变更日志,增加自动战斗和基建换班功能的优化说明

* docs: 更新 v5.25.0 版本变更日志,增加对自动战斗和基建换班功能的详细说明

* docs: 修复 CHANGELOG.md 中的格式问题

* docs: 修复 CHANGELOG.md 中的拼写错误

* docs: Update dependencies and change CDN provider

Updated project dependencies and switched to a new CDN provider for improved access speed.

* docs: 更新依赖库并更换官网和 API 节点的 CDN 提供商,优化访问速度

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: AnnAngela <naganjue@vip.qq.com>
Co-authored-by: uye <99072975+ABA2396@users.noreply.github.com>
2025-09-21 13:54:32 +08:00
萨拉托加
a37a74a4e2 fix: 现买现印选项
fix #14188
2025-09-21 12:22:02 +08:00
MistEO
1d2d49920a chore: 整理文档站 social 链接 2025-09-21 11:40:23 +08:00
MistEO
da82e14efc chore: 删除文档站不知道有啥用的文件? 2025-09-21 11:36:01 +08:00
MistEO
ad9103ea12 docs: 修改文档站导航栏跳转 2025-09-21 11:35:47 +08:00
nekosu
26296b3b82 docs: Maa Pipeline Support 扩展文档 (#14110)
* doc: cache

* doc: vsc ext doc skeleton

* fix: svg ref

* doc: optimize

* docs: 在任务流程协议文档中添加扩展使用提示

* docs: add en translation

* docs: 补充跳转超链接

---------

Co-authored-by: Rbqwow <55343783+Rbqwow@users.noreply.github.com>
2025-09-21 04:31:14 +08:00
Constrat
72ba949f1c chore: remove comment on script 2025-09-20 21:22:47 +02:00
Constrat
1102771ea1 ci(tools): add stale cache cleanup script 2025-09-20 20:48:51 +02:00
Constrat
9d9f95ea4a i18n: fix english for main page 2025-09-20 20:48:36 +02:00
MistEO
0e33a53068 feat: add docs icon 2025-09-21 01:05:26 +08:00
uye
081c0b7597 chore: 调整 锏 基建技能效率 2025-09-20 19:46:52 +08:00
uye
e3de09ddcc Release v5.25.0-beta.5 (#14180)
准备发正式版了,这个之后先别进 pr
2025-09-20 14:19:34 +08:00
github-actions[bot]
81e22e5bf9 docs: Auto Update Changelogs of v5.25.0-beta.5 (#14181)
* docs: Auto Generate Changelog of Release v5.25.0-beta.5

* docs: Update CHANGELOG with recent fixes and enhancements

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: uye <99072975+ABA2396@users.noreply.github.com>
2025-09-20 14:17:20 +08:00
uye
424687c3e1 fix: 成就列表解锁时间显示颜色错误 2025-09-20 14:08:34 +08:00
uye
94e6fabb76 fix: GO 导航 2025-09-20 14:02:41 +08:00
uye
8d346ed392 fix: 勾选启动后直接运行时无法自动切换基建排班表
fix #14173
2025-09-20 13:51:16 +08:00
soundofautumn
fd3204e965 chore: fix build warning (#14176)
0>RunningState.cs(49,46): Warning CS8622 : “void RunningState.TimeoutReminderTimer_Elapsed(object sender, ElapsedEventArgs e)”的参数“sender”类型中引用类型的为 Null 性与目标委托“ElapsedEventHandler”不匹配(可能是由于为 Null 性特性)。
0>RunningState.cs(41,17): Warning CS8618 : 在退出构造函数时,不可为 null 的 事件 "TimeoutOccurred" 必须包含非 null 值。请考虑添加 "required" 修饰符或将该 事件 声明为可为 null。
0>RunningState.cs(80,46): Warning CS8625 : 无法将 null 字面量转换为非 null 的引用类型。
0>RunningState.cs(80,52): Warning CS8625 : 无法将 null 字面量转换为非 null 的引用类型。
0>RunningState.cs(38,37): Warning CS8618 : 在退出构造函数时,不可为 null 的 字段 "_instance" 必须包含非 null 值。请考虑添加 "required" 修饰符或将该 字段 声明为可为 null。
2025-09-20 13:43:07 +08:00
uye
7109310145 fix: 网络连接错误的情况下读取了本地缓存也提示了获取热更成功 2025-09-20 13:38:48 +08:00
soundofautumn
a424520a1d chore: rename RecognizerViewModel -> ToolboxViewModel (#14177)
* chore: rename RecognizerView -> ToolboxView

* chore: 重新排序顺序使得和ui顺序一致
2025-09-20 13:37:53 +08:00
github-actions[bot]
b98ae1be2d chore: Auto Update Game Resources - 2025-09-20
https://github.com/MaaAssistantArknights/MaaAssistantArknights/actions/runs/17875323432

[skip changelog]
2025-09-20 04:31:07 +00:00
萨拉托加
5eaf466128 fix: 萨米肉鸽未通关结局时探寻前路卡住 2025-09-19 17:21:41 +08:00
github-actions[bot]
8dc7893459 chore: Auto Update Game Resources - 2025-09-19
https://github.com/MaaAssistantArknights/MaaAssistantArknights/actions/runs/17853878149

[skip changelog]
2025-09-19 09:09:19 +00:00
MistEO
e891471750 ci: remove website aws config 2025-09-19 15:23:24 +08:00
Lucien Shaw
9014a20c25 fix: 文档站首页在窄屏下的响应式设计 (#14166) 2025-09-19 15:14:16 +08:00
Lucien Shaw
4280d9356a fix: 暂时修复无法读取过去的评论的问题 (#14163) 2025-09-19 14:41:33 +08:00
Manicsteiner
b8e739bcad chore: YostarJP ocr fix (#14134)
* chore: YostarJP ocr fix

* chore: item30165, ja-jp xaml, 随到随取

* i18n: RA task mode
2025-09-19 11:36:02 +08:00
Constrat
f9c76d4995 fix: Eye For an Eye encounter IS2 EN 2025-09-19 00:42:52 +02:00
Lucien Shaw
28ca820784 docs: 完善文档站的代码检查和涉及的文本替换 (#14156)
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-09-18 23:53:59 +08:00
Lucien Shaw
d8dbec69ca docs: 完善自动肉鸽和其它文档中的部分内容 (#13924)
* docs: 在中文文档的连接设置中添加一处关于隐藏目录的提示

* docs: 在中文的自动肉鸽文档中完善关于蓝图测绘分队的提示

* i18n: EN is.md

* i18n: connetion for all

* docs: ko-kr is

* docs: kr fix typo

* docs: 完善了英文的自动肉鸽文档中的部分措辞

修改部分开局推荐提示的措辞和语法,使其和表格中的其它提示一致
使用罗马数字专用符号`Ⅱ`代替两个拉丁字母`II`

* docs: 更新繁体中文自动肉鸽文档中的开局推荐

* docs: 更正三种语言自动肉鸽文档中的傀影肉鸽开局推荐难度

更正简中、英文、韩文的自动肉鸽文档中傀影肉鸽开局推荐难度(繁中文档不适用;日文文档没有这一部分)

* docs: 只是改个语序

* i18n: JP

* docs: 调整简中和日语的自动肉鸽文档的表格缩进

* docs: 在繁中的自动肉鸽文档中添加最后更新日期

---------

Co-authored-by: Constrat <56174894+Constrat@users.noreply.github.com>
Co-authored-by: HX3N <scarlet7518@gmail.com>
Co-authored-by: Rbqwow <55343783+Rbqwow@users.noreply.github.com>
Co-authored-by: Manicsteiner <Manicsteiner@outlook.com>
2025-09-18 23:26:23 +08:00
SherkeyXD
ada9b0849b docs(rft): 切换文档主题至 vuepress-theme-plume (#13821)
Co-authored-by: Lucien Shaw <myxlc55@outlook.com>
Co-authored-by: MistEO <mistereo@hotmail.com>
2025-09-18 18:26:14 +08:00
uye
99e64b3ea8 chore: 调整会客室中更容易获得线索板上尚未拥有的线索的技能优先级 2025-09-18 18:01:26 +08:00
uye
e7be333557 chore: 基建把 u酱 ban 了 2025-09-18 15:38:03 +08:00
github-actions[bot]
8da2271af1 chore: Auto Templates Optimization
Triggered by 7b58ddee5b

[skip changelog]
2025-09-18 07:01:41 +00:00
uye
7b58ddee5b fix: 为什么 mujikca 的图黑的不够纯粹 2025-09-18 14:51:36 +08:00
萨拉托加
fcfa9c033c fix: 肉鸽在结算界面卡死 (#14145)
* fix: 肉鸽通关后有概率无法跳过剧情导致卡死或出错

有概率无法跳过卡在Roguelike@ClickToStartPoint里

* chore: Auto update by pre-commit hooks [skip changelog]

* fix: 肉鸽还是卡结算界面,改一下ClickToStartPoint位置

* fix: 导航肉鸽时有概率识别到回弹动画状态的入口

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-09-18 14:41:41 +08:00
Loong
1992af7159 feat: cli 支持新版战斗列表以及悖论模拟 (#14154)
chore: bump maa-cli to 0.5.9
2025-09-18 14:38:54 +08:00
Constrat
a6b5101e0c ci: update cache scripts 2025-09-18 02:20:27 +02:00
github-actions[bot]
e03a96774d chore: Auto Update Game Resources - 2025-09-17
https://github.com/MaaAssistantArknights/MaaAssistantArknights/actions/runs/17809390023

[skip changelog]
2025-09-17 20:08:55 +00:00
status102
261ddc49d9 fix(core): CopilotTask参数可选项存在性检查 2025-09-18 00:43:17 +08:00
Lucien Shaw
bb735b6ee7 feat: 为官网首页添加多语言支持 (#13943)
* build: 引入react i18n组件

* i18n: 加载多语言支持模块

* i18n: 添加语言切换按钮

* i18n: 添加网页下载按钮多语言支持

* build: 更新typescript依赖

* fix: 修复callback导致语言切换不生效的问题

* i18n: 完成首页所有元素的多语言支持

* chore: 删除冗余代码

* i18n: 优化了语言切换按钮的交互逻辑并添加多语言占位符

* chore: 规范了部分代码的格式并删除冗余代码

* i18n: ko-kr

* chore: kr 미러 to mirror

* fix: 修复检测和切换语言的问题

* chore: 调整了尾注用户协议部分的显示方式

* refactor: 更改首页尾注的显示方式

* style: 统一Trans元素为self-close样式

* i18n: zh-tw

* fix: 修复换行和块之间的空格问题并补上缺失的翻译

* feat: 更改首页语言也会同步更改文档按钮对应的链接

* refactor: 将弃用的MutableRefObject替换为RefObject

* feat: 语言切换按钮的选项使用对应的语言渲染

* feat: 统一管理所有语言信息并开放读取语言接口

* fix: 去除按钮在鼠标悬停时出现的下划线

* style: 统一不使用行尾分号

* build: 更新部分依赖

* fix: 修正不成对的Trans块对应的本地化文本

* feat: 移动设备横屏浏览时出现垂直滚动条

移动设备横屏时,可能仍能出现下载按钮,全部展开时可能过高,此时出现垂直滚动条,方便用户浏览所有内容

* i18n: JP

* fix: 强制隐藏下载链接容器的水平滚动条

* fix: 将下载链接容器设置为占满宽度

* i18n: JP edits

* fix: 修复滚动条引起的上端裁切问题

* feat: action按钮组根据实际宽度调整布局

不再依靠md:xxx的固定阈值区分小屏和中屏及以上,而是根据不同语言的按钮宽度动态计算是否溢出,从而决定排布方式

* feat: 使用上下文管理布局

使用layoutStateContext来管理布局相关状态,主要是宽度溢出检测

* fix: Copilot 说我们是小驼峰

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

* perf: Copilot 说我们不再需要下划线和它的偏移
我还是第一次知道这里下划线这么难看

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

* feat: 把别的按钮样式抄到语言切换按钮上

* style: 复活 Prettier

这 Prettier 什么鬼情况
我没有要求你把所有文件都格式化,我不是恶魔,后面忘了,总之我可能得狠狠恢复你了。真的。
所以这缩进怎么又 2 又 4 的

* chore: Auto update by pre-commit hooks [skip changelog]

* refactor: 更改副标题和尾注的元素class以优化动画和显示

* style: 将typescript代码文件的缩进统一为2

* fix: 改正测速进行中的i18n key

* refactor: 删除link类的下划线css定义

* build: 更新prettier依赖和相关配置

* style: prettier美化

* chore: 尝试规避github ci找不到插件的错误

* chore: Auto update by pre-commit hooks [skip changelog]

* refactor: 使用.prettierrc.js管理官网相关文件的美化配置

* refactor: 暂时取消自动import排序美化

* fix: 下载按钮动画问题

* feat: 响应式设计测量宽度时,临时隐藏相关元素

* style: prettier

* refactor: 下载按钮组居中对齐

* feat: 让系统架构提示动画从上到下

* refactor: 优化第二行按钮动画

* refactor: 优化协议部分文本动画

* i18n: 为一句过长的日语添加换行符

* fix: 修复进度条样式

* refactor: 不将i18n作为触发器

* chore: 首页图片资源文件路径变更

* chore: 添加多语言图片占位

* i18n: 首页图片支持多语言切换

* chore: 更新日文的首页截图

* chore: Auto update by pre-commit hooks [skip changelog]

* fix: 在首页的文档链接后补全斜杠

* chore: 更新prettier的EOL设置

* style: prettier美化

* chore: pre-commit复活

* refactor: 统一languageFilename变量名

* refactor: 移除加载截图模块的dead code

* i18n: 为mirrorchyan的跳转链接添加多语言支持

mirrorchyan提供简中和英语,因此其他语言需要fallback到二者之一。
- 繁体中文跳转到简体中文
- 日语和韩语跳转到英文

* fix: dead code删除不彻底

* i18n: 去除除了简中以外的”海外源“字样

* i18n: 规范化简中和繁中的locale文本

* i18n:调整英文文本的语法和表达

* i18n: 规范化日文文本

* chore: prettier

* i18n: KR screenshot

* i18n: txwy screenshot

* chore: Auto update by pre-commit hooks [skip changelog]

* i18n: zh-tw tweak

* refactor: mirror酱相关的两处key更名

* docs: 优化中文和英文的部分语句表达方式

Linux 下载那句我怎么看怎么觉得怪
我想改成 `下载完成(Linux 版本仅包含动态库与资源文件)` `Download completed (Linux version includes dynamic libraries and resource files only)`
但感觉改完也很怪

感觉不如把这俩直接换成 CLI 的下载

* i18n: fix version info loading error message and pluralize downloads for zh-cn

* chore: update en-us screens dark and light

* chore: Auto update by pre-commit hooks [skip changelog]

* fix: focus

* chore: Auto update by pre-commit hooks [skip changelog]

* refactor: 去除多余类型标记

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

---------

Co-authored-by: HX3N <scarlet7518@gmail.com>
Co-authored-by: momomochi987 <as99us301@gmail.com>
Co-authored-by: Manicsteiner <Manicsteiner@outlook.com>
Co-authored-by: Rbqwow <55343783+Rbqwow@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Constrat <56174894+Constrat@users.noreply.github.com>
2025-09-17 21:19:07 +08:00
uye
c54b45c09f fix: SettingsViewModel Idle 2025-09-17 17:54:19 +08:00
萨拉托加
eb061dcc59 fix: 异格推王的基建加成错误 2025-09-17 16:32:14 +08:00
uye
bc7dc763fe feat: RunningState 统一状态变更事件 (#14141)
* feat: RunningState 统一状态变更事件

* feat: 统一 Inited 与 Stopping

* perf: 优化小工具中的stop
2025-09-17 14:06:51 +08:00
github-actions[bot]
3bfc2662e3 chore: Auto Update Game Resources - 2025-09-16
https://github.com/MaaAssistantArknights/MaaAssistantArknights/actions/runs/17773963424

[skip changelog]
2025-09-16 17:29:14 +00:00
status102
f4c21be051 chore: file header 2025-09-17 00:57:06 +08:00
status102
2936006087 rft: 特征匹配过程函数拆入analyze() 2025-09-17 00:53:23 +08:00
github-actions[bot]
efa364043d chore: Auto Update Game Resources - 2025-09-16
https://github.com/MaaAssistantArknights/MaaAssistantArknights/actions/runs/17772582080

[skip changelog]
2025-09-16 16:33:32 +00:00
Weiyou Wang
7b6dada3ea feat: 生息盐酸任务添加对错误模式 (有/无存档) 的提示 (#14131)
* feat: 生息盐酸任务添加对错误模式 (有/无存档) 的提示

* fix: callback 里任务名没有前缀
2025-09-17 00:26:28 +08:00
Weiyou Wang
be3b1a2057 fix: 调低 MacOS PlayCover 下对 InfrastControl 识别的阈值 (#14139) 2025-09-17 00:21:20 +08:00
status102
67ceb02116 fix: CurrentConfig未刷新 2025-09-17 00:07:32 +08:00
status102
aa7a2731e0 fix: CurrentConfig悬空 2025-09-17 00:07:32 +08:00
uye
df8f3786f0 fix: 拥有全干员的情况下重启后进入干员识别界面不会自动选中选项卡 2025-09-16 23:48:49 +08:00
uye
20b167119a fix: 修复 DataGrid 虚拟化下 Tab 导航异常 2025-09-16 23:44:27 +08:00
Constrat
b1f02a2eb5 fix(ci): download to v5 with necessary fix (#14122)
fix: specify path for download v5
2025-09-16 16:41:19 +02:00
HY
f9e424cd3b chore: 繁中服「相見歡」活動導航 (#14137)
* chore: 繁中服「相見歡」活動導航

* chore: 再改 再改
2025-09-16 16:37:22 +02:00
萨拉托加
5eecbe21c1 fix: 萨卡兹肉鸽未通关结局时原初异途卡住
fix #14133
2025-09-16 18:38:49 +08:00
MistEO
32a3523bc4 feat: use coreml OCR for apple (#14108) 2025-09-16 18:20:10 +08:00
github-actions[bot]
7dd2dbdcbe chore: Auto Update Game Resources - 2025-09-16
https://github.com/MaaAssistantArknights/MaaAssistantArknights/actions/runs/17759820697

[skip changelog]
2025-09-16 08:33:34 +00:00
github-actions[bot]
27f9df768d chore: Auto Update Game Resources - 2025-09-16
https://github.com/MaaAssistantArknights/MaaAssistantArknights/actions/runs/17758555824

[skip changelog]
2025-09-16 07:44:48 +00:00
萨拉托加
2350a05fc4 fix: 肉鸽深入探索无法退出结算界面 (#14123) 2025-09-15 23:03:04 +08:00
soundofautumn
3ea9912802 chore: fix build warning (#14120) 2025-09-15 23:00:34 +08:00
uye
a9e31c75d0 Release v5.25.0-beta.4 (#14126) 2025-09-15 22:49:41 +08:00
uye
4e46a392a3 docs: Update CHANGELOG for v5.25.0-beta.4
Updated changelog for version 5.25.0-beta.4 with new features and fixes.
2025-09-15 22:48:52 +08:00
pre-commit-ci[bot]
2f09f9e591 chore: Auto update by pre-commit hooks [skip changelog] 2025-09-15 14:43:19 +00:00
uye
55f675fb8d fix: minitouch 触控 wait ms 2025-09-15 22:38:35 +08:00
uye
36fc9a8e0a fix: 复核自定义干员时等待游戏动画 2025-09-15 22:11:05 +08:00
Constrat
cfd463a7fd fix: wrong default on type number 2025-09-15 14:09:40 +02:00
uye
2884f2d0ae fix: 自动战斗无法读取下拉列表中的作业 2025-09-15 19:52:42 +08:00
MistEO
0af752b083 Release v5.25.0-beta.3 (#14115) 2025-09-15 16:50:34 +08:00
MistEO
212cb506d6 docs: changelog version 2025-09-15 16:50:13 +08:00
MistEO
6ed32b3344 docs: changelog 2025-09-15 16:49:32 +08:00
MistEO
4a2901c473 ci: fix minitouch scale 2025-09-15 16:43:58 +08:00
MistEO
18bec2504d ci: add create issue 2025-09-15 15:28:04 +08:00
MistEO
7c4002351e ci: use download-artifact v4 2025-09-15 15:28:04 +08:00
MistEO
4e0b5ace24 Release v5.25.0-beta.2 (#14111) 2025-09-15 15:00:10 +08:00
github-actions[bot]
acfb173cc3 docs: Auto Update Changelogs of v5.25.0-beta.2 (#14112)
* docs: Auto Generate Changelog of Release v5.25.0-beta.2

* docs: changelog

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: MistEO <mistereo@hotmail.com>
2025-09-15 14:58:02 +08:00
MistEO
feb7b6109f ci: fix win zip 2025-09-15 14:02:35 +08:00
MistEO
552d7784a2 ci: add zip for win ci and create issue if failed release 2025-09-15 13:37:59 +08:00
status102
b1d10a87dc perf: 加个try先 2025-09-15 13:19:19 +08:00
Constrat
30bb86bade ci(fix): try to color only [err] log as red 2025-09-15 01:36:04 +02:00
MistEO
80511c660f ci: split cmake file (#14109) 2025-09-15 04:18:40 +08:00
mistereo@hotmail.com
45ca28ed74 chore: remove SyncRes 2025-09-15 03:07:17 +08:00
MistEO
a208c1f03b ci: set hash version 2025-09-15 02:31:32 +08:00
Status102
5b33bc3f00 feat: 自动战斗多作业支持保存干员组内编入的干员 (#14095)
* chore: 加个存储先

* feat: 与旧编队比较

* feat: 快速编队

* fix: 计数

* fix: 缓存了旧的组名

* perf: 快速退出

* fix: 跳过编队后修改编队状态

* fix: 完事

* fix: err

* fix: 顺手一起修了
2025-09-15 01:27:51 +08:00
MistEO
6202eedeb3 refactor: use std::format instead of sprintf (#14107)
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-09-15 01:07:05 +08:00
Constrat
a70502521d ci:. standardize cache key for nuget cache 2025-09-14 18:55:13 +02:00
Constrat
66a5095ede ci: standardize hash for windows maadeps 2025-09-14 18:52:20 +02:00
Constrat
5b750ca194 fix: smoke-testing script 2025-09-14 18:48:47 +02:00
uye
b18e4e6ff6 Release v5.25.0-beta.1 (#14100) 2025-09-15 00:41:06 +08:00
MistEO
31761d7e5d ci: refactor res_updater cmake (#14106)
* ci: refactor res_updater cmake

* ci: remove ResourceUpdater from main cmake

* ci: typos

* build: remove boost

* ci: fix deps and cmake config

* ci: add zsh script

* chore: fix res_updater

* chore: use -Wno-error for res_updater

* fix: perms for version.zsh

* fix: gitignore

* fix: script

---------

Co-authored-by: Constrat <56174894+Constrat@users.noreply.github.com>
2025-09-14 18:33:40 +02:00
github-actions[bot]
c881362cb1 docs: Auto Update Changelogs of v5.25.0-beta.1 (#14101)
* docs: Auto Generate Changelog of Release v5.25.0-beta.1

* docs: Update CHANGELOG with recent changes and fixes

* docs: Update button click behavior in battle list settings

* docs: Update CHANGELOG with recent changes and fixes

* docs: changelog

* docs: Update CHANGELOG with recent changes and fixes

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: uye <99072975+ABA2396@users.noreply.github.com>
Co-authored-by: Status102 <102887808+status102@users.noreply.github.com>
2025-09-15 00:32:40 +08:00
uye
00e5c1eb9f chore: 自定义基建配置时间仍在有效期内时不检查其他时间段 2025-09-15 00:26:33 +08:00
Constrat
7e3ab62aae fix: typo 2025-09-14 17:56:32 +02:00
Constrat
b0713bb9df Merge branch 'dev' of https://github.com/MaaAssistantArknights/MaaAssistantArknights into dev 2025-09-14 17:55:19 +02:00
Constrat
42343f8978 fix: type number for nightly ota 2025-09-14 17:55:12 +02:00
MistEO
e9383a7783 build: do not auto gen version for local build 2025-09-14 23:28:08 +08:00
status102
e0ee76115b feat: CustomTask增加任务存在检测 2025-09-14 21:45:43 +08:00
Constrat
d6bf677bb1 ci: add caching for macos maadeps 2025-09-14 14:32:51 +02:00
MistEO
746816c6c7 ci: try macos for smoke_test (#14104)
* ci: try macos for smoke_test

* ci: Remove concurrency from smoke-testing workflow

* ci: use ninjga build for macos testing

* ci: add trigger

* ci: fix macos parallel

* ci: update bash

* fix: zsh script

* fix: perms

* fix: zsh script regular array

* ci: add resource link for cache hit

* test: enable dev for testing

* test: revert test

---------

Co-authored-by: Constrat <56174894+Constrat@users.noreply.github.com>
2025-09-14 14:22:15 +02:00
nekosu
4d74abfd8f feat: custom clang (#14102)
* feat: custom clang

* fix: version typo

* fix: version typo
2025-09-14 12:35:40 +02:00
萨拉托加
5853354357 chore: 界园萨卡兹肉鸽招募休谟斯优先级 2025-09-14 17:54:08 +08:00
Status102
022ab93c1c ci: 为smoke-testing使用cache时增加resource链接 (#14096)
Co-authored-by: MistEO <mistereo@hotmail.com>
2025-09-14 17:30:30 +08:00
github-actions[bot]
cd8d22d23e chore: Auto Update Game Resources - 2025-09-14
https://github.com/MaaAssistantArknights/MaaAssistantArknights/actions/runs/17708701640

[skip changelog]
2025-09-14 08:30:48 +00:00
pre-commit-ci[bot]
da1170ecc9 chore: Auto update by pre-commit hooks [skip changelog] 2025-09-14 08:25:54 +00:00
uye
df46d6bcb0 chore: 更新基建技能效率 2025-09-14 16:20:15 +08:00
Litwak913
bf27a7fc86 fix: 修复 cmake copy_and_add_rpath_library 的失败逻辑 (#14097) 2025-09-14 06:39:06 +08:00
Constrat
482f21620e chore: remove -DINSTALL_RESOURCES 2025-09-13 18:01:40 +02:00
uye
1472d80c12 fix: 刷开局奖励只选票券时行为异常
fix #14079
2025-09-13 21:12:09 +08:00
Constrat
5bfc5fce9f fix: smoke testing upload logs 2025-09-13 15:05:52 +02:00
Constrat
dcd2d52a5a fix: move smoke testing working dir 2025-09-13 14:55:15 +02:00
uye
2c87975e52 feat: core 崩溃后下次启动时 ui 输出提示 (#14022)
* feat: core 崩溃后下次启动时 ui 输出提示

* style: space

* chore: ubuntu warning

* i18n: zh-tw

---------

Co-authored-by: momomochi987 <as99us301@gmail.com>
2025-09-13 20:28:56 +08:00
status102
e3245a4163 feat(wpf): allow single copilot task execution
有人炸就派uuu @ABA2396
2025-09-13 20:02:58 +08:00
status102
43ea1f94df perf(wpf): wpf自动战斗列表中作业设置按钮左键单击还原为解析指定作业,新增行为修改至右键,解析作业并关闭列表 2025-09-13 19:57:37 +08:00
status102
1077b08c19 fix: 自动编队缺少干员输出的额外换行 2025-09-13 19:53:18 +08:00
status102
d02393f174 fix(core): Copilot多任务编队时编队设置残留 2025-09-13 19:35:52 +08:00
uye
bc59477b24 fix: 自定义基建换班的班次不会随时间切换
fix #14092
2025-09-13 16:03:53 +08:00
uye
e4cb99c0c0 fix: "统一 WpfGui 工作目录"后,配置为外服无法运行 MAA
fix #14090
2025-09-13 15:42:39 +08:00
Status102
e65219efc5 fix: 移除 debug_demo (原Sample) 的对应 resource 额外查找逻辑 (#14081)
* rft: resource链接生成移动至cmake

* fix: smoke

* fix: smoke

* fix: smoke

* chore: 干脆移除掉好了

* chore: remove blank line

* fix: 移除多余链接创建

* perf: use DINSTALL_RESOURCE

* build: 整理cmake util函数

* chore: wpf link resource由cmake进行

* Revert "chore: wpf link resource由cmake进行"

This reverts commit 0e973734e7.

---------

Co-authored-by: MistEO <mistereo@hotmail.com>
2025-09-13 12:24:22 +08:00
uye
8bffeaa368 chore: 调整 y 存图时间间隔 2025-09-13 12:01:17 +08:00
uye
b017e90b6b feat: 给自定义任务添加 ScreenshotTaskPlugin 插件 2025-09-13 11:16:03 +08:00
MistEO
36da60ed9d fix: 统一 WpfGui 工作目录 (#14072)
* fix: 统一WpfGui工作目录

* chore: 漏了的cache目录

* chore: Auto update by pre-commit hooks [skip changelog]

* fix: 多了一层相对目录

* feat: wpf 创建软连接

* feat: 添加 PathsHelper,提取通用地址

* feat: 提取通用目录

* fix: Combine

* fix: 重构依赖后 MaaWpfGui 的 resource 路径丢失 (#14077)

fix: mklink

* chore: 删除弹窗

* chore: 自定义基建使用绝对路径

* perf: 简化命名

* fix: 遗漏的issue rp

* fix: 基建

* perf: config.new

* feat: 去除本地作业前缀

* chore: 怎么改名了

* rft: rename

添加一个Dir后缀, 直接using static

* fix: remove不再使用的../../../resrouce

* perf: 短点

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: uye <99072975+ABA2396@users.noreply.github.com>
Co-authored-by: Status102 <102887808+status102@users.noreply.github.com>
2025-09-12 21:25:33 +08:00
uye
a71eb71eff fix: 逻辑写错了!
[skip changelog]
2025-09-12 19:04:21 +08:00
uye
283329f8ea chore: 调整定时器触发逻辑
fix #14083
2025-09-12 18:51:17 +08:00
Constrat
01eed2a376 ci: reduce building scope for resource updater + rm llvm.sh (#14084)
* test: pre target / component

* test: temp disable cache

* fix: add libcxx

* ci: remove llvm.sh after execution

* test: reconfigure cache
2025-09-12 12:46:26 +02:00
uye
a13212ea6e chore: 调整未检测到模拟器的输出 2025-09-12 17:21:23 +08:00
status102
cb31aa0dbd feat(wpf): 战斗列表点击作业时自动关闭列表, 原逻辑迁移至鼠标右键 2025-09-12 13:30:50 +08:00
nekosu
61265768e5 fix: add component for install libcxx only 2025-09-12 11:54:09 +08:00
Status102
85975d642c fix: 重构依赖后 MaaWpfGui 的 resource 路径丢失 (#14077)
fix: mklink
2025-09-12 00:55:40 +08:00
status102
8d5806b9e1 chore: gitignore
lnk for sln or other
2025-09-12 00:44:13 +08:00
Constrat
5b32c3a985 chore: where and how did this come from? 2025-09-11 18:22:00 +02:00
github-actions[bot]
4dc488229d chore: Auto Update Game Resources - 2025-09-11
https://github.com/MaaAssistantArknights/MaaAssistantArknights/actions/runs/17650477221

[skip changelog]
2025-09-11 16:18:07 +00:00
403 changed files with 28855 additions and 17777 deletions

29
.devcontainer/Dockerfile Normal file
View File

@@ -0,0 +1,29 @@
FROM mcr.microsoft.com/devcontainers/base:ubuntu
USER vscode
ENV CONDA_DIR=/home/vscode/miniconda
ENV PATH="$CONDA_DIR/bin:$PATH"
ARG PYTHON_VERSION=3.12
ARG NODEJS_VERSION=24
# Install Miniconda
RUN wget https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh -O ~/miniconda.sh \
&& bash ~/miniconda.sh -b -p $CONDA_DIR \
&& rm ~/miniconda.sh \
&& conda tos accept --override-channels --channel https://repo.anaconda.com/pkgs/main \
&& conda tos accept --override-channels --channel https://repo.anaconda.com/pkgs/r
# Configure conda environment
RUN eval "$(conda shell.bash hook)" \
&& conda create -n maa python=$PYTHON_VERSION -y \
&& conda activate maa \
&& conda install -y conda-forge::nodejs=$NODEJS_VERSION \
&& pip install pre-commit black \
&& npm install -g pnpm
# Finalize conda setup
RUN conda init \
&& conda config --set auto_activate false \
&& echo "conda activate maa" >> ~/.bashrc

View File

@@ -1,13 +1,50 @@
// For format details, see https://aka.ms/devcontainer.json. For config options, see the
// README at: https://github.com/devcontainers/templates/tree/main/src/javascript-node
{
"image": "mcr.microsoft.com/devcontainers/cpp:ubuntu-22.04",
"features": {
"ghcr.io/devcontainers/features/python:1": {},
"ghcr.io/devcontainers/features/sshd:1": {}
"name": "MAA",
// Or use a Dockerfile or Docker Compose file. More info: https://containers.dev/guide/dockerfile
// "image": "mcr.microsoft.com/devcontainers/base:ubuntu",
"build": {
"dockerfile": "Dockerfile"
},
"postCreateCommand": "sudo sh -ce 'wget https://apt.llvm.org/llvm.sh && chmod +x llvm.sh && ./llvm.sh 20'",
// Features to add to the dev container. More info: https://containers.dev/features.
// "features": {},
// Use 'forwardPorts' to make a list of ports inside the container available locally.
"forwardPorts": [3001],
// Use 'postCreateCommand' to run commands after the container is created.
"postCreateCommand": "bash .devcontainer/post-create.sh",
// Configure tool-specific properties.
"customizations": {
"vscode": {
"extensions": ["llvm-vs-code-extensions.vscode-clangd", "DavidAnson.vscode-markdownlint"]
"extensions": [
"mkxml.vscode-filesize",
"nekosu.maa-support",
"DavidAnson.vscode-markdownlint",
"esbenp.prettier-vscode",
"vue.volar",
"ms-python.python",
"ms-python.black-formatter"
],
"settings": {
// format
"editor.formatOnSave": true,
"editor.defaultFormatter": "esbenp.prettier-vscode",
"[markdown]": {
"editor.defaultFormatter": "DavidAnson.vscode-markdownlint"
},
"[python]": {
"editor.defaultFormatter": "ms-python.black-formatter"
},
// python
"python.terminal.launchArgs": ["-u"],
"python.defaultInterpreterPath": "/home/vscode/miniconda/envs/maa/bin/python",
"python.terminal.activateEnvironment": false
}
}
}
// Uncomment to connect as root instead. More info: https://aka.ms/dev-containers-non-root.
// "remoteUser": "root"
}

View File

@@ -0,0 +1,21 @@
#!/bin/bash
WORKSPACE=$(pwd)
# conda activate maa
echo "===================="
echo "Setting up git safe.directory for $WORKSPACE and its submodules..."
cd "$WORKSPACE"
git config --global --add safe.directory "$WORKSPACE"
git submodule foreach --recursive 'git config --global --add safe.directory "$toplevel/$path"'
echo "===================="
cd "$WORKSPACE"
echo "Installing dependencies for python..."
# pip install -r tools/.../requirements.txt
# pip install -r tools/.../requirements-dev.txt
echo "===================="
echo "Installing dependencies for nodejs..."
cd "$WORKSPACE"/docs
pnpm install --frozen-lockfile

View File

@@ -15,7 +15,7 @@ body:
required: false
- label: 我使用的是当前更新版本的最新版, 并已查看版本发布至今的 [更新内容](https://github.com/MaaAssistantArknights/MaaAssistantArknights/commits/dev/), [Pull Requests](https://github.com/MaaAssistantArknights/MaaAssistantArknights/pulls) 中尚未发布的更新内容并未提及该 Bug 已被修复的情况
required: false
- label: 我已检查了 [常见问题](https://maa.plus/docs/zh-cn/manual/faq.html), [公告](https://github.com/MaaAssistantArknights/MaaAssistantArknights/issues/7732), [活跃议题](https://github.com/MaaAssistantArknights/MaaAssistantArknights/issues), [已关闭议题](https://github.com/MaaAssistantArknights/MaaAssistantArknights/issues?q=is%3Aissue%20state%3Aclosed) 确认我的问题未被提及
- label: 我已检查了 [常见问题](https://docs.maa.plus/zh-cn/manual/faq.html), [公告](https://github.com/MaaAssistantArknights/MaaAssistantArknights/issues/7732), [活跃议题](https://github.com/MaaAssistantArknights/MaaAssistantArknights/issues), [已关闭议题](https://github.com/MaaAssistantArknights/MaaAssistantArknights/issues?q=is%3Aissue%20state%3Aclosed) 确认我的问题未被提及
required: false
- type: textarea
id: describe

View File

@@ -15,7 +15,7 @@ body:
required: false
- label: 我使用的是当前更新版本的最新版, 并已查看版本发布至今的 [更新内容](https://github.com/MaaAssistantArknights/MaaAssistantArknights/commits/dev/), [Pull Requests](https://github.com/MaaAssistantArknights/MaaAssistantArknights/pulls) 中尚未发布的更新内容,确认我的建议未被提及
required: false
- label: 我已检查了 [常见问题](https://maa.plus/docs/zh-cn/manual/faq.html), [公告](https://github.com/MaaAssistantArknights/MaaAssistantArknights/issues/7732), [活跃议题](https://github.com/MaaAssistantArknights/MaaAssistantArknights/issues), [已关闭议题](https://github.com/MaaAssistantArknights/MaaAssistantArknights/issues?q=is%3Aissue%20state%3Aclosed) 确认我的建议未被提及
- label: 我已检查了 [常见问题](https://docs.maa.plus/zh-cn/manual/faq.html), [公告](https://github.com/MaaAssistantArknights/MaaAssistantArknights/issues/7732), [活跃议题](https://github.com/MaaAssistantArknights/MaaAssistantArknights/issues), [已关闭议题](https://github.com/MaaAssistantArknights/MaaAssistantArknights/issues?q=is%3Aissue%20state%3Aclosed) 确认我的建议未被提及
required: false
- type: textarea
id: describe

View File

@@ -17,7 +17,7 @@ body:
required: true
- label: I have checked all the options without carefully reading the content and believe this will not affect issue resolution.
required: false
- label: I have reviewed the [FAQs](https://maa.plus/docs/en-us/manual/faq.html), [Announcement](/MaaAssistantArknights/MaaAssistantArknights/issues/7732), [Open Issues](https://github.com/MaaAssistantArknights/MaaAssistantArknights/issues), [Closed Issues](https://github.com/MaaAssistantArknights/MaaAssistantArknights/issues?q=is%3Aissue%20state%3Aclosed) to ensure that my issue has not been mentioned.
- label: I have reviewed the [FAQs](https://docs.maa.plus/en-us/manual/faq.html), [Announcement](/MaaAssistantArknights/MaaAssistantArknights/issues/7732), [Open Issues](https://github.com/MaaAssistantArknights/MaaAssistantArknights/issues), [Closed Issues](https://github.com/MaaAssistantArknights/MaaAssistantArknights/issues?q=is%3Aissue%20state%3Aclosed) to ensure that my issue has not been mentioned.
required: true
- type: textarea
id: describe

View File

@@ -17,7 +17,7 @@ body:
required: true
- label: I have checked all the options without carefully reading the content and believe this will not affect issue resolution.
required: false
- label: I have reviewed the [FAQs](https://maa.plus/docs/en-us/manual/faq.html), [Announcement](/MaaAssistantArknights/MaaAssistantArknights/issues/7732), [Open Issues](https://github.com/MaaAssistantArknights/MaaAssistantArknights/issues), [Closed Issues](https://github.com/MaaAssistantArknights/MaaAssistantArknights/issues?q=is%3Aissue%20state%3Aclosed) to ensure that my feature/suggestion has not been mentioned.
- label: I have reviewed the [FAQs](https://docs.maa.plus/en-us/manual/faq.html), [Announcement](/MaaAssistantArknights/MaaAssistantArknights/issues/7732), [Open Issues](https://github.com/MaaAssistantArknights/MaaAssistantArknights/issues), [Closed Issues](https://github.com/MaaAssistantArknights/MaaAssistantArknights/issues?q=is%3Aissue%20state%3Aclosed) to ensure that my feature/suggestion has not been mentioned.
required: true
- type: textarea
id: describe

75
.github/stale_cache_cleanup.ps1 vendored Normal file
View File

@@ -0,0 +1,75 @@
$totalClearedSize = 0
$cacheList = gh cache list --json id,key,ref,sizeInBytes,createdAt | ConvertFrom-Json
# List of keys to process
$keyPatterns = @(
"Windows-x64-nuget",
"Windows-x64-maadeps",
"Windows-arm64-nuget",
"Windows-arm64-maadeps",
"macOS-x64-maadeps",
"macOS-arm64-maadeps",
"Linux-x64-maadeps",
"Linux-arm64-maadeps",
"Smoke-testing"
)
# Filter caches matching any of our key patterns
$matchingCaches = $cacheList | Where-Object {
$cache = $_
($keyPatterns | Where-Object { $cache.key -like "*$_*" }).Count -gt 0
}
# Get unique branch references from the matching caches
$branches = $matchingCaches | Select-Object -Property ref -Unique | ForEach-Object { $_.ref }
Write-Output "Found caches across $($branches.Count) branches"
foreach ($branch in $branches) {
# Extract branch name from ref for display
$branchName = $branch -replace "refs/heads/", ""
if ($branch -match "refs/pull/(\d+)/merge") {
$branchName = "PR #$($matches[1])"
}
Write-Output "Processing caches for branch: $branchName"
# Filter for current branch caches
$branchCaches = $matchingCaches | Where-Object { $_.ref -eq $branch }
foreach ($pattern in $keyPatterns) {
Write-Output " Processing $branchName branch caches for pattern: $pattern"
# Filter for caches matching the current key pattern within branch
$patternCaches = $branchCaches | Where-Object { $_.key -like "*$pattern*" }
if (-not $patternCaches) {
Write-Output " No $branchName branch caches found for pattern: $pattern"
continue
}
# Sort by creation time (newest first)
$sortedCaches = $patternCaches | Sort-Object -Property createdAt -Descending
# Keep the first one (latest) and delete the rest
$latestCache = $sortedCaches[0]
Write-Output " Keeping latest cache for $branchName/${pattern}: '$($latestCache.key)' (ID: $($latestCache.id))"
# Delete all except the latest one
for ($i = 1; $i -lt $sortedCaches.Count; $i++) {
$cache = $sortedCaches[$i]
$cacheId = $cache.id
$cacheKey = $cache.key
Write-Output " Deleting cache for $branchName/${pattern}: '$cacheKey' (ID: $cacheId)"
gh cache delete $cacheId
$totalClearedSize += $cache.sizeInBytes
}
}
Write-Output ""
}
$formattedSize = "{0:N2}" -f ($totalClearedSize / 1MB)
Write-Output "Total cleared size: $formattedSize MB"

59
.github/stale_cache_dev.ps1 vendored Normal file
View File

@@ -0,0 +1,59 @@
$totalClearedSize = 0
$cacheList = gh cache list --json id,key,ref,sizeInBytes,createdAt | ConvertFrom-Json
# Filter for dev branch caches only
$devCaches = $cacheList | Where-Object { $_.ref -eq "refs/heads/dev" }
if (-not $devCaches) {
Write-Output "No caches found for dev branch."
exit
}
# List of keys to process
$keyPatterns = @(
"Windows-x64-nuget",
"Windows-x64-maadeps",
"Windows-arm64-nuget",
"Windows-arm64-maadeps",
"macOS-x64-maadeps",
"macOS-arm64-maadeps",
"Linux-x64-maadeps",
"Linux-arm64-maadeps",
"Smoke-testing"
)
foreach ($pattern in $keyPatterns) {
Write-Output "Processing dev branch caches for pattern: $pattern"
# Filter for caches matching the current key pattern within dev branch
$matchingCaches = $devCaches | Where-Object { $_.key -like "*$pattern*" }
if (-not $matchingCaches) {
Write-Output " No dev branch caches found for pattern: $pattern"
continue
}
# Sort by creation time (newest first)
$sortedCaches = $matchingCaches | Sort-Object -Property createdAt -Descending
# Keep the first one (latest) and delete the rest
$latestCache = $sortedCaches[0]
Write-Output " Keeping latest dev branch cache: '$($latestCache.key)' (ID: $($latestCache.id))"
# Delete all except the latest one
for ($i = 1; $i -lt $sortedCaches.Count; $i++) {
$cache = $sortedCaches[$i]
$cacheId = $cache.id
$cacheKey = $cache.key
Write-Output " Deleting dev branch cache: '$cacheKey' (ID: $cacheId)"
gh cache delete $cacheId
$totalClearedSize += $cache.sizeInBytes
}
Write-Output ""
}
$formattedSize = "{0:N2}" -f ($totalClearedSize / 1MB)
Write-Output "Total cleared size: $formattedSize MB"

View File

@@ -128,7 +128,7 @@ jobs:
with:
path: |
./MaaDeps
key: ${{ runner.os }}-${{ matrix.arch }}-maadeps-${{ hashFiles('./tools/maadeps-download.py') }}
key: ${{ runner.os }}-${{ matrix.arch }}-maadeps-${{ hashFiles('tools/maadeps-download.py') }}
- name: Bootstrap MaaDeps
if: steps.cache-maadeps.outputs.cache-hit != 'true'
@@ -158,7 +158,7 @@ jobs:
path: |
.nuke/temp
~/.nuget/packages
key: ${{ runner.os }}-${{ matrix.arch }}-${{ hashFiles('**/*.csproj') }}
key: ${{ runner.os }}-${{ matrix.arch }}-nuget-${{ hashFiles('**/*.csproj') }}
- name: Restore dependencies
if: steps.cache-nuget.outputs.cache-hit != 'true'
@@ -196,11 +196,16 @@ jobs:
cp tools/DependencySetup_依赖库安装.bat install
- name: Zip files
run: |
cd install
Compress-Archive -Destination MAA-${{ needs.meta.outputs.tag }}-win-${{ matrix.arch }}.zip -Path ./*
- name: Upload MAA to Github
uses: actions/upload-artifact@v4
with:
name: MAA-win-${{ matrix.arch }}
path: install
path: install/*.zip
ubuntu:
# Prevent duplicate runs on organization branches with PRs
@@ -225,26 +230,19 @@ jobs:
git submodule update --init --depth 1 3rdparty/EmulatorExtras
git submodule update --init --depth 1 src/maa-cli
- name: Cache MaaDeps and Toolchain
- name: Cache MaaDeps
id: cache-maadeps
uses: actions/cache@v4
with:
path: ./MaaDeps
key: ${{ runner.os }}-${{ matrix.arch == 'x86_64' && 'x64' || 'arm64' }}-maadeps-${{ hashFiles('tools/maadeps-download.py', 'tools/linux-toolchain-download.py') }}
key: ${{ runner.os }}-${{ matrix.arch == 'x86_64' && 'x64' || 'arm64' }}-maadeps-${{ hashFiles('tools/maadeps-download.py') }}
- name: Bootstrap MaaDeps and Toolchain
- name: Bootstrap MaaDeps
if: steps.cache-maadeps.outputs.cache-hit != 'true'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
python3 tools/maadeps-download.py ${{ matrix.arch == 'x86_64' && 'x64' || 'arm64' }}-linux
python3 tools/linux-toolchain-download.py ${{ matrix.arch == 'x86_64' && 'x64' || 'arm64' }}
- name: Install llvm 20
run: |
wget https://apt.llvm.org/llvm.sh
chmod +x llvm.sh
sudo ./llvm.sh 20
- name: Config cmake
run: |
@@ -255,7 +253,7 @@ jobs:
-DINSTALL_RESOURCE=ON \
-DINSTALL_PYTHON=ON \
-DMAA_HASH_VERSION='${{ needs.meta.outputs.tag }}' \
-DCMAKE_TOOLCHAIN_FILE=cmake/linux/maa-${{ matrix.arch == 'x86_64' && 'x64' || 'arm64' }}-linux-toolchain.cmake
-DCMAKE_TOOLCHAIN_FILE=MaaDeps/cmake/maa-${{ matrix.arch == 'x86_64' && 'x64' || 'arm64' }}-linux-toolchain.cmake
- name: Build
run: |
@@ -351,12 +349,18 @@ jobs:
with:
show-progress: false
# ninja 1.13.1 is already installed and up-to-date. To reinstall 1.13.1, run: brew reinstall ninja
# ninja 1.13.1 is already installed and up-to-date.
# - name: Install Dependencies
# run: |
# brew install ninja
# Caching not necessary on macOS runner
- name: Cache MaaDeps
id: cache-maadeps
uses: actions/cache@v4
with:
path: ./MaaDeps
key: ${{ runner.os }}-${{ matrix.arch == 'x86_64' && 'x64' || 'arm64' }}-maadeps-${{ hashFiles('tools/maadeps-download.py') }}
- name: Bootstrap MaaDeps
run: |
[[ ${{ matrix.arch }} = "arm64" ]] && triplet="arm64-osx" || triplet="x64-osx"
@@ -373,7 +377,7 @@ jobs:
- name: Build
run: |
cmake --build build --config Release --parallel $(nproc)
cmake --build build --config Release --parallel $(sysctl -n hw.logicalcpu)
- name: Install
run: |
@@ -590,3 +594,12 @@ jobs:
gh workflow run --repo $GITHUB_REPOSITORY release-ota
env:
GH_TOKEN: ${{ secrets.MISTEOWORKFLOW }}
- name: Create issue if failed
if: failure()
uses: actions-cool/issues-helper@v3
with:
actions: "create-issue"
title: "Failed Release"
body: |
${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}

View File

@@ -1,50 +0,0 @@
name: "CodeQL Website Analysis"
on:
pull_request:
branches: ["dev"]
paths:
- "website/**"
- "!**/*.md"
schedule:
- cron: "10 12 * * *" # Runs daily at 12:10 UTC
workflow_dispatch:
permissions:
actions: write
contents: read
security-events: write
jobs:
analyze-website:
name: Analyze Website (JavaScript/TypeScript)
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v5
with:
show-progress: false
- name: Setup CodeQL for JavaScript/TypeScript
uses: github/codeql-action/init@v3
with:
languages: javascript-typescript
build-mode: none
- name: Run CodeQL Analysis
uses: github/codeql-action/analyze@v3
with:
category: "/language:multi-none"
- name: Delete old caches
shell: bash
run: |
oldCaches=$(gh cache list --key codeql --order asc --json key | jq -r '.[] | .key' | head -n -1)
for cache in $oldCaches; do
if [ -n "$cache" ]; then
echo "Deleting cache: $cache"
gh cache delete "$cache" --confirm
fi
done
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

View File

@@ -52,7 +52,6 @@ jobs:
--exclude 'https?://.*'
--exclude-path 'docs/zh-tw/manual/introduction/introduction_old.md'
--exclude-path 'docs/ja-jp/manual/introduction/introduction_old.md'
--exclude 'files/MAA_Runtime_Fix_Pwsh.ps1$'
-- './docs/**/*.md' './README.md'
- name: Comment (only for PR)

View File

@@ -16,12 +16,12 @@ on:
limit_maa:
description: "Number of releases to fetch from MaaAssistantArknights"
required: true
default: "10"
default: 10
type: number
limit_mr:
limit_maarelease:
description: "Number of releases to fetch from MaaRelease"
required: true
default: "10"
default: 10
type: number
jobs:
@@ -172,7 +172,7 @@ jobs:
with:
path: |
./MaaDeps
key: ${{ runner.os }}-${{ matrix.arch }}-maadeps-${{ hashFiles('./tools/maadeps-download.py') }}
key: ${{ runner.os }}-${{ matrix.arch }}-maadeps-${{ hashFiles('tools/maadeps-download.py') }}
- name: Bootstrap MaaDeps
if: steps.cache-maadeps.outputs.cache-hit != 'true'
@@ -202,7 +202,7 @@ jobs:
path: |
.nuke/temp
~/.nuget/packages
key: ${{ runner.os }}-${{ matrix.arch }}-${{ hashFiles('**/*.csproj') }}
key: ${{ runner.os }}-${{ matrix.arch }}-nuget-${{ hashFiles('**/*.csproj') }}
- name: Restore dependencies
if: steps.cache-nuget.outputs.cache-hit != 'true'
@@ -313,12 +313,12 @@ jobs:
limit_maa=${limit_maa%.*}
echo "Parsed limit_maa: $limit_maa"
limit_mr=${{ inputs.limit_mr || 10 }}
limit_mr=${limit_mr%.*}
echo "Parsed limit_mr: $limit_mr"
limit_maarelease=${{ inputs.limit_maarelease || 10 }}
limit_maarelease=${limit_maarelease%.*}
echo "Parsed limit_maarelease: $limit_maarelease"
gh release list --repo 'MaaAssistantArknights/MaaAssistantArknights' --limit $limit_maa | tee ./release_maa.txt
gh release list --repo "${{ github.repository_owner }}/MaaRelease" --limit $limit_mr | tee ./release_mr.txt
gh release list --repo "${{ github.repository_owner }}/MaaRelease" --limit $limit_maarelease | tee ./release_mr.txt
echo ${{ needs.build-win-nightly.outputs.tag }} > ./config
cat ./release_maa.txt | awk '{ print $1 }' > ./tags_maa.txt

View File

@@ -9,12 +9,12 @@ on:
limit:
description: Number of releases to fetch from MaaAssistantArknights, 2 at least
required: false
default: "31"
default: 31
type: number
limit_2:
description: Number of releases to fetch from MaaRelease
required: false
default: "30"
default: 30
type: number
env:
@@ -95,6 +95,9 @@ jobs:
steps:
- name: Download release config
uses: actions/download-artifact@v5
with:
name: MaaReleaseConfig
path: ./MaaReleaseConfig
- name: Fetch MaaRelease
uses: actions/checkout@v5
@@ -134,6 +137,15 @@ jobs:
prerelease: ${{ fromJSON(needs.create-tag.outputs.prerelease) }}
overwrite: true
- name: Create issue if failed
if: failure()
uses: actions-cool/issues-helper@v3
with:
actions: "create-issue"
title: "Failed make release OTA for Windows"
body: |
${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}
make-ota-mac:
needs: create-tag
runs-on: macos-14
@@ -177,6 +189,15 @@ jobs:
prerelease: ${{ fromJSON(needs.create-tag.outputs.prerelease) }}
overwrite: true
- name: Create issue if failed
if: failure()
uses: actions-cool/issues-helper@v3
with:
actions: "create-issue"
title: "Failed make release OTA for macos"
body: |
${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}
release:
needs:
- make-ota

View File

@@ -125,11 +125,11 @@ jobs:
compression-level: 0
update-game-resources:
# Remove the comment in case of rate limitations on the runners/instances.
# In case of rate limitations on the runners/instances, add dependency, by removing the comment
# needs: [clone-resources-official, clone-resources-overseas, clone-resources-txwy]
if: github.repository_owner == 'MaaAssistantArknights'
runs-on: ubuntu-latest
runs-on: macos-latest
steps:
- name: Checkout MAA
uses: actions/checkout@v5
@@ -146,11 +146,8 @@ jobs:
with:
key: ResourceUpdater-${{ runner.os }}-${{ hashFiles('tools/ResourceUpdater/main.cpp') }}
path: |
./tools/ResourceUpdater/libc++.so.1
./tools/ResourceUpdater/libc++abi.so.1
./tools/ResourceUpdater/libopencv_world4.so.411
./tools/ResourceUpdater/libunwind.so.1
./tools/ResourceUpdater/ResourceUpdater
./tools/ResourceUpdater/libopencv_world4.4.11.0.dylib
./tools/ResourceUpdater/res_updater
- name: Cache MaaDeps
if: steps.resupd-cache.outputs.cache-hit != 'true'
@@ -159,42 +156,34 @@ jobs:
with:
path: |
./MaaDeps
key: ${{ runner.os }}-x64-maadeps-${{ hashFiles('tools/maadeps-download.py', 'tools/linux-toolchain-download.py') }}
key: ${{ runner.os }}-arm64-maadeps-${{ hashFiles('tools/maadeps-download.py') }}
- name: Bootstrap MaaDeps
if: steps.resupd-cache.outputs.cache-hit != 'true' && steps.maadeps-cache.outputs.cache-hit != 'true'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
python3 tools/maadeps-download.py x64-linux
python3 tools/linux-toolchain-download.py x64
- name: Install llvm-20
if: steps.resupd-cache.outputs.cache-hit != 'true'
run: |
wget https://apt.llvm.org/llvm.sh
chmod +x llvm.sh
sudo ./llvm.sh 20
python3 tools/maadeps-download.py arm64-osx
- name: Config cmake
if: steps.resupd-cache.outputs.cache-hit != 'true'
run: |
cd tools/ResourceUpdater
mkdir -p build
cmake -B build \
cmake -B build -GNinja \
-DCMAKE_BUILD_TYPE=Release \
-DMAADEPS_TRIPLET='maa-x64-linux' \
-DBUILD_RES_UPDATER=ON \
-DCMAKE_TOOLCHAIN_FILE=cmake/linux/maa-x64-linux-toolchain.cmake
-DMAADEPS_TRIPLET='maa-arm64-osx' \
-DWITH_HASH_VERSION=ON
- name: Build
if: steps.resupd-cache.outputs.cache-hit != 'true'
run: |
cmake --build build --config Release --parallel $(nproc)
cmake --build tools/ResourceUpdater/build --config Release --parallel $(sysctl -n hw.logicalcpu)
- name: Install
if: steps.resupd-cache.outputs.cache-hit != 'true'
run: |
cmake --install build --config Release --prefix tools/ResourceUpdater
cmake --install tools/ResourceUpdater/build --prefix tools/ResourceUpdater --config Release
- name: Save ResourceUpdater to cache
if: always() && steps.resupd-cache.outputs.cache-hit != 'true'
@@ -202,49 +191,64 @@ jobs:
with:
key: ResourceUpdater-${{ runner.os }}-${{ hashFiles('tools/ResourceUpdater/main.cpp') }}
path: |
./tools/ResourceUpdater/libc++.so.1
./tools/ResourceUpdater/libc++abi.so.1
./tools/ResourceUpdater/libopencv_world4.so.411
./tools/ResourceUpdater/libunwind.so.1
./tools/ResourceUpdater/ResourceUpdater
- name: Wait for TXWY resources
uses: lewagon/wait-on-check-action@v1.4.0
with:
ref: ${{ github.ref }}
check-name: 'clone-resources-txwy'
repo-token: ${{ secrets.GITHUB_TOKEN }}
wait-interval: 5
./tools/ResourceUpdater/libopencv_world4.4.11.0.dylib
./tools/ResourceUpdater/res_updater
- name: Download txwy
id: download-txwy
uses: actions/download-artifact@v5
continue-on-error: true
with:
name: txwy
path: ./tools/ResourceUpdater/Overseas/tw/gamedata/excel
- name: Delay txwy
if: steps.download-txwy.outcome == 'failure'
run: |
sleep 10
- name: Re-download txwy
if: steps.download-txwy.outcome == 'failure'
uses: actions/download-artifact@v5
with:
name: txwy
path: ./tools/ResourceUpdater/Overseas/tw/gamedata/excel
- name: Wait for Overseas resources
uses: lewagon/wait-on-check-action@v1.4.0
with:
ref: ${{ github.ref }}
check-name: 'clone-resources-overseas'
repo-token: ${{ secrets.GITHUB_TOKEN }}
wait-interval: 5
- name: Download Overseas
id: download-overseas
uses: actions/download-artifact@v5
continue-on-error: true
with:
name: overseas
path: ./tools/ResourceUpdater/Overseas
- name: Delay Overseas
if: steps.download-overseas.outcome == 'failure'
run: |
sleep 10
- name: Re-download Overseas
if: steps.download-overseas.outcome == 'failure'
uses: actions/download-artifact@v5
with:
name: overseas
path: ./tools/ResourceUpdater/Overseas
- name: Wait for Official resources
uses: lewagon/wait-on-check-action@v1.4.0
with:
ref: ${{ github.ref }}
check-name: 'clone-resources-official'
repo-token: ${{ secrets.GITHUB_TOKEN }}
wait-interval: 5
- name: Download Official
id: download-official
uses: actions/download-artifact@v5
continue-on-error: true
with:
name: official
path: ./tools/ResourceUpdater/Official
- name: Delay Official
if: steps.download-official.outcome == 'failure'
run: |
sleep 10
- name: Re-download Official
if: steps.download-official.outcome == 'failure'
uses: actions/download-artifact@v5
with:
name: official
@@ -252,7 +256,7 @@ jobs:
- name: Run Resource Updater
run: |
./tools/ResourceUpdater/ResourceUpdater
./tools/ResourceUpdater/res_updater
- name: Task Sorting
id: task_sorting
@@ -268,7 +272,7 @@ jobs:
- name: Update version.json date if necessary
id: update_version
run: |
tools/ResourceUpdater/version.sh
./tools/ResourceUpdater/version.zsh
- name: Setup python
if: steps.update_version.outputs.contains_png == 'True'
@@ -342,7 +346,7 @@ jobs:
if: steps.update_version.outputs.changes != 'True' || steps.add_files.outputs.have_commits != 'True'
uses: andymckay/cancel-action@0.5
# - name: Release # ref: https://docs.github.com/en/actions/using-workflows/triggering-a-workflow#triggering-a-workflow-from-a-workflow
# if: steps.add_files.outputs.have_commits == 'True'
# run: |
# gh workflow run release-nightly-ota -f release_body="Auto Release of Resource Updates"
# - name: Release # ref: https://docs.github.com/en/actions/using-workflows/triggering-a-workflow#triggering-a-workflow-from-a-workflow
# if: steps.add_files.outputs.have_commits == 'True'
# run: |
# gh workflow run release-nightly-ota -f release_body="Auto Release of Resource Updates"

View File

@@ -3,6 +3,7 @@ name: smoke-testing
on:
push:
paths:
- ".github/workflows/smoke-testing.yml"
- "3rdparty/include/**"
- "include/**"
- "src/Cpp/**"
@@ -14,6 +15,7 @@ on:
- "tools/maadeps-download.py"
pull_request:
paths:
- ".github/workflows/smoke-testing.yml"
- "3rdparty/include/**"
- "include/**"
- "src/Cpp/**"
@@ -25,17 +27,13 @@ on:
- "tools/maadeps-download.py"
workflow_dispatch:
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
smoke-testing:
# Prevent duplicate runs on organization branches with PRs
if: github.event_name != 'pull_request' ||
github.event.pull_request.head.repo.full_name !=
github.event.pull_request.base.repo.full_name
runs-on: ubuntu-latest
runs-on: macos-latest
steps:
- name: Checkout code
uses: actions/checkout@v5
@@ -53,15 +51,10 @@ jobs:
with:
key: ${{ steps.cache_key.outputs.key }}
path: |
./install/AsstCaller.h
./install/AsstPort.h
./install/libc++.so.1
./install/libc++abi.so.1
./install/libfastdeploy_ppocr.so
./install/libMaaCore.so
./install/libonnxruntime.so.1
./install/libopencv_world4.so.411
./install/libunwind.so.1
./install/libfastdeploy_ppocr.dylib
./install/libMaaCore.dylib
./install/libonnxruntime.1.19.2.dylib
./install/libopencv_world4.4.11.0.dylib
./install/smoke_test
- name: Fetch submodules
@@ -75,37 +68,30 @@ jobs:
uses: actions/cache@v4
with:
path: ./MaaDeps
key: ${{ runner.os }}-x64-maadeps-${{ hashFiles('tools/maadeps-download.py', 'tools/linux-toolchain-download.py') }}
key: ${{ runner.os }}-arm64-maadeps-${{ hashFiles('tools/maadeps-download.py') }}
- name: Bootstrap MaaDeps
if: steps.smoke-cache.outputs.cache-hit != 'true' && steps.maadeps-cache.outputs.cache-hit != 'true'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
python3 tools/maadeps-download.py x64-linux
python3 tools/linux-toolchain-download.py x64
- name: Install llvm-20
if: steps.smoke-cache.outputs.cache-hit != 'true'
run: |
wget https://apt.llvm.org/llvm.sh
chmod +x llvm.sh
sudo ./llvm.sh 20
python3 tools/maadeps-download.py arm64-osx
- name: Config cmake
if: steps.smoke-cache.outputs.cache-hit != 'true'
run: |
mkdir -p build
cmake -B build \
cmake -B build -GNinja \
-DCMAKE_BUILD_TYPE=Debug \
-DMAADEPS_TRIPLET='maa-x64-linux' \
-DMAADEPS_TRIPLET='maa-arm64-osx' \
-DBUILD_SMOKE_TEST=ON \
-DCMAKE_TOOLCHAIN_FILE=cmake/linux/maa-x64-linux-toolchain.cmake
-DINSTALL_RESOURCE=ON \
-DWITH_HASH_VERSION=ON
- name: Build
if: steps.smoke-cache.outputs.cache-hit != 'true'
run: |
cmake --build build --config Debug --parallel $(nproc)
cmake --build build --config Debug --parallel $(sysctl -n hw.logicalcpu)
- name: Install
if: steps.smoke-cache.outputs.cache-hit != 'true'
@@ -113,9 +99,14 @@ jobs:
mkdir -p install
cmake --install build --prefix install --config Debug
- name: Make link for cache smoke-testing
if: steps.smoke-cache.outputs.cache-hit == 'true'
run: |
ln -s "$(pwd)/resource" install/resource
- name: Run tests
run: |
./tools/SmokeTesting/run_tests.sh
./tools/SmokeTesting/run_tests.zsh
- name: Save cache smoke-testing (only in dev)
if: steps.smoke-cache.outputs.cache-hit != 'true' && github.ref == 'refs/heads/dev'
@@ -123,15 +114,10 @@ jobs:
with:
key: ${{ steps.cache_key.outputs.key }}
path: |
./install/AsstCaller.h
./install/AsstPort.h
./install/libc++.so.1
./install/libc++abi.so.1
./install/libfastdeploy_ppocr.so
./install/libMaaCore.so
./install/libonnxruntime.so.1
./install/libopencv_world4.so.411
./install/libunwind.so.1
./install/libfastdeploy_ppocr.dylib
./install/libMaaCore.dylib
./install/libonnxruntime.1.19.2.dylib
./install/libopencv_world4.4.11.0.dylib
./install/smoke_test
- name: Upload logs

View File

@@ -8,108 +8,65 @@ on:
paths:
- ".github/workflows/website-workflow.yml"
- "docs/**"
- "website/**"
pull_request:
paths:
- ".github/workflows/website-workflow.yml"
- "docs/**"
- "website/**"
workflow_dispatch:
inputs:
deploy-to-prod-env:
description: "Deploy to production environment"
deploy-to-prod:
description: "Deploy to prod"
default: false
required: true
type: boolean
concurrency:
group: "pages"
cancel-in-progress: false
jobs:
build:
timeout-minutes: 20
runs-on: ubuntu-latest
timeout-minutes: 20
steps:
- name: Check out code
- name: Checkout
uses: actions/checkout@v5
with:
show-progress: false
- name: Setup Pages
uses: actions/configure-pages@v5
- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 9
version: 10
run_install: false
- name: Setup Node.js environment
uses: actions/setup-node@v5
with:
node-version: 22
node-version: 24
cache: pnpm
cache-dependency-path: "./docs/pnpm-lock.yaml"
- name: Install dependencies
run: pnpm install --frozen-lockfile
working-directory: "./website"
working-directory: "./docs"
- name: Build
- name: Build documentation
run: pnpm run build
working-directory: "./website"
working-directory: "./docs"
- name: Upload artifact to GitHub
uses: actions/upload-artifact@v4
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
name: dist
path: "./website/dist"
publish:
runs-on: ubuntu-latest
needs: build
if: github.event_name != 'pull_request'
steps:
- name: Download website artifacts
uses: actions/download-artifact@v5
with:
name: dist
- name: Set deployment environment
id: set-deployment-env
run: |
if [[ "${{ github.event_name }}" != "workflow_dispatch" && "${{ github.ref }}" == "refs/heads/master" ]] || [[ "${{ github.event.inputs.deploy-to-prod-env }}" == "true" ]]; then
echo "AZURE_TARGET_ENV=prod" >> $GITHUB_ENV
else
echo "AZURE_TARGET_ENV=dev" >> $GITHUB_ENV
fi
- name: Show environment
run: echo ${{ env.AZURE_TARGET_ENV }}
path: "./docs/.vuepress/dist"
- name: Deploy to GitHub Pages
uses: peaceiris/actions-gh-pages@v4
if: env.AZURE_TARGET_ENV == 'prod'
if: ${{ inputs.deploy-to-prod == true || github.ref == 'refs/heads/master' }}
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: "."
publish_dir: "./docs/.vuepress/dist"
publish_branch: gh-pages
- name: Deploy to Azure (prod)
id: deploy-prod
uses: Azure/static-web-apps-deploy@v1
if: env.AZURE_TARGET_ENV == 'prod'
with:
azure_static_web_apps_api_token: ${{ secrets.AZURE_STATIC_WEB_APPS_MAA_WEBSITE }}
repo_token: ${{ secrets.GITHUB_TOKEN }}
action: "upload"
app_location: "."
api_location: ""
skip_app_build: true
skip_api_build: true
- name: Deploy to Azure (dev)
id: deploy-dev
uses: Azure/static-web-apps-deploy@v1
if: env.AZURE_TARGET_ENV == 'dev'
with:
azure_static_web_apps_api_token: ${{ secrets.AZURE_STATIC_WEB_APPS_MAA_WEBSITE }}
repo_token: ${{ secrets.GITHUB_TOKEN }}
action: "upload"
deployment_environment: dev
app_location: "."
api_location: ""
skip_app_build: true
skip_api_build: true

6
.gitignore vendored
View File

@@ -451,6 +451,7 @@ tools/RoguelikeRecruitmentTool/output
# CF 活动关卡(异格夜刀),手动改的地图
/resource/Arknights-Tile-Pos/act24side_09-activities-act24side-level_act24side_09.json
/src/MaaWpfGui/FodyWeavers.xml
*.lnk
# 链接检查缓存
.lycheecache
@@ -473,4 +474,7 @@ Thumbs.db
# build & install
build
install
install
# pnpm cache
.pnpm-store

View File

@@ -18,10 +18,17 @@ repos:
rev: v3.5.3
hooks:
- id: prettier
files: ^((\.github/ISSUE_TEMPLATE|docs|resource|src|tools|website)/.*|\.pre-commit-config\.yaml|package-definition\.json)
name: prettier (config files)
files: ^((\.github/ISSUE_TEMPLATE|resource|src|tools)/.*|\.pre-commit-config\.yaml|package-definition\.json)
types_or:
- yaml
- json
- repo: https://github.com/rbubley/mirrors-prettier
rev: v3.5.3
hooks:
- id: prettier
name: prettier (docs)
files: ^docs/.*
- repo: https://github.com/DavidAnson/markdownlint-cli2
rev: v0.17.2
hooks:

View File

@@ -1,11 +1,13 @@
**/node_modules/
**/pnpm-lock.yaml
docs/**/*.md
MaaDeps/
3rdparty/
src/maa-cli
src/MaaMacGui
website/
# website/
# docs/
resource/Arknights-Tile-Pos/

View File

@@ -1,234 +1,49 @@
## v5.24.2
### 特殊说明
由于本次活动代号 SS 与 SideStory 的内部代号冲突,关卡命名统一采用 AveMujica-x 格式(例如 AveMujica-8请使用 手动输入关卡名 / cli 的博士使用此代号。
### 功能进化 | Highlight
本次更新继续扩展自动化能力,一起来看看吧
#### 自动战斗优化
这个版本我们优化了自动战斗功能,现在你可以在更多的场景下使用自动战斗功能。目前 MAA 支持以下场景:
* `主线/故事集/SideStory`:基础模式,注意只能在当前章节/页面内导航(即 SS 里不能用于切换普通关、EX 关和 S 关);
* `保全派驻`:用于保全派驻模式,可以点击神秘代码输入框右侧的向下小箭头来选择内置作业,并且可以设置循环次数;
* `悖论模拟`:新增的专用于干员悖论模拟的场景,分为以下两种使用方式:
* 直接使用单次战斗:输入神秘代码后,在干员的悖论模拟入口,<u>选择好技能,出现【开始模拟】按钮后,点击 MAA 的开始按钮</u>
* 多个干员连续作战:右键粘贴按钮可以粘贴作业集的神秘代码(或是勾选战斗列表依次输入每个干员的作业的神秘代码),然后<u>在干员列表界面,点击 MAA 的开始按钮</u>。
* `其他活动`:兜底模式,不可使用战斗列表。
现在,博士们可以直接使用悖论模拟的战斗列表功能完成所有悖论模拟作业,支持按职业找人、自动跳过未拥有的干员,并在战斗列表中直接显示干员名,真正实现“点一下,全都打完”~
#### 新内容支持
- **争锋频道:蜜果城** 入口适配(本质还是跑的青草城代码)
- 外服也同步适配了 **新版终端界面**
#### 其他优化
- 自动战斗在关卡结束后增加了黑色返回按钮的检测,更加稳健
- 界面与交互细节继续优化,深色模式显示效果更自然
----
### [CN ONLY] Special Notice
Due to a conflict between this event's code SS and the internal code for SideStory, the stage naming will use the format AveMujica-x (e.g., AveMujica-8). Please use this code when entering the stage manually or via CLI.
#### Copilot Optimization
In this version, we've optimized the Copilot, allowing you to use it in more scenarios. Currently, MAA supports the following scenarios:
* `Main Theme/Intermezzi/SideStory`: Basic mode. Note that navigation is only possible within the current chapter/page (i.e., in SideStory, you cannot switch between normal stages, EX stages, and S stages);
* `SSS`: For SSS mode. You can click the small downward arrow on the right side of the mysterious code input box to select built-in files, also you can set the number of loop times;
* `Paradox Simulation`: A newly added scenario specifically designed for operator paradox simulations, available in the following two usage methods:
* Direct single battle usage: After entering the secret code, you need to navigate to the operator's paradox simulation entry point, <u>select the skills, wait for the [Start Simulation] button to appear, then click MAA's start button</u> to start;
* Continuous battles for multiple operators: You need to rightclick the paste button to paste the mysterious code for the job set, or check the battle list checkbox and sequentially enter each operator's mysterious code for the operation, then <u>click MAA's start button on the operator list interface</u>.
* `Other Events`: Fallback mode, battle list cannot be used.
Now, Doctors can directly use the combat list feature in Paradox Simulation to complete all Paradox Simulation assignments. It supports filtering by profession, automatically skipping unowned Operators, and displaying Operator names directly in the combat list — truly achieving "one click, all done"~
#### New Content Support
- [CN ONLY] **Arena Channel: Honeydew** entry (Use the same code for Green Grass City)
- **New Terminal interface** adaptation for global servers
#### Other Improvements
- Added detection for the black return button after auto-battle ends, making runs more robust
- UI and interaction polish — dark mode looks more natural
----
以下是详细内容:
## v5.24.2
## v5.26.0-beta.1
### 新增 | New
* 适配 命运(AveMujica) 主题 (#13970) @weinibuliu
* SideStory「无忧梦呓」导航 (#13969) @SherkeyXD
* 勾选 「下次公告更新前不再显示」 勾选框时不需要滚到底才能关闭公告 @ABA2396
### 改进 | Improved
* 优化关卡验证逻辑,避免导入错误类型关卡时直接崩溃 @ABA2396
* 次生预案十里坡剑神 @ABA2396
* 设置指引添加更新设置 @ABA2396
* 设置指引添加性能设置 @ABA2396
### 修复 | Fix
* 肉鸽因模拟器卡顿偶现无法退出商店 @ABA2396
* OF-1 无法切换分队 @status102
* 蜜果城模拟器卡顿时可能无法返回主界面 @Windsland52
* 八幡海铃识别错误 @Saratoga-Official
* 选技能可能会点到技能范围 @ABA2396
### 其他 | Other
* 关卡小提示改用 Value @ABA2396
* 调整日志输出格式 @ABA2396
* 悖论模拟选技能改用固定位置,避免透明背景影响 @ABA2396
## v5.24.1
### 新增 | New
* 适配 悬想(界园肉鸽) 主题 (#13948) @weinibuliu
* 繁中服「視相」主題介面 (#13947) @momomochi987
* 悖论通关后自动取消勾选,遇到战斗失败的关卡时停止 (#13963) @ABA2396
### 改进 | Improved
* 日志记录增加 ClassName 输出debug 模式下属性切换新增反引号显示 @ABA2396
* 优化 Copilot 列表验证逻辑,提高性能 @ABA2396
### 修复 | Fix
* 自动编队后续追加自定干员失败 @status102
* 错误的关卡名可能导致验证崩溃 @ABA2396
* 公告重复点击时不会前置窗口 @ABA2396
* 战斗列表无法进入 1/2 星干员悖论 @ABA2396
* 悖论模拟战斗列表页尾干员错位 @ABA2396
* 空作业列表点开始崩溃 @status102
* 繁中服薩米肉鴿第五層名稱 (#13961) @momomochi987
* EN not picking up Trade Orders @Constrat
* IS5 EN StageRefresh not working, updated template @Constrat
* IS2 and IS3 not starting for EN @Constrat
* update Infrast templates for EN @Constrat
* 文档首页语言选择按钮的宽度定义方式 (#14199) @lucienshawls
* 傀影肉鸽无法识别四结局 (#14193) @Saratoga-Official
* GamePassSkip2 识别到错误的跳过 @Saratoga-Official
* 萨米肉鸽不期而遇避战 @Saratoga-Official
* Google Play Games Developer shutdown @Constrat
* manual set resource version time @MistEO
* prettier @Constrat
### 文档 | Docs
* 修正文档中的部分错误 (#13923) @lucienshawls
* 补充vsc插件繁中文档 @Rbqwow
* 修复文档站 readme 盾换行 @Rbqwow
* 调整文档站的标题和尾注文本显示 (#14213) @lucienshawls
* 更新网页开发相关文档 (#14167) @Rbqwow @Manicsteiner
* 完善任务流程协议文档 (#13232) @zzyyyl
* 回调消息协议文档视觉更新 @SherkeyXD
* 集成文档视觉更新 @SherkeyXD
* 文档启用 b 站视频播放功能 @SherkeyXD
* 文档添加字段容器功能 @SherkeyXD
* 文档添加功能 @SherkeyXD
* 更新文档编写指南 @SherkeyXD
* 标题 MAA 统一采用缩写 @MistEO
* 再次调整文档站标题( @MistEO
* 调整文档站标题 @MistEO
* Update JP(#14227) @wallsman
* markdown pre-commit @zzyyyl
* add extension's evaluating feature @neko-para
* add telegram icon @SherkeyXD
### 其他 | Other
* 将 「掉线时自动重连」 从 「运行设置」 移到 「刷理智设置」 中 @ABA2396
* 将 「自动肉鸽在战斗结束前延迟停止动作」 从 「运行设置」 移到 「肉鸽设置」 中 @ABA2396
* 繁中服「銀心湖列車」復刻活動導航 (#13945) @momomochi987
* 调整公告日志记录 @ABA2396
* 提取 isBuildOutputFolder @ABA2396
* 编译目录下不检查 dll @ABA2396
* 长草任务运行状态 (#13928) @status102
* 简化 Split @ABA2396
* OperatorType -> OperatorRole @status102
* JP ocr fix (#13938) @Manicsteiner
* i18n @Constrat @Manicsteiner
## v5.24.0
### 新增 | New
* 悖论模拟战斗列表通过职业找人 @ABA2396
* 悖论模拟战斗列表支持跳过未拥有的干员 @ABA2396
* 战斗列表悖论模拟关卡名转为干员名 @ABA2396
* 支持一键悖论模拟 (#13893) @status102 @Constrat @Burnside999 @momomochi987 @HX3N @Manicsteiner @ABA2396
* 争锋频道:蜜果城 @ABA2396
* mac 支持蜜果城 @ABA2396
* 调整战斗列表提示描述 @ABA2396
* 远程通知添加 `[MAA]` 前缀 @ABA2396
* 加个启动提醒 @ABA2396
* 在启动时检测额外的 DLL 文件 (#13850) @Rbqwow @ABA2396
* 自动战斗关卡结束后增加识别使用黑色返回按钮的检测 @status102
* 更新源为海外源时隐藏 Mirror酱 CDK 输入框 @ABA2396
### 改进 | Improved
* 覆盖 ThirdlyTextBrush优化深色模式下的显示效果 @ABA2396
* 任务 baseTask @status102
* 重构自动战斗战斗列表 (#13852) @status102
* 更新 CsWin32 @ABA2396
* ToastNotification 重构 @ABA2396
* 向战斗队列中添加 SSS 作业时追加错误输出 @status102
* limit codeql run only to source code (#13802) @Constrat
### 修复 | Fix
* 悖论模拟单文件无法使用 @ABA2396
* 关卡名下划线被解释成 CheckBox 访问键 @ABA2396
* 勾八导航乱写 @ABA2396
* 自动战斗界面 Idle setter 限制 @status102
* 自动战斗-战斗列表使用错误的作业战斗 @status102
* 信用购物有时候点不掉危机合约支援界面 @ABA2396
* ServerChan 未使用通用 httpService @ABA2396
* 错误清除 _tasksStatus 的时机 @ABA2396
* 肉鸽入口等待 ocr 识别错误 @ABA2396
* 界园肉鸽商店钱包余额ocr roi @status102
* 自动战斗-战斗列表`突袭`提示显示在运行期显示效果 @status102
* 不再点击停止任务时移除存储的 TaskId @status102
* 繁中服薩米肉鴿第四層名稱 (#13846) @momomochi987
* 肉鸽投资存款不变重试 20 次退出 @status102
* required version 显示错误 @ABA2396
* 会客室换班失败(如选人过程中弹出线索交流完成)时重开任务 @ABA2396
* 肉鸽开局招募在无开局干员时, 无法识别两招募的左侧位 @status102
* 千古鸭帝进战斗 @Saratoga-Official
* 日服的萨卡兹第五层怎么全 jb 改成 exit 了 @ABA2396
* 自动战斗干员编队状态; 修复编队中干员属性未达标时反复报错; 缺少干员输出时, 干员组内干员打平输出 (#13795) @status102
* 修正生息演算中 "丰饶灌木林" 的 OCR 识别 (#13825) @Alan-Charred
* 资源更新文件处理 @hguandl
* 萨卡兹肉鸽因动画延时偶发无法领取去伪存真合成物品 @ABA2396
* 萨米投资进二层会卡在预见密文板 @ABA2396
* CrownSlayer -> Crownslayer for EN @Constrat
* RoguelikeDialogSkip for EN @Constrat
* BattleQuickFormationExpandRole text ocr @Constrat
* OfficeMini template for EN @Constrat
* OfficeMini template for EN @Constrat
* ROI and text for EA YostarEN @Constrat
* YostarEN text render template changes @Constrat
* var type @status102
* YostarKR EA navigation @HX3N
* filters @ABA2396
### 其他 | Other
* 整合枚举类 OperProfession 和 Role (#13914) @soundofautumn
* 悖论模拟使用多任务流程 @status102
* 移除MaaCore不再支持的自动战斗作业代码解析 @status102
* 删掉 core 的联网功能 @ABA2396
* core 删除 cpr @ABA2396
* dll 检测排除带 maa 的 dll @ABA2396
* 自动战斗模组错误本地化 & 移除多余的行末空格 (#13800) @soundofautumn @Constrat @HX3N
* 调整小游戏内容顺序 @ABA2396
* 修改 RA 和肉鸽的进入终端等待时间 @ABA2396
* 调整萨卡兹,界园的古米精二优先度 @Saratoga-Official
* 修改备份文件写入时间 @ABA2396
* 关机/休眠/睡眠 统一调用 PowerManagement @ABA2396
* 调整 GetModuleFileName 判断 @ABA2396
* 移除未使用的 container @ABA2396
* mumu 使用 7555 端口时禁用 Index 检测,添加日志警告 @ABA2396
* file header @status102
* 自动编队助战的确实干员读取 @status102
* 加点肉鸽事件 fallback 前延迟,可能减轻点网络波动影响 @ABA2396
* 自动战斗不再使用 `need_navigate` 字段作为导航启用开关, 而是直接使用 `navigate_name` 字段 @status102
* 调整技能截图判断 @ABA2396
* YostarEN updated main stage navigation (#13906) @Constrat
* Give new line for English downloading from @Constrat
* YostarJP remove old navigation (#13905) @Manicsteiner
* YostarJP/KR new main stage navigation and ocr fix @Manicsteiner @HX3N
* A single-line comment within C# code is not preceded by a blank line. @ABA2396
* A C# partial element is missing a documentation header. @ABA2396
* An item within a C# enumeration is missing an Xml documentation header. @ABA2396
* A C# method, constructor, delegate or indexer element is missing documentation for one or more of its parameters. @ABA2396
* The XML header documentation for a C# element is missing a tag. @ABA2396
* Copyright 2025 @ABA2396
* Update localization strings for Mini Game section @AnnAngela
* 统一显示效果 @ABA2396
* 水月萨米肉鸽不期而遇避战 @Saratoga-Official
* 重写完成后动作仅一次的 ui 字符串 (#14196) @Rbqwow
* 贸易站没其他好用的人再用锏 @ABA2396
* YostarJP Sarkaz roguelike StageEncounter (#14223) @Manicsteiner
* YostarJP sami roguelike 720p (#14210) @Manicsteiner
* YostarJP Mizuki StageEncounter (#14206) @Manicsteiner
* devcontainer.json (#14169) @Rbqwow @lucienshawls

View File

@@ -1,22 +1,21 @@
cmake_minimum_required(VERSION 3.28)
project(MAA)
if (NOT CMAKE_BUILD_TYPE)
if(NOT CMAKE_BUILD_TYPE)
set(CMAKE_BUILD_TYPE "Release" CACHE STRING "Choose the type of build." FORCE)
endif ()
endif()
list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_LIST_DIR}/cmake/modules")
option(BUILD_WPF_GUI "build MaaWpfGui" ${WIN32})
option(BUILD_DEBUG_DEMO "build debug demo" OFF)
option(BUILD_XCFRAMEWORK "build xcframework for macOS app" OFF)
option(BUILD_UNIVERSAL "build both arm64 and x86_64 on macOS" OFF)
option(BUILD_SMOKE_TEST "build smoke_test" OFF)
option(INSTALL_PYTHON "install python ffi" OFF)
option(INSTALL_RESOURCE "install resource" OFF)
option(INSTALL_FLATTEN "do not use bin lib include directory" ON)
option(WITH_EMULATOR_EXTRAS "build with emulator extras" ${WIN32})
option(BUILD_SMOKE_TEST "build smoke_test" OFF)
option(BUILD_RES_UPDATER "build ResourceUpdater" OFF)
option(WITH_HASH_VERSION "generate version from git hash" OFF)
include(${PROJECT_SOURCE_DIR}/MaaDeps/maadeps.cmake)
@@ -24,12 +23,16 @@ include(${PROJECT_SOURCE_DIR}/cmake/config.cmake)
include(${PROJECT_SOURCE_DIR}/cmake/utils.cmake)
include(${PROJECT_SOURCE_DIR}/cmake/version.cmake)
if(APPLE)
include(${PROJECT_SOURCE_DIR}/cmake/macos.cmake)
endif()
if(INSTALL_FLATTEN)
set(MaaCore_install_flatten_args RUNTIME DESTINATION . LIBRARY DESTINATION . PUBLIC_HEADER DESTINATION .)
endif()
add_library(HeaderOnlyLibraries INTERFACE)
target_include_directories(HeaderOnlyLibraries INTERFACE 3rdparty/include 3rdparty/EmulatorExtras)
file(GLOB_RECURSE maa_src src/MaaCore/*.h src/MaaCore/*.hpp src/MaaCore/*.cpp)
add_library(MaaCore SHARED ${maa_src})
target_include_directories(HeaderOnlyLibraries INTERFACE 3rdparty/include)
find_package(OpenCV REQUIRED COMPONENTS core imgproc imgcodecs)
find_package(Boost REQUIRED CONFIG COMPONENTS system)
@@ -37,113 +40,22 @@ find_package(ZLIB REQUIRED)
find_package(fastdeploy_ppocr REQUIRED)
find_package(ONNXRuntime REQUIRED)
target_link_libraries(MaaCore HeaderOnlyLibraries ${OpenCV_LIBS} fastdeploy_ppocr ONNXRuntime::ONNXRuntime ZLIB::ZLIB Boost::system)
if(WIN32)
target_link_libraries(MaaCore ws2_32)
endif()
if(LINUX)
target_link_libraries(MaaCore pthread)
endif()
add_subdirectory(src/MaaCore)
source_group(TREE ${CMAKE_CURRENT_SOURCE_DIR} FILES ${maa_src})
if (WIN32)
#注意相比VS版本缺少了 -D_CONSOLE -D_WINDLL 两项
target_compile_definitions(MaaCore PRIVATE ASST_DLL_EXPORTS _UNICODE UNICODE)
endif ()
target_include_directories(MaaCore PUBLIC include PRIVATE src/MaaCore)
set(MaaCore_PUBLIC_HEADERS include/AsstCaller.h include/AsstPort.h)
target_sources(MaaCore PUBLIC ${MaaCore_PUBLIC_HEADERS})
set_target_properties(MaaCore PROPERTIES PUBLIC_HEADER "${MaaCore_PUBLIC_HEADERS}")
if(WIN32)
add_custom_command(
TARGET MaaCore
POST_BUILD
COMMAND ${CMAKE_COMMAND} -E copy_directory_if_different
"${PROJECT_SOURCE_DIR}/MaaDeps/runtime/${MAADEPS_TRIPLET}/$<$<CONFIG:Debug>:msvc-debug/>"
$<TARGET_FILE_DIR:MaaCore>
COMMAND_EXPAND_LISTS)
endif()
if (BUILD_WPF_GUI)
if(BUILD_WPF_GUI)
include_external_msproject(MaaWpfGui ${PROJECT_SOURCE_DIR}/src/MaaWpfGui/MaaWpfGui.csproj)
add_dependencies(MaaWpfGui MaaCore)
endif()
if(APPLE)
set_target_properties(MaaCore PROPERTIES INSTALL_RPATH "@loader_path/")
elseif(UNIX)
set_target_properties(MaaCore PROPERTIES INSTALL_RPATH "$ORIGIN/")
endif()
if(WITH_EMULATOR_EXTRAS AND NOT EXISTS ${PROJECT_SOURCE_DIR}/3rdparty/EmulatorExtras/Mumu)
message(WARNING "EmulatorExtras not found, please run `git submodule update --init 3rdparty/EmulatorExtras`")
set(WITH_EMULATOR_EXTRAS OFF)
endif()
target_compile_definitions(MaaCore PRIVATE ASST_WITH_EMULATOR_EXTRAS=$<BOOL:${WITH_EMULATOR_EXTRAS}>)
if(INSTALL_FLATTEN)
set(MaaCore_install_flatten_args RUNTIME DESTINATION . LIBRARY DESTINATION . PUBLIC_HEADER DESTINATION .)
endif()
install(TARGETS MaaCore ${MaaCore_install_flatten_args})
maadeps_install(.)
if (INSTALL_PYTHON)
if(INSTALL_PYTHON)
install(DIRECTORY src/Python DESTINATION .)
endif (INSTALL_PYTHON)
if (INSTALL_RESOURCE)
endif()
if(INSTALL_RESOURCE)
install(DIRECTORY resource DESTINATION .)
endif (INSTALL_RESOURCE)
endif()
if (BUILD_DEBUG_DEMO)
add_executable(debug_demo src/Cpp/main.cpp)
if(MSVC)
target_compile_options(debug_demo PRIVATE "/WX-")
else()
target_compile_options(debug_demo PRIVATE "-Wno-error")
endif()
target_link_libraries(debug_demo MaaCore)
add_dependencies(debug_demo MaaCore)
# install(TARGETS debug_demo ${MaaCore_install_flatten_args})
endif (BUILD_DEBUG_DEMO)
if (BUILD_SMOKE_TEST)
add_executable(smoke_test src/Cpp/main.cpp)
if(MSVC)
target_compile_options(smoke_test PRIVATE "/WX-")
else()
target_compile_options(smoke_test PRIVATE "-Wno-error")
endif()
target_compile_definitions(smoke_test PRIVATE SMOKE_TESTING)
target_link_libraries(smoke_test MaaCore)
add_dependencies(smoke_test MaaCore)
install(TARGETS smoke_test ${MaaCore_install_flatten_args})
endif (BUILD_SMOKE_TEST)
if (BUILD_RES_UPDATER)
add_executable(ResourceUpdater tools/ResourceUpdater/main.cpp)
target_include_directories(ResourceUpdater PUBLIC include PRIVATE src/MaaCore) # For Utils/Time.hpp
target_link_libraries(ResourceUpdater HeaderOnlyLibraries ${OpenCV_LIBS})
if(LINUX)
target_link_libraries(ResourceUpdater pthread)
endif()
install(TARGETS ResourceUpdater DESTINATION . COMPONENT ResourceUpdater)
# Copy from maadeps_install, adding component
if(MSVC)
install(DIRECTORY "${CMAKE_CURRENT_LIST_DIR}/MaaDeps/runtime/${MAADEPS_TRIPLET}/$<$<CONFIG:Debug>:msvc-debug/>" DESTINATION . USE_SOURCE_PERMISSIONS COMPONENT ResourceUpdater)
else()
install(DIRECTORY "${CMAKE_CURRENT_LIST_DIR}/MaaDeps/runtime/${MAADEPS_TRIPLET}/" DESTINATION . USE_SOURCE_PERMISSIONS COMPONENT ResourceUpdater)
endif()
endif (BUILD_RES_UPDATER)
if (APPLE)
include(${PROJECT_SOURCE_DIR}/cmake/macos.cmake)
endif (APPLE)
if(BUILD_DEBUG_DEMO OR BUILD_SMOKE_TEST)
add_subdirectory(src/Cpp)
endif()

View File

@@ -4,7 +4,7 @@
<img alt="LOGO" src="./docs/.vuepress/public/images/maa-logo_512x512.png" width="256" height="256" />
# MaaAssistantArknights
# MAA
<br>
<div>
@@ -25,7 +25,7 @@
<!-- markdownlint-restore -->
[简体中文](https://maa.plus/docs/zh-cn/) | [繁體中文](https://maa.plus/docs/zh-tw/) | [English](https://maa.plus/docs/en-us/) | [日本語](https://maa.plus/docs/ja-jp/) | [한국어](https://maa.plus/docs/ko-kr/)
[简体中文](https://docs.maa.plus/zh-cn/) | [繁體中文](https://docs.maa.plus/zh-tw/) | [English](https://docs.maa.plus/en-us/) | [日本語](https://docs.maa.plus/ja-jp/) | [한국어](https://docs.maa.plus/ko-kr/)
MAA 的意思是 MAA Assistant Arknights
@@ -39,12 +39,12 @@ MAA 的意思是 MAA Assistant Arknights
## 下载与安装
请阅读 [文档](https://maa.plus/docs/zh-cn/manual/newbie.html) 后前往 [官网](https://maa.plus) 或 [Releases](https://github.com/MaaAssistantArknights/MaaAssistantArknights/releases) 下载,并参考 [新手上路](https://maa.plus/docs/zh-cn/manual/newbie.html) 进行安装。
请阅读 [文档](https://docs.maa.plus/zh-cn/manual/newbie.html) 后前往 [官网](https://maa.plus) 或 [Releases](https://github.com/MaaAssistantArknights/MaaAssistantArknights/releases) 下载,并参考 [新手上路](https://docs.maa.plus/zh-cn/manual/newbie.html) 进行安装。
## 亮点功能
- 刷理智,掉落识别及上传 [企鹅物流](https://penguin-stats.cn/)[一图流](https://ark.yituliu.cn/)
- 智能基建换班,自动计算干员效率,单设施内最优解;同时也支持 [自定义排班](https://maa.plus/docs/zh-cn/protocol/base-scheduling-schema.html)
- 智能基建换班,自动计算干员效率,单设施内最优解;同时也支持 [自定义排班](https://docs.maa.plus/zh-cn/protocol/base-scheduling-schema.html)
- 自动公招,可选使用加急许可,一次全部刷完!公招数据自动上传 [企鹅物流](https://penguin-stats.cn/result/stage/recruit/recruit)[一图流](https://ark.yituliu.cn/survey/maarecruitdata)
- 支持手动识别公招界面,方便对高星公招做出选择 ~~(你的这个高资回费出的是推王呢还是推王呢)~~
- 支持识别干员列表,统计已有和未有干员及潜能,并在公招识别显示
@@ -83,16 +83,16 @@ MAA 的意思是 MAA Assistant Arknights
### 功能介绍
请参阅 [用户手册](https://maa.plus/docs/zh-cn/manual/)。
请参阅 [用户手册](https://docs.maa.plus/zh-cn/manual/)。
### 外服支持
目前国际服(美服)、日服、韩服、繁中服的绝大部分功能均已支持。但由于外服用户较少及项目人手不足,很多功能并没有进行全面的测试,所以请自行体验。
若您遇到了 Bug或对某个功能有强需求欢迎在 [Issues](https://github.com/MaaAssistantArknights/MaaAssistantArknights/issues) 和 [讨论区](https://github.com/MaaAssistantArknights/MaaAssistantArknights/discussions) 催更;或加入我们一起建设 MAA请参阅 [外服适配教程](https://maa.plus/docs/zh-cn/develop/overseas-client-adaptation.html)
若您遇到了 Bug或对某个功能有强需求欢迎在 [Issues](https://github.com/MaaAssistantArknights/MaaAssistantArknights/issues) 和 [讨论区](https://github.com/MaaAssistantArknights/MaaAssistantArknights/discussions) 催更;或加入我们一起建设 MAA请参阅 [外服适配教程](https://docs.maa.plus/zh-cn/develop/overseas-client-adaptation.html)
### CLI 支持
MAA 支持命令行界面CLI操作支持 LinuxmacOS 和 Windows可用于自动化脚本或在无图形界面的服务器上使用。请参阅 [CLI 使用指南](https://maa.plus/docs/zh-cn/manual/cli/)
MAA 支持命令行界面CLI操作支持 LinuxmacOS 和 Windows可用于自动化脚本或在无图形界面的服务器上使用。请参阅 [CLI 使用指南](https://docs.maa.plus/zh-cn/manual/cli/)
## 加入我们
@@ -103,7 +103,7 @@ MAA 支持命令行界面CLI操作支持 LinuxmacOS 和 Windows
- 全新框架:[MaaFramework](https://github.com/MaaXYZ/MaaFramework)
- [作业站](https://prts.plus) 前端:[maa-copilot-frontend](https://github.com/MaaAssistantArknights/maa-copilot-frontend)
- [作业站](https://prts.plus) 后端:[MaaBackendCenter](https://github.com/MaaAssistantArknights/MaaBackendCenter)
- [官网](https://maa.plus)[前端](website)
- [官网](https://maa.plus)[前端](https://github.com/MaaAssistantArknights/maa-website)
- 深度学习:[MaaAI](https://github.com/MaaAssistantArknights/MaaAI)
### 多语言 (i18n)
@@ -114,11 +114,11 @@ MAA 以中文(简体)为第一语言,翻译词条均以中文(简体)
#### Windows
请参阅 [开始开发](https://maa.plus/docs/zh-cn/develop/development.html)。
请参阅 [开始开发](https://docs.maa.plus/zh-cn/develop/development.html)。
#### Linux | macOS
请参阅 [Linux 编译教程](https://maa.plus/docs/zh-cn/develop/linux-tutorial.html)。
请参阅 [Linux 编译教程](https://docs.maa.plus/zh-cn/develop/linux-tutorial.html)。
#### API
@@ -131,22 +131,22 @@ MAA 以中文(简体)为第一语言,翻译词条均以中文(简体)
- [Rust 接口](src/Rust/src/maa_sys)[HTTP 接口](src/Rust)
- [TypeScript 接口](https://github.com/MaaAssistantArknights/MaaX/tree/main/packages/main/coreLoader)
- [Woolang 接口](src/Woolang/maa.wo)[集成示例](src/Woolang/demo.wo)
- [集成文档](https://maa.plus/docs/zh-cn/protocol/integration.html)
- [回调消息协议](https://maa.plus/docs/zh-cn/protocol/callback-schema.html)
- [任务流程协议](https://maa.plus/docs/zh-cn/protocol/task-schema.html)
- [自动抄作业协议](https://maa.plus/docs/zh-cn/protocol/copilot-schema.html)
- [集成文档](https://docs.maa.plus/zh-cn/protocol/integration.html)
- [回调消息协议](https://docs.maa.plus/zh-cn/protocol/callback-schema.html)
- [任务流程协议](https://docs.maa.plus/zh-cn/protocol/task-schema.html)
- [自动抄作业协议](https://docs.maa.plus/zh-cn/protocol/copilot-schema.html)
#### 外服适配
请参阅 [外服适配教程](https://maa.plus/docs/zh-cn/develop/overseas-client-adaptation.html),对于国服已支持的功能,绝大部分的外服适配工作仅需要截图 + 简单的 JSON 修改即可。
请参阅 [外服适配教程](https://docs.maa.plus/zh-cn/develop/overseas-client-adaptation.html),对于国服已支持的功能,绝大部分的外服适配工作仅需要截图 + 简单的 JSON 修改即可。
#### 想参与开发,但不太会用 GitHub?
[GitHub Pull Request 流程简述](https://maa.plus/docs/zh-cn/develop/development.html#github-pull-request-流程简述)
[GitHub Pull Request 流程简述](https://docs.maa.plus/zh-cn/develop/development.html#github-pull-request-流程简述)
#### Issue bot
请参阅 [Issue Bot 使用方法](https://maa.plus/docs/zh-cn/develop/issue-bot-usage.html)
请参阅 [Issue Bot 使用方法](https://docs.maa.plus/zh-cn/develop/issue-bot-usage.html)
## 致谢

View File

@@ -43,7 +43,7 @@ if(LINUX)
OUTPUT_STRIP_TRAILING_WHITESPACE
)
if("${LIB_PATH}" STREQUAL "${LIBNAME}.so.1}")
if("${LIB_PATH}" STREQUAL "${LIBNAME}.so.1")
message(FATAL_ERROR "Could not locate ${LIBNAME}.so.1 using compiler")
endif()
@@ -63,7 +63,7 @@ if(LINUX)
message(STATUS "${LIBNAME}.so.1 path: ${LIB_PATH_REAL}")
install(FILES "${LIB_PATH_REAL}" DESTINATION . RENAME "${LIBNAME}.so.1")
install(FILES "${LIB_PATH_REAL}" DESTINATION . RENAME "${LIBNAME}.so.1" COMPONENT libcxx)
get_filename_component(LIB_PATH_DIR "${LIB_PATH_REAL}" DIRECTORY)
list(APPEND CMAKE_BUILD_RPATH "${LIB_PATH_DIR}")

View File

@@ -1,19 +0,0 @@
set(CMAKE_SYSTEM_NAME Linux)
set(CMAKE_SYSTEM_PROCESSOR aarch64)
set(XTOOLS_ROOT ${CMAKE_CURRENT_LIST_DIR}/../../MaaDeps/x-tools/aarch64-linux-gnu)
set(CMAKE_C_COMPILER_TARGET aarch64-linux-gnu)
set(CMAKE_C_COMPILER clang-20)
set(CMAKE_CXX_COMPILER_TARGET aarch64-linux-gnu)
set(CMAKE_CXX_COMPILER clang++-20)
set(CMAKE_ASM_COMPILER_TARGET aarch64-linux-gnu)
set(CMAKE_ASM_COMPILER clang-20)
set(CMAKE_SYSROOT ${XTOOLS_ROOT}/aarch64-linux-gnu/sysroot)
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -stdlib=libc++ --sysroot=${CMAKE_SYSROOT}")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fPIC -stdlib=libc++ --sysroot=${CMAKE_SYSROOT}")
set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -fPIC -stdlib=libc++ --sysroot=${CMAKE_SYSROOT} -fuse-ld=lld --gcc-toolchain=${XTOOLS_ROOT}")
set(CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} -fPIC -stdlib=libc++ --sysroot=${CMAKE_SYSROOT} -fuse-ld=lld --gcc-toolchain=${XTOOLS_ROOT}")
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -fPIC -stdlib=libc++ --sysroot=${CMAKE_SYSROOT} -fuse-ld=lld --gcc-toolchain=${XTOOLS_ROOT}")
set(CMAKE_LINKER_TYPE LLD)

View File

@@ -1,19 +0,0 @@
set(CMAKE_SYSTEM_NAME Linux)
set(CMAKE_SYSTEM_PROCESSOR x86_64)
set(XTOOLS_ROOT ${CMAKE_CURRENT_LIST_DIR}/../../MaaDeps/x-tools/x86_64-linux-gnu)
set(CMAKE_C_COMPILER_TARGET x86_64-linux-gnu)
set(CMAKE_C_COMPILER clang-20)
set(CMAKE_CXX_COMPILER_TARGET x86_64-linux-gnu)
set(CMAKE_CXX_COMPILER clang++-20)
set(CMAKE_ASM_COMPILER_TARGET x86_64-linux-gnu)
set(CMAKE_ASM_COMPILER clang-20)
set(CMAKE_SYSROOT ${XTOOLS_ROOT}/x86_64-linux-gnu/sysroot)
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC -stdlib=libc++ --sysroot=${CMAKE_SYSROOT}")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fPIC -stdlib=libc++ --sysroot=${CMAKE_SYSROOT}")
set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -fPIC -stdlib=libc++ --sysroot=${CMAKE_SYSROOT} -fuse-ld=lld --gcc-toolchain=${XTOOLS_ROOT}")
set(CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} -fPIC -stdlib=libc++ --sysroot=${CMAKE_SYSROOT} -fuse-ld=lld --gcc-toolchain=${XTOOLS_ROOT}")
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -fPIC -stdlib=libc++ --sysroot=${CMAKE_SYSROOT} -fuse-ld=lld --gcc-toolchain=${XTOOLS_ROOT}")
set(CMAKE_LINKER_TYPE LLD)

View File

@@ -25,6 +25,3 @@ if (BUILD_XCFRAMEWORK)
)
endif (BUILD_XCFRAMEWORK)
target_compile_options(MaaCore PRIVATE
-Wno-deprecated-declarations
-Wno-gnu-zero-variadic-macro-arguments)

View File

@@ -44,3 +44,30 @@ endif(APPLE)
if(NOT DEFINED MAADEPS_TRIPLET)
detect_maadeps_triplet(MAADEPS_TRIPLET)
endif()
# 创建资源目录链接的函数
function(create_resource_link TARGET_NAME OUTPUT_DIR)
if(WIN32)
# Windows 使用 mklink /J 创建目录链接(不需要管理员权限)
add_custom_command(
TARGET ${TARGET_NAME}
POST_BUILD
COMMAND ${CMAKE_COMMAND} -E echo "Creating resource directory link for ${TARGET_NAME}..."
COMMAND ${CMAKE_COMMAND} -E remove_directory "${OUTPUT_DIR}/resource"
COMMAND cmd /c "mklink /J \"${OUTPUT_DIR}/resource\" \"${PROJECT_SOURCE_DIR}/resource\""
COMMAND ${CMAKE_COMMAND} -E echo "Resource directory link created successfully"
COMMENT "Creating junction for resource directory for ${TARGET_NAME}"
)
else()
# Unix/Linux/macOS 使用符号链接
add_custom_command(
TARGET ${TARGET_NAME}
POST_BUILD
COMMAND ${CMAKE_COMMAND} -E echo "Creating resource directory link for ${TARGET_NAME}..."
COMMAND ${CMAKE_COMMAND} -E remove "${OUTPUT_DIR}/resource"
COMMAND ${CMAKE_COMMAND} -E create_symlink "${PROJECT_SOURCE_DIR}/resource" "${OUTPUT_DIR}/resource"
COMMAND ${CMAKE_COMMAND} -E echo "Resource directory link created successfully"
COMMENT "Creating symlink for resource directory for ${TARGET_NAME}"
)
endif()
endfunction()

View File

@@ -3,23 +3,23 @@ set(MAA_HASH_VERSION
"DEBUG_VERSION"
CACHE STRING "maa version")
if(MAA_HASH_VERSION STREQUAL "DEBUG_VERSION")
if(WITH_HASH_VERSION AND MAA_HASH_VERSION STREQUAL "DEBUG_VERSION")
find_package(Git)
endif()
if(MAA_HASH_VERSION STREQUAL "DEBUG_VERSION" AND GIT_FOUND)
execute_process(
COMMAND "${GIT_EXECUTABLE}" rev-parse HEAD
WORKING_DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}"
RESULT_VARIABLE result
OUTPUT_VARIABLE output
ERROR_VARIABLE err
OUTPUT_STRIP_TRAILING_WHITESPACE)
if(GIT_FOUND)
execute_process(
COMMAND "${GIT_EXECUTABLE}" rev-parse HEAD
WORKING_DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}"
RESULT_VARIABLE result
OUTPUT_VARIABLE output
ERROR_VARIABLE err
OUTPUT_STRIP_TRAILING_WHITESPACE)
if(result EQUAL 0)
set(MAA_HASH_VERSION "${output}")
else()
message(WARNING "git rev-parse returning ${result}, output:\n${err}")
if(result EQUAL 0)
set(MAA_HASH_VERSION "${output}")
else()
message(WARNING "git rev-parse returning ${result}, output:\n${err}")
endif()
endif()
endif()

2
docs/.prettierignore Normal file
View File

@@ -0,0 +1,2 @@
**/pnpm-lock.yaml
**/*.md

40
docs/.prettierrc.js Normal file
View File

@@ -0,0 +1,40 @@
module.exports = {
printWidth: 120,
tabWidth: 2,
useTabs: false,
bracketSpacing: true,
bracketSameLine: false,
endOfLine: 'auto',
semi: false,
singleQuote: true,
trailingComma: 'all',
arrowParens: 'always',
overrides: [
{
files: ['**/*.ts'],
options: {
semi: true,
},
},
{
files: ['**/*.*css'],
options: {
singleQuote: false,
},
},
{
files: ['**/*.yml', '**/*.yaml'],
options: {
parser: 'yaml',
singleQuote: false,
},
},
{
files: ['**/*.json'],
options: {
tabWidth: 4,
},
},
],
}

View File

@@ -1,12 +1,11 @@
import { defineClientConfig } from "vuepress/client";
import Image1 from "../components/Image1.vue";
import Image2 from "../components/Image2.vue";
import Image4 from "../components/Image4.vue";
import { defineClientConfig } from 'vuepress/client';
import ImageGrid from './components/ImageGrid.vue';
import './styles/index.scss';
export default defineClientConfig({
enhance: ({ app }) => {
app.component("Image1", Image1);
app.component("Image2", Image2);
app.component("Image4", Image4);
app.component('ImageGrid', ImageGrid);
},
});

View File

@@ -0,0 +1,72 @@
<template>
<CardGrid>
<ImageCard v-for="(item, index) of displayImageList" :key="index" :image="item" />
</CardGrid>
</template>
<script lang="ts">
import { PropType, defineComponent, computed, ref, onMounted, onUnmounted } from 'vue'
import { withBase } from 'vuepress/client'
export default defineComponent({
name: 'ImageCardGrid',
props: {
imageList: {
type: Array as PropType<Array<{ light: string; dark: string } | string>>,
required: true,
},
},
setup(props) {
const isDarkMode = ref(false)
let observer: MutationObserver | null = null
let mediaQuery: MediaQueryList | null = null
const updateDarkMode = () => {
if (typeof window !== 'undefined') {
const html = document.documentElement
isDarkMode.value =
html.classList.contains('dark') ||
html.getAttribute('data-theme') === 'dark' ||
window.matchMedia('(prefers-color-scheme: dark)').matches
}
}
onMounted(() => {
updateDarkMode()
if (typeof window !== 'undefined') {
// 监听DOM变化主题切换通常会改变class或data-theme属性
observer = new MutationObserver(updateDarkMode)
observer.observe(document.documentElement, {
attributes: true,
attributeFilter: ['class', 'data-theme'],
})
// 监听系统主题变化
mediaQuery = window.matchMedia('(prefers-color-scheme: dark)')
mediaQuery.addEventListener('change', updateDarkMode)
}
})
onUnmounted(() => {
if (observer) {
observer.disconnect()
}
if (mediaQuery) {
mediaQuery.removeEventListener('change', updateDarkMode)
}
})
const displayImageList = computed(() => {
return props.imageList.map((item) => {
const src = typeof item === 'string' ? item : isDarkMode.value ? item.dark : item.light
return withBase(src)
})
})
return {
displayImageList,
}
},
})
</script>

View File

@@ -1,55 +0,0 @@
import type { VNode } from "vue";
import { defineComponent, h, computed } from "vue";
import NavbarDropdown from "@theme-hope/modules/navbar/components/NavbarDropdown";
import { I18nIcon } from "@theme-hope/modules/navbar/components/icons/index";
import { useNavbarLanguageDropdown } from "@theme-hope/modules/navbar/composables/index";
export default defineComponent({
name: "LanguageDropdown",
setup() {
const dropdown = useNavbarLanguageDropdown();
const filteredDropdown = computed(() => {
if (!dropdown.value) return null;
const filteredConfig = { ...dropdown.value };
if (filteredConfig.children) {
filteredConfig.children = filteredConfig.children.filter(item => {
// 过滤掉跳转到根目录的项目
return item.link !== '/' && item.link !== '/docs/' && !item.link?.endsWith('/docs/');
});
}
return filteredConfig;
});
//console.log("OldLanguageDropdown", dropdown.value);
//console.log("NewLanguageDropdown", filteredDropdown());
return (): VNode | null =>
dropdown.value
? h(
"div",
{ class: "vp-nav-item" },
h(
NavbarDropdown,
{ config: filteredDropdown.value },
{
title: () =>
h(I18nIcon, {
"aria-label": filteredDropdown.value?.ariaLabel,
style: {
width: "1rem",
height: "1rem",
verticalAlign: "middle",
},
}),
},
),
)
: null;
},
});

View File

@@ -1,87 +1,70 @@
import { defineUserConfig } from "vuepress";
import { getDirname, path } from "vuepress/utils";
import { viteBundler } from "@vuepress/bundler-vite";
import { googleAnalyticsPlugin } from "@vuepress/plugin-google-analytics";
import Theme from "./theme";
import { viteBundler } from '@vuepress/bundler-vite';
import { defineUserConfig } from 'vuepress';
import { googleAnalyticsPlugin } from '@vuepress/plugin-google-analytics';
import { plumeTheme } from 'vuepress-theme-plume';
const __dirname = getDirname(import.meta.url);
import DocSearchConfig from './plugins/search';
const isProd = process.env.NODE_ENV === 'production';
export default defineUserConfig({
base: "/docs/",
lang: "zh-CN",
title: "MaaAssistantArknights",
description: "MAA",
base: '/',
lang: 'zh-CN',
title: 'MAA 文档站',
description: 'MAA —「明日方舟」小助手',
host: '0.0.0.0',
port: 3001,
locales: {
"/zh-cn/": {
lang: "zh-cn",
description: "文档",
'/zh-cn/': {
lang: 'zh-CN',
title: 'MAA 文档站',
description: '文档',
},
"/zh-tw/": {
lang: "zh-tw",
description: "文件",
'/zh-tw/': {
lang: 'zh-TW',
title: 'MAA 文件站',
description: '文件',
},
"/en-us/": {
lang: "en-us",
description: "Documentation",
'/en-us/': {
lang: 'en-US',
title: 'MAA Documentation Site',
description: 'Documentation',
},
"/ja-jp/": {
lang: "ja-jp",
description: "ドキュメンテーション",
'/ja-jp/': {
lang: 'ja-JP',
title: 'MAA ドキュメントサイト',
description: 'ドキュメント',
},
"/ko-kr/": {
lang: "ko-kr",
description: "선적 서류 비치",
'/ko-kr/': {
lang: 'ko-KR',
title: 'MAA 문서 사이트',
description: '문서',
},
},
markdown: {
headers: {
level: [2, 3, 4, 5],
},
},
theme: Theme,
alias: {
"@theme-hope/modules/navbar/components/LanguageDropdown": path.resolve(
__dirname,
"./components/LanguageDropdown.ts",
),
},
plugins: [
googleAnalyticsPlugin({
id: "G-FJQDKG394Z",
}),
],
head: [
["link", { rel: "preconnect", href: "https://fonts.googleapis.com" }],
['link', { rel: 'preconnect', href: 'https://fonts.googleapis.com' }],
['link', { rel: 'preconnect', href: 'https://fonts.gstatic.com', crossorigin: '' }],
[
"link",
{ rel: "preconnect", href: "https://fonts.gstatic.com", crossorigin: "" },
],
[
"link",
'link',
{
href: "https://fonts.googleapis.com/css2?family=Noto+Sans+SC:wght@100..900&display=swap",
rel: "stylesheet",
href: 'https://fonts.googleapis.com/css2?family=Noto+Sans+SC:wght@100..900&display=swap',
rel: 'stylesheet',
},
],
[
"link",
'link',
{
href: "https://fonts.googleapis.com/css2?family=Noto+Serif+SC:wght@200..900&display=swap",
rel: "stylesheet",
href: 'https://fonts.googleapis.com/css2?family=Noto+Serif+SC:wght@200..900&display=swap',
rel: 'stylesheet',
},
],
[
"link",
'link',
{
href: "https://fonts.googleapis.com/css2?family=JetBrains+Mono:ital,wght@0,100..800;1,100..800&display=swap",
rel: "stylesheet",
href: 'https://fonts.googleapis.com/css2?family=JetBrains+Mono:ital,wght@0,100..800;1,100..800&display=swap',
rel: 'stylesheet',
},
],
],
@@ -90,4 +73,63 @@ export default defineUserConfig({
viteOptions: {},
vuePluginOptions: {},
}),
shouldPrefetch: false,
theme: plumeTheme({
hostname: 'https://docs.maa.plus',
docsRepo: 'MaaAssistantArknights/MaaAssistantArknights',
docsDir: '/docs',
docsBranch: 'dev',
editLink: true,
lastUpdated: false,
contributors: false,
changelog: false,
blog: false,
cache: 'filesystem',
search: DocSearchConfig,
codeHighlighter: {
themes: { light: 'one-light', dark: 'one-dark-pro' },
},
markdown: {
image: {
lazyload: true,
mark: true,
size: true,
},
icon: { provider: 'iconify' },
plot: true,
field: true,
bilibili: true,
},
watermark: false,
comment: {
provider: 'Giscus',
repo: 'MaaAssistantArknights/maa-website',
repoId: 'R_kgDOHY7Gyg',
category: 'Comments',
categoryId: 'DIC_kwDOHY7Gys4CgoVH',
mapping: 'pathname',
strict: false,
lazyLoading: true,
},
//replaceAssets: isProd ? "https://cdn.maa.plus" : false,
}),
plugins: [
googleAnalyticsPlugin({
id: 'G-FJQDKG394Z',
}),
],
});

5
docs/.vuepress/env.d.ts vendored Normal file
View File

@@ -0,0 +1,5 @@
declare module '*.vue' {
import { DefineComponent } from 'vue';
const component: DefineComponent<{}, {}, any>;
export default component;
}

View File

@@ -1,29 +1,19 @@
import { navbar } from "vuepress-theme-hope";
import { defineNavbarConfig } from 'vuepress-theme-plume';
export const enusNavbar = navbar([
export const enusNavbar = defineNavbarConfig([
{
text: "Home",
icon: "ic:round-home",
link: "/en-us/",
text: 'User Manual',
icon: 'mdi:user',
link: '/en-us/manual/newbie.html',
},
{
text: "User Manual",
icon: "mdi:user",
link: "/en-us/manual/",
text: 'Development Docs',
icon: 'ph:code-bold',
link: '/en-us/develop/development.html',
},
{
text: "Development Docs",
icon: "ph:code-bold",
link: "/en-us/develop/",
},
{
text: "Protocol Docs",
icon: "basil:document-solid",
link: "/en-us/protocol/",
},
{
text: "MAA Website",
icon: "mdi:cow",
link: "https://maa.plus",
text: 'Protocol Docs',
icon: 'basil:document-solid',
link: '/en-us/protocol/integration.html',
},
]);

View File

@@ -1,5 +1,5 @@
export * from "./zh-cn";
export * from "./zh-tw";
export * from "./en-us";
export * from "./ja-jp";
export * from "./ko-kr";
export * from './zh-cn';
export * from './zh-tw';
export * from './en-us';
export * from './ja-jp';
export * from './ko-kr';

View File

@@ -1,29 +1,19 @@
import { navbar } from "vuepress-theme-hope";
import { defineNavbarConfig } from 'vuepress-theme-plume';
export const jajpNavbar = navbar([
export const jajpNavbar = defineNavbarConfig([
{
text: "ホームページ",
icon: "ic:round-home",
link: "/ja-jp/",
text: '使用説明',
icon: 'mdi:user',
link: '/ja-jp/manual/newbie.html',
},
{
text: "使用説明",
icon: "mdi:user",
link: "/ja-jp/manual/",
text: '開発関連',
icon: 'ph:code-bold',
link: '/ja-jp/develop/development.html',
},
{
text: "開発関連",
icon: "ph:code-bold",
link: "/ja-jp/develop/",
},
{
text: "プロトコルドキュメント",
icon: "basil:document-solid",
link: "/ja-jp/protocol/",
},
{
text: "MAA 公式サイト",
icon: "mdi:cow",
link: "https://maa.plus",
text: 'プロトコルドキュメント',
icon: 'basil:document-solid',
link: '/ja-jp/protocol/integration.html',
},
]);

View File

@@ -1,29 +1,19 @@
import { navbar } from "vuepress-theme-hope";
import { defineNavbarConfig } from 'vuepress-theme-plume';
export const kokrNavbar = navbar([
export const kokrNavbar = defineNavbarConfig([
{
text: "홈페이지",
icon: "ic:round-home",
link: "/ko-kr/",
text: '사용자 설명서',
icon: 'mdi:user',
link: '/ko-kr/manual/newbie.html',
},
{
text: "사용자 설명서",
icon: "mdi:user",
link: "/ko-kr/manual/",
text: '개발 문서',
icon: 'ph:code-bold',
link: '/ko-kr/develop/development.html',
},
{
text: "개발 문서",
icon: "ph:code-bold",
link: "/ko-kr/develop/",
},
{
text: "프로토콜 문서",
icon: "basil:document-solid",
link: "/ko-kr/protocol/",
},
{
text: "MAA 공식 홈페이지",
icon: "mdi:cow",
link: "https://maa.plus",
text: '프로토콜 문서',
icon: 'basil:document-solid',
link: '/ko-kr/protocol/integration.html',
},
]);

View File

@@ -1,29 +1,19 @@
import { navbar } from "vuepress-theme-hope";
import { defineNavbarConfig } from 'vuepress-theme-plume';
export const zhcnNavbar = navbar([
export const zhcnNavbar = defineNavbarConfig([
{
text: "主页",
icon: "ic:round-home",
link: "/zh-cn/",
text: '用户手册',
icon: 'mdi:user',
link: '/zh-cn/manual/newbie.html',
},
{
text: "用户手册",
icon: "mdi:user",
link: "/zh-cn/manual/",
text: '开发文档',
icon: 'ph:code-bold',
link: '/zh-cn/develop/development.html',
},
{
text: "开发文档",
icon: "ph:code-bold",
link: "/zh-cn/develop/",
},
{
text: "协议文档",
icon: "basil:document-solid",
link: "/zh-cn/protocol/",
},
{
text: "MAA 官网",
icon: "mdi:cow",
link: "https://maa.plus",
text: '协议文档',
icon: 'basil:document-solid',
link: '/zh-cn/protocol/integration.html',
},
]);

View File

@@ -1,29 +1,19 @@
import { navbar } from "vuepress-theme-hope";
import { defineNavbarConfig } from 'vuepress-theme-plume';
export const zhtwNavbar = navbar([
export const zhtwNavbar = defineNavbarConfig([
{
text: "首頁",
icon: "ic:round-home",
link: "/zh-tw/",
text: '用戶說明書',
icon: 'mdi:user',
link: '/zh-tw/manual/newbie.html',
},
{
text: "用戶說明書",
icon: "mdi:user",
link: "/zh-tw/manual/",
text: '開發文件',
icon: 'ph:code-bold',
link: '/zh-tw/develop/development.html',
},
{
text: "開發文件",
icon: "ph:code-bold",
link: "/zh-tw/develop/",
},
{
text: "協議文件",
icon: "basil:document-solid",
link: "/zh-tw/protocol/",
},
{
text: "MAA 官網",
icon: "mdi:cow",
link: "https://maa.plus",
text: '協議文件',
icon: 'basil:document-solid',
link: '/zh-tw/protocol/integration.html',
},
]);

View File

@@ -0,0 +1,8 @@
import { defineNotesConfig } from 'vuepress-theme-plume';
import { genNotes } from './genSidebar';
export const enusNotes = defineNotesConfig({
dir: 'en-us',
link: '/en-us/',
notes: genNotes('en-us'),
});

View File

@@ -0,0 +1,119 @@
import * as fs from 'fs';
import * as path from 'path';
import * as matterModule from 'gray-matter';
import { defineNoteConfig, ThemeNote, ThemeSidebarItem } from 'vuepress-theme-plume';
const matter = (matterModule as any).default;
interface MetaData {
baseName: string;
order: number;
title: string;
icon: string;
index: boolean;
}
function getMetaData(dir: string, entry: fs.Dirent): MetaData | null {
const currentPath = path.join(dir, entry.name);
if (!fs.existsSync(currentPath)) {
return null;
}
let mdFilePath = '';
if (entry.isDirectory()) {
mdFilePath = path.join(currentPath, 'README.md');
} else if (entry.isFile() && entry.name.endsWith('.md') && entry.name.toLowerCase() !== 'readme.md') {
mdFilePath = currentPath;
} else {
return null;
}
if (!fs.existsSync(mdFilePath)) {
return null;
}
const fileContent = fs.readFileSync(mdFilePath, 'utf-8');
const meta = matter(fileContent).data ?? {};
const baseName = path.parse(entry.name).name;
// 获取顺序目录的order在meta.dir.order里文件的order在meta.order里默认值为一个大数
const order = Number((entry.isDirectory() ? meta?.dir?.order : meta?.order) ?? Number.MAX_SAFE_INTEGER);
// 获取标题先从matter里找title再用正则获取一级标题最后fallback到文件名不含扩展名
const title = String(meta?.title ?? RegExp('# (.+)').exec(fileContent)?.[1] ?? baseName);
// 获取图标
const icon = String(meta?.icon ?? '');
// 是否作为索引页文件永远为true目录则看meta.index默认true
const index = entry.isDirectory() ? (Boolean(meta?.index) ?? true) : true;
return {
baseName: baseName,
order: order,
title: title,
icon: icon,
index: index,
};
}
export function genNotes(lang: string, baseDir = path.resolve(__dirname, '../../')): ThemeNote[] {
// 进入指定语言目录即docs/<i18n>/
const langDir = path.join(baseDir, lang);
// 递归获取目录和文件
function getItems(dir: string, isRoot: boolean): any[] {
// 将内容与对应顺序进行包装
interface Wrapped {
content: ThemeNote | ThemeSidebarItem | string;
order: number;
}
let itemsWithOrder: Wrapped[] = [];
// 获取所有非隐藏文件和目录
const entries = fs.readdirSync(dir, { withFileTypes: true }).filter((e) => !e.name.startsWith('.'));
for (const entry of entries) {
const metaData = getMetaData(dir, entry);
if (!metaData) {
continue;
}
if (entry.isDirectory()) {
// 递归获取子目录内容
const children = getItems(path.join(dir, entry.name), false);
if (isRoot) {
// 一级目录,作为“专题”
const item = defineNoteConfig({
dir: metaData.baseName,
link: `/${metaData.baseName}/`,
text: metaData.title,
sidebar: children,
});
itemsWithOrder.push({ content: item, order: metaData.order });
} else {
// 非一级目录,作为可折叠的子目录
const item: ThemeSidebarItem = {
text: metaData.title,
// 只有当目录设置了index: true时才生成链接否则点击时不跳转、只切换折叠状态
link: metaData.index ? `${metaData.baseName}/` : undefined,
icon: metaData.icon,
// 目前没有文档使用了这个特性,故不处理
// badge: undefined,
collapsed: true,
// 前面不能加斜杠,必须用相对路径
prefix: `${metaData.baseName}/`,
items: children,
};
itemsWithOrder.push({ content: item, order: metaData.order });
}
} else if (entry.isFile() && entry.name.endsWith('.md') && entry.name.toLowerCase() !== 'readme.md') {
// 普通文件,取完整文件名作为链接
const item = entry.name;
itemsWithOrder.push({ content: item, order: metaData.order });
}
}
// 当前dir的内容读取完毕进行排序并返回返回时丢弃order
itemsWithOrder.sort((a, b) => a.order - b.order);
return itemsWithOrder.map((i) => i.content);
}
// 递归起点只有这里是一级目录isRoot传true
return getItems(langDir, true);
}

View File

@@ -0,0 +1,5 @@
export * from './zh-cn';
export * from './zh-tw';
export * from './en-us';
export * from './ja-jp';
export * from './ko-kr';

View File

@@ -0,0 +1,8 @@
import { defineNotesConfig } from 'vuepress-theme-plume';
import { genNotes } from './genSidebar';
export const jajpNotes = defineNotesConfig({
dir: 'ja-jp',
link: '/ja-jp/',
notes: genNotes('ja-jp'),
});

View File

@@ -0,0 +1,8 @@
import { defineNotesConfig } from 'vuepress-theme-plume';
import { genNotes } from './genSidebar';
export const kokrNotes = defineNotesConfig({
dir: 'ko-kr',
link: '/ko-kr/',
notes: genNotes('ko-kr'),
});

View File

@@ -0,0 +1,8 @@
import { defineNotesConfig } from 'vuepress-theme-plume';
import { genNotes } from './genSidebar';
export const zhcnNotes = defineNotesConfig({
dir: 'zh-cn',
link: '/zh-cn/',
notes: genNotes('zh-cn'),
});

View File

@@ -0,0 +1,8 @@
import { defineNotesConfig } from 'vuepress-theme-plume';
import { genNotes } from './genSidebar';
export const zhtwNotes = defineNotesConfig({
dir: 'zh-tw',
link: '/zh-tw/',
notes: genNotes('zh-tw'),
});

View File

@@ -1,88 +1,84 @@
export default {
appId: "99JM20SIFG",
apiKey: "7596a5a8c95cd64d4cf3050c9a4f878e",
indexName: "maa",
// 这里应该把所有本地化配置都放入 locales 中
locales: {
"/zh-cn/": {
placeholder: "搜索",
translations: {
button: {
buttonText: "搜索",
},
modal: {
searchBox: {
resetButtonTitle: "清除查询条件",
cancelButtonText: "取消",
},
startScreen: {
recentSearchesTitle: "搜索历史",
noRecentSearchesText: "没有搜索历史",
saveRecentSearchButtonTitle: "保存至搜索历史",
removeRecentSearchButtonTitle: "从搜索历史中移除",
favoriteSearchesTitle: "收藏",
removeFavoriteSearchButtonTitle: "从收藏中移除",
},
errorScreen: {
titleText: "无法获取结果",
helpText: "你可能需要检查你的网络连接",
},
footer: {
selectText: "选择",
navigateText: "切换",
closeText: "关闭",
searchByText: "搜索提供者",
},
noResultsScreen: {
noResultsText: "无法找到相关结果",
suggestedQueryText: "你可以尝试查询",
reportMissingResultsText: "你认为该查询应该有结果?",
reportMissingResultsLinkText: "点击反馈",
},
},
},
provider: 'algolia' as const,
appId: '99JM20SIFG',
apiKey: '7596a5a8c95cd64d4cf3050c9a4f878e',
indexName: 'maa',
locales: {
'/zh-cn/': {
placeholder: '搜索',
translations: {
button: {
buttonText: '搜索',
},
"/en-us/": {
placeholder: "Search",
translations: {
button: {
buttonText: "Search",
},
modal: {
searchBox: {
resetButtonTitle: "Clear the query",
cancelButtonText: "Cancel",
},
startScreen: {
recentSearchesTitle: "Recent",
noRecentSearchesText: "No recent searches",
saveRecentSearchButtonTitle: "Save this search",
removeRecentSearchButtonTitle:
"Remove this search from history",
favoriteSearchesTitle: "Favorite",
removeFavoriteSearchButtonTitle:
"Remove this search from favorites",
},
errorScreen: {
titleText: "Unable to fetch results",
helpText:
"You might want to check your network connection.",
},
footer: {
selectText: "to select",
navigateText: "to navigate",
closeText: "to close",
searchByText: "Search by",
},
noResultsScreen: {
noResultsText: "No results for",
suggestedQueryText: "Try searching for",
reportMissingResultsText:
"Believe this query should return results?",
reportMissingResultsLinkText: "Let us know.",
},
},
},
modal: {
searchBox: {
resetButtonTitle: '清除查询条件',
cancelButtonText: '取消',
},
startScreen: {
recentSearchesTitle: '搜索历史',
noRecentSearchesText: '没有搜索历史',
saveRecentSearchButtonTitle: '保存至搜索历史',
removeRecentSearchButtonTitle: '从搜索历史中移除',
favoriteSearchesTitle: '收藏',
removeFavoriteSearchButtonTitle: '从收藏中移除',
},
errorScreen: {
titleText: '无法获取结果',
helpText: '你可能需要检查你的网络连接',
},
footer: {
selectText: '选择',
navigateText: '切换',
closeText: '关闭',
searchByText: '搜索提供者',
},
noResultsScreen: {
noResultsText: '无法找到相关结果',
suggestedQueryText: '你可以尝试查询',
reportMissingResultsText: '你认为该查询应该有结果?',
reportMissingResultsLinkText: '点击反馈',
},
},
},
},
'/en-us/': {
placeholder: 'Search',
translations: {
button: {
buttonText: 'Search',
},
modal: {
searchBox: {
resetButtonTitle: 'Clear the query',
cancelButtonText: 'Cancel',
},
startScreen: {
recentSearchesTitle: 'Recent',
noRecentSearchesText: 'No recent searches',
saveRecentSearchButtonTitle: 'Save this search',
removeRecentSearchButtonTitle: 'Remove this search from history',
favoriteSearchesTitle: 'Favorite',
removeFavoriteSearchButtonTitle: 'Remove this search from favorites',
},
errorScreen: {
titleText: 'Unable to fetch results',
helpText: 'You might want to check your network connection.',
},
footer: {
selectText: 'to select',
navigateText: 'to navigate',
closeText: 'to close',
searchByText: 'Search by',
},
noResultsScreen: {
noResultsText: 'No results for',
suggestedQueryText: 'Try searching for',
reportMissingResultsText: 'Believe this query should return results?',
reportMissingResultsLinkText: 'Let us know.',
},
},
},
},
},
};

View File

@@ -0,0 +1,129 @@
import { defineThemeConfig } from 'vuepress-theme-plume';
import { zhcnNavbar, zhtwNavbar, enusNavbar, jajpNavbar, kokrNavbar } from './navbar';
import { zhcnNotes, zhtwNotes, enusNotes, jajpNotes, kokrNotes } from './notes';
export default defineThemeConfig({
logo: '/images/maa-logo_512x512.png',
appearance: true,
social: [
{ icon: 'qq', link: 'https://api.maa.plus/MaaAssistantArknights/api/qqgroup' },
{ icon: 'discord', link: 'https://discord.gg/23DfZ9uA4V' },
{ icon: 'telegram', link: 'https://t.me/+Mgc2Zngr-hs3ZjU1' },
{ icon: 'bilibili', link: 'https://space.bilibili.com/3493274731940507/' },
{ icon: 'github', link: 'https://github.com/MaaAssistantArknights/MaaAssistantArknights/' },
],
navbarSocialInclude: ['qq', 'discord', 'telegram', 'bilibili', 'github'],
aside: true,
// outline: [2, 3, 4, 5],
copyright: false,
prevPage: false,
nextPage: false,
createTime: false,
footer: false,
locales: {
'/zh-cn/': {
navbar: zhcnNavbar,
notes: zhcnNotes,
},
'/zh-tw/': {
navbar: zhtwNavbar,
notes: zhtwNotes,
},
'/en-us/': {
navbar: enusNavbar,
notes: enusNotes,
},
'/ja-jp/': {
navbar: jajpNavbar,
notes: jajpNotes,
},
'/ko-kr/': {
navbar: kokrNavbar,
notes: kokrNotes,
},
},
autoFrontmatter: false,
//plugins: {
// notice: [
// {
// path: "/zh-tw/",
// title: "翻译警告",
// content: "MAA 的文檔以簡體中文為主,其他語言的文檔可能品質低或尚未翻譯,請諒解。",
// fullscreen: true,
// confirm: true,
// showOnce: true,
// actions: [
// {
// text: "我知道了",
// type: "primary",
// },
// {
// text: "前往簡體中文",
// link: "/zh-cn/",
// },
// ],
// },
// {
// path: "/en-us/",
// title: "Translation Warning",
// content: "MAA's documents are mainly in Simplified Chinese. Documents in other languages may be of low quality or not yet translated. Please understand.",
// fullscreen: true,
// confirm: true,
// showOnce: true,
// actions: [
// {
// text: "Okay",
// type: "primary",
// },
// {
// text: "Take me to zh-CN",
// link: "/zh-cn/",
// },
// ],
// },
// {
// path: "/ja-jp/",
// title: "翻訳に関する警告",
// content: "MAA のドキュメントは主に簡体字中国語で書かれており、他の言語のドキュメントは低品質であるか、翻訳されていない可能性がありますので、ご了承ください。",
// fullscreen: true,
// confirm: true,
// showOnce: true,
// actions: [
// {
// text: "OK",
// type: "primary",
// },
// {
// text: "中国語サイトへ行く",
// link: "/zh-cn/",
// },
// ],
// },
// {
// path: "/ko-kr/",
// title: "번역 경고",
// content: "MAA의 문서는 주로 중국어 간체로 되어 있습니다. 다른 언어로 된 문서는 번역이 이상하거나, 번역이 되어있지 않을 수 있습니다.",
// fullscreen: true,
// confirm: true,
// showOnce: true,
// actions: [
// {
// text: "OK",
// type: "primary",
// },
// {
// text: "중국어 간체로 이동",
// link: "/zh-cn/",
// },
// ],
// },
// ],
//},
});

View File

@@ -0,0 +1 @@
docs.maa.plus

View File

Before

Width:  |  Height:  |  Size: 15 KiB

After

Width:  |  Height:  |  Size: 15 KiB

View File

@@ -1,101 +0,0 @@
# This file MUST use GBK encoding, whatever the system language is.
# You may do more testing, but at least it works like this for me.
# Fuck Microsoft.
# 修改请使用 GBK 编码保存。
# 如果能用 UTF-8 保存而不乱码,那就去做,我实在是研究不明白微软的屎了。
# 你或许想加一条 [Console]::OutputEncoding = [System.Text.Encoding]::UTF8 来解决问题。
# 但很神奇的,这根本不管用,甚至还会让中文汉字渲染重叠在一起。
# 我在 CMD 里面都能 chcp 65001 换成 UTF-8。
# 微软什么时候能把 PowerShell 7 集成到系统里。
# 我由衷的认为 Windows 中预装的 PowerShell 就是一坨屎,甚至不如 CMD。
# 用 PowerShell 写这东西真成为了一盘醋包的饺子了。
# 检查 PowerShell 脚本运行策略
# 我真理解不了这个运行策略的存在意义了,明明叫脚本运行策略,却可以用脚本修改。
# 我既可以在不提权的情况下允许所有脚本运行,也可以直接启动一个运行所有脚本运行的会话。
# 本脚本在测试时发现,在不修改策略且不提权的情况下也可以正常运行,只是在安装运行库时需要点安装程序的 UAC 弹窗。
# 而不修改策略且提权时反而因为脚本策略运行不了了,这是什么品种的管理员权限。
# $ExecutionPolicy = Get-ExecutionPolicy
# if ($ExecutionPolicy -eq 'Restricted' -or $ExecutionPolicy -eq 'AllSigned') {
# Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser
# Write-Host "已修改当前用户的 PowerShell 脚本运行策略为 RemoteSigned 以便运行此脚本。"
# Write-Host "这只需运行一次,且理应不会产生较大的安全风险。"
# Write-Host "如果您对此有疑虑,请在脚本运行结束后,在 PowerShell 中运行以下命令将策略值清空。"
# Write-Host "Set-ExecutionPolicy -ExecutionPolicy Undefined -Scope CurrentUser"
# Pause
# }
# 获取 UAC 权限并启动一个 RemoteSigned 脚本策略会话
If (-Not ([Security.Principal.WindowsPrincipal] [Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole([Security.Principal.WindowsBuiltinRole]::Administrator)) {
Write-Host "正在获取管理员权限..."
Start-Process powershell.exe "-ExecutionPolicy RemoteSigned -File `"$PSCommandPath`" -ArgumentList `"$PSCommandPath`"" -Verb RunAs
Exit
}
# 读取系统代理并应用
$Internet_Settings = Get-ItemProperty -Path 'HKCU:\Software\Microsoft\Windows\CurrentVersion\Internet Settings'
if ($Internet_Settings.ProxyEnable -eq 1) {
$env:HTTP_PROXY = "http://$($Internet_Settings.ProxyServer)"
$env:HTTPS_PROXY = "http://$($Internet_Settings.ProxyServer)"
Write-Host "已应用系统代理:$($Internet_Settings.ProxyServer)"
}
# else {
# Write-Host "未启用系统代理。"
# }
Remove-Variable -Name Internet_Settings
# 新建下载用临时文件夹
New-Item -Path "$env:TEMP" -Name "MAA_Runtime_Fix_Pwsh" -ItemType "Directory" | Out-Null
# 使用 BITS 下载运行库安装包
Write-Host "正在下载运行库安装包..."
# Start-Sleep -Seconds 1
Start-BitsTransfer -Source "https://aka.ms/vs/17/release/vc_redist.x64.exe" -Destination "$env:TEMP\MAA_Runtime_Fix_Pwsh\vc_redist.x64.exe"
Start-BitsTransfer -Source "https://builds.dotnet.microsoft.com/dotnet/WindowsDesktop/8.0.11/windowsdesktop-runtime-8.0.11-win-x64.exe" -Destination "$env:TEMP\MAA_Runtime_Fix_Pwsh\windowsdesktop-runtime-8.0.11-win-x64.exe"
# 卸载 vc++ 和 dotnet8
Write-Host ""
Write-Host "尝试调用 WinGet 卸载已安装的运行库..."
winget uninstall "Microsoft.VCRedist.2015+.x64" "Microsoft.DotNet.DesktopRuntime.8" --force --all-versions
# 安装 vc++
Write-Host ""
Write-Host "正在安装/修复 Microsoft Visual C++ 可再发行程序包..."
$vcProcess = Start-Process "$env:TEMP\MAA_Runtime_Fix_Pwsh\vc_redist.x64.exe" -ArgumentList '/repair', '/passive', '/norestart' -PassThru
$vcProcess.WaitForExit()
# 安装 dotnet8
Write-Host "正在安装/修复 .NET 桌面运行时 8..."
$dotnetProcess = Start-Process "$env:TEMP\MAA_Runtime_Fix_Pwsh\windowsdesktop-runtime-8.0.11-win-x64.exe" -ArgumentList '/repair', '/passive', '/norestart' -PassThru
$dotnetProcess.WaitForExit()
# 删除临时文件夹
Write-Host ""
Write-Host "正在清理临时文件..."
Remove-Item -Path "$env:TEMP\MAA_Runtime_Fix_Pwsh" -Recurse -Force
Write-Host "运行库修复完成,请再次尝试运行 MAA。"
Write-Host ""
Pause
# 使用 winget 安装/更新运行库并卸载旧版本
# winget install "Microsoft.VCRedist.2015+.x64" "Microsoft.DotNet.DesktopRuntime.8" --uninstall-previous --accept-package-agreements
# 使用 winget 下载运行库安装包
# winget download --id "Microsoft.VCRedist.2015+.x64" -d "$env:TEMP\MAA_Runtime_Fix_Pwsh\"
# winget download --id "Microsoft.DotNet.DesktopRuntime.8" -d "$env:TEMP\MAA_Runtime_Fix_Pwsh\"
# 不使用 winget 卸载 vc++
# 会进行卸载 但是卸不掉
# Get-Package -Name "Microsoft Visual C++ 2015-2022 Redistributable (x64) - *" | Uninstall-Package -Force
# 不使用 winget 卸载 dotnet8
# 会进行卸载 但是卸不掉
# Get-Package -Name "Microsoft Windows Desktop Runtime - 8.* (x64)" | Uninstall-Package -Force
# 下载安装包那里注释了一个睡一秒是因为本来下载文件的那个进度条会把上面输出过的所有内容都覆盖掉,上来就只能看到个下载进度条,别的啥也看不到。
# 但当我去掉新建文件夹时输出的一大坨东西之后,这行就能露出来了。
# 我建议每个人都去看一下 PowerShell 的 New-Item 新建文件夹能输出多大一坨玩意。
# 还有 PowerShell 弱智一样的进度条显示机制,非得搞个固定不透明一大坨的浮窗上去干什么,就不能和别人一样在命令底部显示吗。
# 再用 Pwsh 写脚本我就是傻逼。

Binary file not shown.

Before

Width:  |  Height:  |  Size: 266 KiB

After

Width:  |  Height:  |  Size: 70 KiB

View File

@@ -0,0 +1,4 @@
<svg width="24" height="24" viewBox="0 0 32 32" xmlns="http://www.w3.org/2000/svg" fill="currentColor">
<text x="16" y="31" font-size="12" text-anchor="middle" font-family="monospace">maa</text>
<path transform="translate(4, 0)" fill-rule="evenodd" clip-rule="evenodd" d="M19.85 8.75l4.15.83v4.84l-4.15.83 2.35 3.52-3.43 3.43-3.52-2.35-.83 4.15H9.58l-.83-4.15-3.52 2.35-3.43-3.43 2.35-3.52L0 14.42V9.58l4.15-.83L1.8 5.23 5.23 1.8l3.52 2.35L9.58 0h4.84l.83 4.15 3.52-2.35 3.43 3.43-2.35 3.52zm-1.57 5.07l4-.81v-2l-4-.81-.54-1.3 2.29-3.43-1.43-1.43-3.43 2.29-1.3-.54-.81-4h-2l-.81 4-1.3.54-3.43-2.29-1.43 1.43L6.38 8.9l-.54 1.3-4 .81v2l4 .81.54 1.3-2.29 3.43 1.43 1.43 3.43-2.29 1.3.54.81 4h2l.81-4 1.3-.54 3.43 2.29 1.43-1.43-2.29-3.43.54-1.3zm-8.186-4.672A3.43 3.43 0 0 1 12 8.57 3.44 3.44 0 0 1 15.43 12a3.43 3.43 0 1 1-5.336-2.852zm.956 4.274c.281.188.612.288.95.288A1.7 1.7 0 0 0 13.71 12a1.71 1.71 0 1 0-2.66 1.422z"/>
</svg>

After

Width:  |  Height:  |  Size: 934 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 40 KiB

View File

@@ -1,32 +0,0 @@
import { sidebar } from "vuepress-theme-hope";
export const enusSidebar = sidebar({
"/en-us/": [
{
text: "MAA",
icon: "ic:round-home",
link: "/en-us/",
},
{
text: "User Manual",
icon: "mdi:user",
prefix: "manual/",
collapsible: true,
children: "structure",
},
{
text: "Development Docs",
icon: "ph:code-bold",
prefix: "develop/",
collapsible: true,
children: "structure",
},
{
text: "Protocol Docs",
icon: "basil:document-solid",
prefix: "protocol/",
collapsible: true,
children: "structure",
},
],
});

View File

@@ -1,5 +0,0 @@
export * from "./zh-cn";
export * from "./zh-tw";
export * from "./en-us";
export * from "./ja-jp";
export * from "./ko-kr";

View File

@@ -1,32 +0,0 @@
import { sidebar } from "vuepress-theme-hope";
export const jajpSidebar = sidebar({
"/ja-jp/": [
{
text: "MAA",
icon: "ic:round-home",
link: "/ja-jp/",
},
{
text: "使用説明",
icon: "mdi:user",
prefix: "manual/",
collapsible: true,
children: "structure",
},
{
text: "開発関連",
icon: "ph:code-bold",
prefix: "develop/",
collapsible: true,
children: "structure",
},
{
text: "プロトコルドキュメント",
icon: "basil:document-solid",
prefix: "protocol/",
collapsible: true,
children: "structure",
},
],
});

View File

@@ -1,32 +0,0 @@
import { sidebar } from "vuepress-theme-hope";
export const kokrSidebar = sidebar({
"/ko-kr/": [
{
text: "MAA",
icon: "ic:round-home",
link: "/ko-kr/",
},
{
text: "사용자 설명서",
icon: "mdi:user",
prefix: "manual/",
collapsible: true,
children: "structure",
},
{
text: "개발 관련",
icon: "ph:code-bold",
prefix: "develop/",
collapsible: true,
children: "structure",
},
{
text: "프로토콜 문서",
icon: "basil:document-solid",
prefix: "protocol/",
collapsible: true,
children: "structure",
},
],
});

View File

@@ -1,32 +0,0 @@
import { sidebar } from "vuepress-theme-hope";
export const zhcnSidebar = sidebar({
"/zh-cn/": [
{
text: "MAA",
icon: "ic:round-home",
link: "/zh-cn/",
},
{
text: "用户手册",
icon: "mdi:user",
prefix: "manual/",
collapsible: true,
children: "structure",
},
{
text: "开发文档",
icon: "ph:code-bold",
prefix: "develop/",
collapsible: true,
children: "structure",
},
{
text: "协议文档",
icon: "basil:document-solid",
prefix: "protocol/",
collapsible: true,
children: "structure",
},
],
});

View File

@@ -1,32 +0,0 @@
import { sidebar } from "vuepress-theme-hope";
export const zhtwSidebar = sidebar({
"/zh-tw/": [
{
text: "MAA",
icon: "ic:round-home",
link: "/zh-tw/",
},
{
text: "用戶說明書",
icon: "mdi:user",
prefix: "manual/",
collapsible: true,
children: "structure",
},
{
text: "開發文件",
icon: "ph:code-bold",
prefix: "develop/",
collapsible: true,
children: "structure",
},
{
text: "協議文件",
icon: "basil:document-solid",
prefix: "protocol/",
collapsible: true,
children: "structure",
},
],
});

View File

@@ -1 +0,0 @@
$theme-colors: #2196f3, #f26d6d, #3eaf7c, #fb9b5f;

View File

@@ -0,0 +1,16 @@
:root {
--vp-font-family-base:
-apple-system, BlinkMacSystemFont, "Noto Sans SC", "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Fira Sans",
"Droid Sans", "Helvetica Neue", STHeiti, "Microsoft YaHei", sans-serif;
--vp-font-family-heading:
Georgia, -apple-system, "Nimbus Roman No9 L", "PingFang SC", "Hiragino Sans GB", "Noto Serif SC", "Microsoft Yahei",
"WenQuanYi Micro Hei", "ST Heiti", sans-serif;
--vp-font-family-mono:
"Maple Mono NF CN", "JetBrains Mono", "Fira Code", "Noto Sans SC", Consolas, monospace, Menlo, "Courier New";
}
html[lang="ja-JP"] {
--vp-font-family-base: "Helvetica Neue", Arial, "Hiragino Kaku Gothic ProN", "Hiragino Sans", Meiryo, sans-serif;
}

View File

@@ -0,0 +1,40 @@
:root {
--vp-home-hero-name: var(--vp-c-text-1);
--vp-home-hero-text: var(--vp-c-text-2);
--vp-home-hero-tagline: var(--vp-c-text-3);
--vp-home-hero-name-color: transparent;
--vp-home-hero-name-background: linear-gradient(350deg, var(--vp-c-yellow-1) 10%, var(--vp-c-red-2));
--vp-home-hero-image-background-image: linear-gradient(-45deg, var(--vp-c-yellow-1) 50%, var(--vp-c-yellow-1) 50%);
--vp-home-hero-image-filter: blur(50px);
--vp-home-hero-name-font-size: 4rem;
--vp-home-hero-name-line-height: 1.1;
@media (min-width: 640px) {
--vp-home-hero-name-font-size: 5rem;
}
@media (min-width: 960px) {
--vp-home-hero-name-font-size: 6rem;
}
}
.vp-home-doc-hero {
min-height: 100vh;
display: flex;
align-items: center;
justify-content: center;
.container {
margin: 0 auto;
display: flex;
align-items: center;
width: 100%;
max-width: 1152px;
}
.name {
font-size: var(--vp-home-hero-name-font-size) !important;
line-height: var(--vp-home-hero-name-line-height) !important;
}
}

View File

@@ -0,0 +1,22 @@
@use "home.scss";
@use "fonts.scss";
/* 按钮组容器 */
.actions .action {
display: flex;
flex-wrap: wrap;
justify-content: center;
max-width: 100%;
padding: 0;
}
/* 按钮 */
.actions .action .vp-button {
margin: 0.5rem;
min-width: 7em;
}
/* 首页标题 */
.is-home .name.clip {
text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
}

View File

@@ -1,20 +0,0 @@
$sidebar-width: 16rem;
$content-width: 1000px;
$vp-font: '-apple-system, BlinkMacSystemFont, "Noto Sans SC", "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Fira Sans", "Droid Sans", "Helvetica Neue", STHeiti, "Microsoft YaHei", sans-serif';
$vp-font-heading: 'Georgia, -apple-system, "Nimbus Roman No9 L", "PingFang SC", "Hiragino Sans GB", "Noto Serif SC", "Microsoft Yahei", "WenQuanYi Micro Hei", "ST Heiti", sans-serif';
$vp-font-mono: '"Sarasa Gothic", "Jetbrains mono", "Fira Code", "Noto Sans SC", Consolas, monospace, Menlo, "Courier New"';
.vp-hero-slide-down-button {
display: none !important;
visibility: hidden !important;
}
.vp-skip-link.sr-only {
display: none !important;
visibility: hidden !important;
}
html[lang="ja-JP"] {
$vp-font: "Helvetica Neue, Arial, Hiragino Kaku Gothic ProN, Hiragino Sans, Meiryo, sans-serif";
}

View File

@@ -1,185 +0,0 @@
import { hopeTheme } from "vuepress-theme-hope";
import DocSearchConfig from './plugins/search';
import { zhcnNavbar, zhtwNavbar, enusNavbar, jajpNavbar, kokrNavbar } from "./navbar/index";
import { zhcnSidebar, zhtwSidebar, enusSidebar, jajpSidebar, kokrSidebar } from "./sidebar/index";
export default hopeTheme({
hostname: "https://maa.plus",
author: "MaaAssistantArknights",
license: "AGPL-3.0",
repo: "MaaAssistantArknights/MaaAssistantArknights",
docsBranch: "dev",
docsDir: "/docs",
lastUpdated: false,
contributors: false,
locales: {
"/zh-cn/": {
navbar: zhcnNavbar,
sidebar: zhcnSidebar,
displayFooter: false,
metaLocales: {
editLink: "在 Github 上编辑此页面",
},
},
"/zh-tw/": {
navbar: zhtwNavbar,
sidebar: zhtwSidebar,
displayFooter: false,
title: '繁体中文',
metaLocales: {
editLink: "在 Github 上編輯此頁面",
},
},
"/en-us/": {
navbar: enusNavbar,
sidebar: enusSidebar,
displayFooter: false,
metaLocales: {
editLink: "Edit this page on Github",
},
},
"/ja-jp/": {
navbar: jajpNavbar,
sidebar: jajpSidebar,
displayFooter: false,
metaLocales: {
editLink: "このページを Github で編集する",
},
},
"/ko-kr/": {
navbar: kokrNavbar,
sidebar: kokrSidebar,
displayFooter: false,
metaLocales: {
editLink: "Github 에서 이 페이지를 편집",
},
},
},
markdown: {
align: true,
codeTabs: true,
//echarts: true,
footnote: true,
gfm: true,
hint: true,
imgLazyload: true,
imgMark: true,
imgSize: true,
//mathjax: true,
mark: true,
//mermaid: true,
tabs: true,
tasklist: true,
vPre: true,
component: true,
highlighter: {
'type': 'shiki',
themes: {
light: "light-plus",
dark: "nord",
}
},
},
plugins: {
activeHeaderLinks: false,
comment: {
provider: "Giscus",
repo: "MaaAssistantArknights/maa-website",
repoId: "R_kgDOHY7Gyg",
category: "Comments",
categoryId: "DIC_kwDOHY7Gys4CgoVH",
mapping: "pathname",
strict: true,
},
docsearch: DocSearchConfig,
icon: {
assets: "iconify",
},
sitemap: true,
seo: true,
notice: [
{
path: "/zh-tw/",
title: "翻译警告",
content: "MAA 的文檔以簡體中文為主,其他語言的文檔可能品質低或尚未翻譯,請諒解。",
fullscreen: true,
confirm: true,
showOnce: true,
actions: [
{
text: "我知道了",
type: "primary",
},
{
text: "前往簡體中文",
link: "/zh-cn/",
},
],
},
{
path: "/en-us/",
title: "Translation Warning",
content: "MAA's documents are mainly in Simplified Chinese. Documents in other languages may be of low quality or not yet translated. Please understand.",
fullscreen: true,
confirm: true,
showOnce: true,
actions: [
{
text: "Okay",
type: "primary",
},
{
text: "Take me to zh-CN",
link: "/zh-cn/",
},
],
},
{
path: "/ja-jp/",
title: "翻訳に関する警告",
content: "MAA のドキュメントは主に簡体字中国語で書かれており、他の言語のドキュメントは低品質であるか、翻訳されていない可能性がありますので、ご了承ください。",
fullscreen: true,
confirm: true,
showOnce: true,
actions: [
{
text: "OK",
type: "primary",
},
{
text: "中国語サイトへ行く",
link: "/zh-cn/",
},
],
},
{
path: "/ko-kr/",
title: "번역 경고",
content: "MAA의 문서는 주로 중국어 간체로 되어 있습니다. 다른 언어로 된 문서는 번역이 이상하거나, 번역이 되어있지 않을 수 있습니다.",
fullscreen: true,
confirm: true,
showOnce: true,
actions: [
{
text: "OK",
type: "primary",
},
{
text: "중국어 간체로 이동",
link: "/zh-cn/",
},
],
},
],
},
}, { custom: true });

27
docs/README.md Normal file
View File

@@ -0,0 +1,27 @@
---
pageLayout: home
title: 首页
config:
- type: doc-hero
hero:
name: MAA
text: 文档站 | Documentation
tagline: 选择语言 | Select Language
image: /images/maa-logo_512x512.png
actions:
- theme: brand
text: 简体中文
link: /zh-cn/
- theme: alt
text: 繁體中文
link: /zh-tw/
- theme: alt
text: English
link: /en-us/
- theme: alt
text: 日本語
link: /ja-jp/
- theme: alt
text: 한국어
link: /ko-kr/
---

View File

@@ -1,41 +0,0 @@
<template>
<div>
<img v-for="src of displayImageList" class="image" :src="src" alt="" />
</div>
</template>
<script lang="ts">
import { PropType, defineComponent } from "vue";
import { withBase } from "vuepress/client";
export default defineComponent({
props: {
imageList: Array as PropType<
Array<{ light: string; dark: string } | string>
>,
},
computed: {
displayImageList() {
return this.imageList.map((item) => {
const src =
typeof item === "string"
? item
: this.$isDarkmode
? item.dark
: item.light;
return withBase(src);
});
},
},
});
</script>
<style scoped>
.image {
box-sizing: border-box;
width: auto;
padding: 9px;
border-radius: 16px;
}
</style>

View File

@@ -1,47 +0,0 @@
<template>
<div>
<img v-for="src of displayImageList" class="image" :src="src" alt="" />
</div>
</template>
<script lang="ts">
import { PropType, defineComponent } from "vue";
import { withBase } from "vuepress/client";
export default defineComponent({
props: {
imageList: Array as PropType<
Array<{ light: string; dark: string } | string>
>,
},
computed: {
displayImageList() {
return this.imageList.map((item) => {
const src =
typeof item === "string"
? item
: this.$isDarkmode
? item.dark
: item.light;
return withBase(src);
});
},
},
});
</script>
<style scoped>
.image {
box-sizing: border-box;
width: 50%;
padding: 9px;
border-radius: 16px;
}
@media (max-width: 419px) {
.image {
width: auto;
}
}
</style>

View File

@@ -1,52 +0,0 @@
<template>
<div>
<img v-for="src of displayImageList" class="image" :src="src" alt="" />
</div>
</template>
<script lang="ts">
import { PropType, defineComponent } from "vue";
import { withBase } from "vuepress/client";
export default defineComponent({
props: {
imageList: Array as PropType<
Array<{ light: string; dark: string } | string>
>,
},
computed: {
displayImageList() {
return this.imageList.map((item) => {
const src =
typeof item === "string"
? item
: this.$isDarkmode
? item.dark
: item.light;
return withBase(src);
});
},
},
});
</script>
<style scoped>
.image {
box-sizing: border-box;
width: 25%;
padding: 9px;
border-radius: 16px;
}
@media (max-width: 719px) {
.image {
width: 50%;
}
}
@media (max-width: 419px) {
.image {
width: auto;
}
}
</style>

View File

@@ -9,12 +9,12 @@ icon: jam:write-f
The purpose of this document is to guide document writers to better utilize the functionalities provided by the theme, thus achieving a more readable effect.
:::
Our documentation is built on [vuepress](https://github.com/vuejs/vuepress) and utilizes the [vuepress-theme-hope](https://github.com/vuepress-theme-hope/vuepress-theme-hope) theme. You can also refer to the [official documentation](https://theme-hope.vuejs.press/) for more detailed explanations. Here, we only introduce some common functionalities.
Our documentation is built on [vuepress](https://github.com/vuejs/vuepress) and utilizes the [vuepress-theme-plume](https://github.com/pengzhanbo/vuepress-theme-plume) theme. You can also refer to the [official documentation](https://theme-plume.vuejs.press/) for more detailed explanations. Here, we only introduce some common functionalities.
## Deploy Locally
1. Install [Pnpm](https://pnpm.io/installation), and clone the repository refer to [Introduction to GitHub Pull request Flow](./development.md#introduction-to-github-pull-request-flow).
2. Create a terminal in the `website` directory, then run `pnpm i` to download dependencies.
2. Create a terminal in the `docs` directory, then run `pnpm i` to download dependencies.
3. Run `pnpm run dev` to deploy.
## Containers

View File

@@ -22,9 +22,6 @@ Mac can use the `tools/build_macos_universal.zsh` script for compilation. It's r
- Ubuntu/Debian
```bash
wget https://apt.llvm.org/llvm.sh
chmod +x llvm.sh
sudo ./llvm.sh 20
sudo apt install cmake
```
@@ -32,8 +29,6 @@ Mac can use the `tools/build_macos_universal.zsh` script for compilation. It's r
```bash
sudo pacman -S --needed cmake
# also, llvm 20 is needed.
# clang-20, clang++-20 are required to be found in PATH
```
2. Build third-party libraries
@@ -48,7 +43,6 @@ Mac can use the `tools/build_macos_universal.zsh` script for compilation. It's r
```bash
python tools/maadeps-download.py
python tools/linux-toolchain-download.py
```
If you find the libraries downloaded above cannot run on your system due to ABI version issues and you don't want to use container solutions, you can also try compiling from scratch
@@ -58,8 +52,8 @@ Mac can use the `tools/build_macos_universal.zsh` script for compilation. It's r
```bash
git clone https://github.com/MaaAssistantArknights/MaaDeps
cd MaaDeps
# If the system is too old to install llvm 20, please consider using local build enviroment instead of cross compiling.
# The toolchain config under MaaDeps/vcpkg-overlay/triplet needs to be modified.
# If the system is too old to use our prebuilt llvm 20, please consider using local build enviroment instead of cross compiling.
# The toolchain config under MaaDeps/cmake needs to be modified.
python linux-toolchain-download.py
python build.py
```
@@ -70,7 +64,7 @@ Mac can use the `tools/build_macos_universal.zsh` script for compilation. It's r
cmake -B build \
-DINSTALL_RESOURCE=ON \
-DINSTALL_PYTHON=ON \
-DCMAKE_TOOLCHAIN_FILE=cmake/linux/maa-x64-linux-toolchain.cmake
-DCMAKE_TOOLCHAIN_FILE=MaaDeps/cmake/maa-x64-linux-toolchain.cmake
cmake --build build
```

View File

@@ -22,16 +22,12 @@ Abbreviated as "repo", the place where we store our code and other resource file
👇 You can simply understand this webpage and all its contents as MAA's repository (we generally call it MAA's main repository)
```component Image1
{
"imageList": [
{
"light": "images/zh-cn/pr-tutorial/repository-light.png",
"dark": "images/zh-cn/pr-tutorial/repository-dark.png"
}
]
}
```
<ImageGrid :imageList="[
{
light: 'images/zh-cn/pr-tutorial/repository-light.png',
dark: 'images/zh-cn/pr-tutorial/repository-dark.png'
}
]" />
### Fork
@@ -42,16 +38,12 @@ Since it's a copy, it becomes `MAA (1)` (just kidding)
To distinguish from the original repository, we generally call the original MAA repository the "main repository" or "upstream repository."
Since everyone can fork their own copy, the copied version is called a "personal repository" or "origin repository."
```component Image1
{
"imageList": [
{
"light": "images/zh-cn/pr-tutorial/fork-light.png",
"dark": "images/zh-cn/pr-tutorial/fork-dark.png"
}
]
}
```
<ImageGrid :imageList="[
{
light: 'images/zh-cn/pr-tutorial/fork-light.png',
dark: 'images/zh-cn/pr-tutorial/fork-dark.png'
}
]" />
### Pull Request
@@ -62,16 +54,12 @@ Of course, since it's a "request," it naturally needs approval. MAA Team members
👇 Below are PRs currently submitted by contributors, waiting for approval
```component Image1
{
"imageList": [
{
"light": "images/zh-cn/pr-tutorial/pull-request-light.png",
"dark": "images/zh-cn/pr-tutorial/pull-request-dark.png"
}
]
}
```
<ImageGrid :imageList="[
{
light: 'images/zh-cn/pr-tutorial/pull-request-light.png',
dark: 'images/zh-cn/pr-tutorial/pull-request-dark.png'
}
]" />
### Conflict
@@ -84,29 +72,21 @@ Conflicts are somewhat troublesome to resolve. This section only explains the co
1. First, enter MAA's main repository and click the Fork button in the upper right corner to fork a copy of the code
```component Image1
{
"imageList": [
{
"light": "images/zh-cn/pr-tutorial/fork-light.png",
"dark": "images/zh-cn/pr-tutorial/fork-dark.png"
}
]
}
```
<ImageGrid :imageList="[
{
light: 'images/zh-cn/pr-tutorial/fork-light.png',
dark: 'images/zh-cn/pr-tutorial/fork-dark.png'
}
]" />
2. Then directly click "Create Fork"
```component Image1
{
"imageList": [
{
"light": "images/zh-cn/pr-tutorial/pr-2-light.png",
"dark": "images/zh-cn/pr-tutorial/pr-2-dark.png"
}
]
}
```
<ImageGrid :imageList="[
{
light: 'images/zh-cn/pr-tutorial/pr-2-light.png',
dark: 'images/zh-cn/pr-tutorial/pr-2-dark.png'
}
]" />
3. You'll arrive at your personal repository. You can see the title is "YourName/MaaAssistantArknights" with small text below saying "forked from MaaAssistantArknights/MaaAssistantArknights"

View File

@@ -0,0 +1,104 @@
---
order: 8
icon: iconoir:code-brackets
---
# Dedicated VSCode Extension Tutorial
* [Extension Store](https://marketplace.visualstudio.com/items?itemName=nekosu.maa-support)
* [Repository](https://github.com/neko-para/maa-support-extension)
## Installation
Searching `Maa` and installing it from VSCode extensions list is recommended.
## Features
### Control Panel
A dedicated control panel is added to the left, with icon ![MaaSupport ControlPanel](/images/maa-support-panel.svg)
The major features of the extension are based on the `interface.json` configuration. Select the activated `interface.json` on the top of the control panel.
The extension has a `Maa` compatiable mode. If `src/MaaCore` folder exists inside the opened workspace, the mode will be enabled automatically.
### Semantic resource analysis
Select expected resource via the `Resource` select inside the control panel. The extension will index and diagnose resource via corresponding paths.
If you find that the editing json isn't hinted by the extension, please check if the activated resource contains it.
> The term `definitions of task / task defs` refers to key props of task objects.
>
> The term `references of task / task refs` refers to values containing task name (e.g. in `next`) in other task objects.
#### Query task defs / task refs
The extension supports Jump to task defs, Jump to task refs and View task defs.
When enabling the `Maa` compatible mode, the extension will be able to parse `template task`, supporting querying task defs and task refs in conjunction with base tasks. Images that has the same name of the task will be shown when hovering the task defs.
#### Query / open images
The extension supports open images.
When enabling the `Maa` compatible mode, the extension will be able to recursively search for the image.
#### Task completion
The extension supports autocompletion according to all known tasks.
When enabling the `Maa` compatible mode, typing `@` will trigger completion.
#### Image path completion
The extension supports autocompletion according to the path of all known images.
When enabling the `Maa` compatible mode, the extension will be able to recursively search for the image.
#### Check tasks / image paths
The extension supports scheduled scanning and diagnosing all tasks.
* Check if contains task defs with same names.
* Check if contains unknown task refs.
* Check if contains unknown image refs.
* Check if contains duplicated task refs in a single task.
#### Multiple paths resource support
The extension supports resource with multiple paths. The extension will perform logical overlapping according to specified order, thus content loaded later can reference content loaded earlier.
### Evaluate Task / Tsak List Expression (Only Maa)
Evaluating the expanded task object and the sources of each properties, and the result of the task list expression via the control panel.
### MaaPiCli feature (Only MaaFramework projects)
Scanning and selecting controllers, selecting resource, adding and manipulating tasks, and launching tasks can be done via the control panel.
### Take screenshots and crop images
Searching and launching `Maa: open crop tool` inside VSCode command panel can open `Screenshots / Crop` panel.
> Use `Ctrl+Shift+P` (`Command+Shift+P` on MacOS) to open command panel
* After selecting and connecting to the controller, use `Screencap` button to obtain screenshots
* Use `Upload` button to manually upload images.
* Hold `Ctrl` key and select cropping area
* Use wheels to zoom
* After finishing cropping, use `Download` button to save the cropping result to the folder of the topest layer of the activated resource
### Bottom status bar
#### MaaSupport \[Extension Version\]
Click to reveal control panel
#### MaaFramework \[MaaFw Version\]
Click to switch `MaaFramework` version used by the extension
> When used for the first time, the preset version will be downloaded.
>
> Search command `Maa: select fetch registry` to switch downloading source (npm / cnpm).

View File

@@ -1,7 +1,7 @@
---
title: CLI Manual
icon: material-symbols:terminal
index: false
index: true
dir:
order: 6
---

View File

@@ -1,5 +1,5 @@
---
order: 4
order: 2
icon: ph:question-fill
---

View File

@@ -135,6 +135,8 @@ MAA now attempts to read the `bluestacks.conf` storage location from the registr
- International version default: `C:\ProgramData\BlueStacks_nxt\bluestacks.conf`
- Chinese version default: `C:\ProgramData\BlueStacks_nxt_cn\bluestacks.conf`
Note: `C:\ProgramData` is a hidden directory. If necessary, paste this address directly into the file explorer's address bar to access it.
2. If this is your first time, run MAA once so it automatically generates the configuration file.
3. **First close** MAA, **then** open `gui.json`, find your current configuration name under `Configurations` (viewable in Settings-Switch Configuration, default is `Default`), search for the `Bluestacks.Config.Path` field, and enter the full path to `bluestacks.conf`. (Note: use escaped backslashes `\\`)

View File

@@ -1,5 +1,5 @@
---
order: 4
order: 2
icon: ph:question-fill
---

View File

@@ -3,7 +3,7 @@ title: Introduction
icon: mdi:information-outline
index: false
dir:
order: 2
order: 4
---
<Catalog base='/en-us/manual/introduction/' />

View File

@@ -21,25 +21,25 @@ All features involving automatic combat require a stable game frame rate of at l
## Recommended Starts
::: details _Last updated 2025/8/2_
::: details _Last updated on 2025/8/30_
| Theme | Difficulty | Squad | Strategy | Operator |
| ------- | ----------------- | --------------------------------------- | ------------------------- | --------- |
| Phantom | Formal Investigation·3~7 | Leader Squad / Tactical Assault Squad | Overcoming Your Weaknesses | Thorns |
| Mizuki | Surging Waves·3~7 | People-Oriented Squad / Mind Over Matter Squad | Slow and Steady Wins the Race | Wiš'adel |
| Sami | Braving Nature·4~10 | Special Training Squad / Tactical Ranged Squad | Slow and Steady Wins the Race | Wiš'adel |
| Sarkaz | Face the Spirit·4~10 | Blueprint Mapping Squad / Tactical Ranged Squad | Slow and Steady Wins the Race | Wiš'adel |
| Garden | Enter the Garden·3~10 | Leader Squad / Tactical Ranged Squad | Slow and Steady Wins the Race | Wiš'adel |
| Theme | Difficulty | Squad | Strategy | Operator |
| ------- | ---------------------- | ----------------------------------------------- | ----------------------------- | -------- |
| Phantom | Formal Investigation·2 | Leader Squad / Tactical Assault Squad | Overcoming Your Weaknesses | Thorns |
| Mizuki | Surging Waves·3~7 | People-Oriented Squad / Mind Over Matter Squad | Slow and Steady Wins the Race | Wiš'adel |
| Sami | Braving Nature·4~10 | Special Training Squad / Tactical Ranged Squad | Slow and Steady Wins the Race | Wiš'adel |
| Sarkaz | Facing Souls·4~10 | Blueprint Mapping Squad / Tactical Ranged Squad | Slow and Steady Wins the Race | Wiš'adel |
| Garden | Enter the Garden·3~10 | Leader Squad / Tactical Ranged Squad | Slow and Steady Wins the Race | Wiš'adel |
The recommended difficulties consider factors like `enemy difficulty`, `hope consumption`, and `score multiplier`, and have been tested to be stable with high-level operators. Feel free to adjust based on your situation and needs.
| Theme | Notes |
| ------- | ----- |
| Phantom | `Formal Investigation·4` and higher difficulties may give hope-reducing collectibles at start, preventing recruitment of six-star operators. |
| Mizuki | `Surging Waves·4` and higher difficulties increase six-star operator hope cost by +1, making it potentially impossible to recruit them with `Mind Over Matter Squad`.<br>`People-Oriented Squad` is better for high-level accounts, while `Mind Over Matter Squad` requires luck. |
| Sami | `Braving Nature·6` and higher difficulties increase six-star operator hope cost by +1, potentially making it impossible to recruit them with `Special Training Squad`. |
| Sarkaz | `Face the Spirit·15` and higher difficulties increase six-star operator hope cost by +1, potentially making it impossible to recruit them with `Blueprint Mapping Squad`.<br>With `Blueprint Mapping Squad`, MAA will adopt an avoidance strategy to quickly obtain `Spirit Bookmarks`, but generally cannot complete endings.<br>When using the Originium Ingot farming strategy with `Point-Stab Ingot Squad`, MAA will use shop refreshing to speed up the process. |
| Garden | `Enter the Garden·15` and higher difficulties increase six-star operator hope cost by +1, potentially making it impossible to recruit them with `Leader Squad`.<br>When set to `Enter the Garden·3` difficulty with the Originium Ingot farming strategy and `Leader Squad`, MAA will use the `End of Time` stage-skip strategy to speed up the process. |
| Theme | Notes |
| ------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Phantom | `Formal Investigation·3` and higher difficulties may offer hope-reducing collectibles at start, preventing recruitment of six-star operators. |
| Mizuki | `Surging Waves·4` and higher difficulties increase six-star operator hope cost by +1, making it potentially impossible to recruit them with `Mind Over Matter Squad`.<br>`People-Oriented Squad` is better for high-level accounts, while `Mind Over Matter Squad` requires luck. |
| Sami | `Braving Nature·6` and higher difficulties increase six-star operator hope cost by +1, making it potentially impossible to recruit them with `Special Training Squad`. |
| Sarkaz | `Facing Souls·15` and higher difficulties increase six-star operator hope cost by +1, making it potentially impossible to recruit them with `Blueprint Mapping Squad` unless `Blueprint Mapping Squad Enhancement Ⅱ` has been activated in `Historical Reconstruction`.<br>When `Blueprint Mapping Squad` is selected, MAA will use a combat-avoidance strategy to quickly collect `Soul Bookmarks`, though it typically makes it impossible to witness an ending.<br>When the Originium Ingot farming strategy and the `Ingots Squad` are selected, MAA will use the shop refreshing strategy to speed up the process. |
| Garden | `Enter the Garden·15` and higher difficulties increase six-star operator hope cost by +1, making it potentially impossible to recruit them with `Leader Squad`.<br>When `Enter the Garden·3` difficulty, the Originium Ingot farming strategy and `Leader Squad` are selected, MAA will use the `End of Time` stage-skip strategy to speed up the process. |
:::

View File

@@ -8,6 +8,10 @@ icon: material-symbols:task
Usage of `resource/tasks` and description of each field
::: tip
It is recommended to use [Visual Studio Code](https://code.visualstudio.com/) and install [Maa Pipeline Support](https://marketplace.visualstudio.com/items?itemName=nekosu.maa-support) extension for efficient editing. For more details, please visit the extension's homepage and the [docs](../develop/vsc-ext-tutorial.md).
:::
::: warning
Please note that JSON files do not support comments. The comments in this document are for demonstration purposes only. Do not copy them directly into your JSON files.
:::
@@ -181,115 +185,207 @@ Please note that JSON files do not support comments. The comments in this docume
}
```
## Expression Calculation
Task list type fields (`sub`, `next`, `onErrorNext`, `exceededNext`, `reduceOtherTimes`) support expression calculations.
| Symbol | Meaning | Example |
| :---------: | :---------------------------------------------------------: | :---------------------------------------: |
| `@` | `@`-type Task | `Fight@ReturnTo` |
| `#` (unary) | Virtual task | `#self` |
| `#` (binary)| Virtual task | `StartUpThemes#next` |
| `*` | Repeat tasks | `(ClickCornerAfterPRTS+ClickCorner)*5` |
| `+` | Task list merge (in next-type attributes, only first occurrence of same-name tasks kept) | `A+B` |
| `^` | Task list difference (in first but not second, order preserved) | `(A+A+B+C)^(A+B+D)` (result is `C`) |
Operators `@`, `#`, `*`, `+`, `^` have precedence: `#` (unary) > `@` = `#` (binary) > `*` > `+` = `^`.
## Special Task Types
### Template Task (`@` Type Task)
### Template Task
Template task and base task are collectively called **template tasks**.
**Template tasks** include derived tasks and `@`-type tasks. The core of the template task can be understood as **modifying the default values of fields** based on the *base task*.
Allows using task "A" as template, with "B@A" representing a task generated from "A".
#### Derived Task
- If task "B@A" is not explicitly defined in `tasks.json`, then add `B@` prefix to `sub`, `next`, `onErrorNext`, `exceededNext`, `reduceOtherTimes` fields (or `B` if task name begins with `#`), all other parameters match task "A". For example, if task "A" has:
Tasks with the `baseTask` field are derived tasks, and the task corresponding to the `baseTask` field is referred to as its *base task* of this derived task. For a derived task,
1. If it is an template matching task, the default value for the `template` field remains `"TaskName.png"`;
2. If the `algorithm` field differs from its *base task*, the derived class parameters are not inherited (only parameters defined in `TaskInfo` are inherited);
3. The default values for all other fields are the corresponding fields of its *base task*.
#### Implicit `@`-type Task
If task `"A"` exists and there is not a task directly defined in any task file such as `"B@A"`, it is an implicit `@`-type task, and task `"A"` is called the *base task* of task `"B@A"`. For an implicit `@`-type task,
1. The default values for task list type fields (`sub`, `next`, `onErrorNext`, `exceededNext`, `reduceOtherTimes`) are set to the base task's corresponding fields with the `B@` prefix directly appended (if the task name starts with `#`, the `B` prefix is appended);
2. The default values for all other fields (including the `template` field) are the corresponding fields of its *base task*.
#### Explicit `@`-type Task
If task `"A"` exists and there is a task directly defined in the task file such as `"B@A"`, it is an explicit `@`-type task, and task `"A"` is called the *base task* of task `"B@A"`. For an explicit `@`-type task,
1. The default values for task list type fields (`sub`, `next`, `onErrorNext`, `exceededNext`, `reduceOtherTimes`) are set to the base task's corresponding fields with the `B@` prefix directly appended (if the task name starts with `#`, the `B` prefix is appended);
2. If it is an template matching task, the default value for the `template` field remains `"TaskName.png"`;
3. If the `algorithm` field differs from its *base task*, the derived class parameters are not inherited (only parameters defined in `TaskInfo` are inherited);
4. The default values for all other fields are the corresponding fields of its *base task*.
### Virtual Task (`#`-type Task)
Virtual tasks are tasks of the form `"#{sharp_type}"` or `"B#{sharp_type}"`, where `{sharp_type}` can be `none`, `self`, `back`, `next`, `sub`, `on_error_next`, `exceeded_next`, or `reduce_other_times`.
Virtual tasks can be divided into **command virtual tasks** (`#none` / `#self` / `#back`) and **field virtual tasks** (`#next`, etc.).
| Virtual Task Type | Meaning | Simple example |
|:---------:|:---:|:--------:|
| none | Empty Task | Skip directly<sup>1</sup><br>`"A": {"next": ["#none", "T1"]}` is interpreted as `"A": {"next": ["T1"]}`<br>`"A#none + T1"` is interpreted as `"T1"` |
| self | Current Task Name | `"A": {"next": "#self"}` in `"#self"` is interpreted as `"A"`<br>`"B": {"next": "A@B@C#self"}` in `"A@B@C#self"` is interpreted as `"B"`.<sup>2</sup> |
| back | # Preceding task name | `"A@B#back"` is interpreted as `"A@B"`<br>`"#back"` will be skipped if it appears directly<sup>3</sup> |
| next, sub, etc. | # The field corresponding to the previous task name | Take `next` for example:<br>`"A#next"` is interpreted as `Task.get("A")->next`<br>`"#next"` will be skipped if it appears directly |
*Note<sup>1</sup>: `"#none"` generally used in conjunction with the template task to add prefixes, or used in the `baseTask` field to avoid unnecessary fields in multi-file inheritance.*
*Note<sup>2</sup>: `"XXX#self"` has the same meaning as `"#self"`.*
*Note<sup>3</sup>: When several tasks have `"next": [ "#back" ]`, `"T1@T2@T3"` represents executing `T3`, `T2`, and `T1` in sequence.*
### Multi-File Task
If a task defined in a later loaded task file (e.g. `tasks.json` for foreign services; hereinafter called File 2) also has a task of the same name defined in a earlier loaded task file (e.g. `tasks.json` for official services; hereinafter called File 1), then.
- if the task in File 2 does not have a `baseTask` field, then it inherits the fields of the task with the same name in File 1 directly.
- If the task in File 2 has a `baseTask` field, then it does not inherit the fields of the task with the same name in File 1, but overwrites them. In particular, when there is no template task, you can use `"baseTask": "#none"` to avoid inheriting unnecessary fields.
### Simple Example
- Derived task example (field `baseTask`)
Assume the following two tasks are defined:
```json
"Return": {
"action": "ClickSelf",
"next": [ "Stop" ]
},
"Return2": {
"baseTask": "Return"
},
```
The parameters of the `"Return2"` task are directly inherited from the `"Return"` task, and actually include the following parameters:
```json
"Return2": {
"algorithm": "MatchTemplate", // Directly inherited
"template": "Return2.png", // "TaskName.png"
"action": "ClickSelf", // Directly inherited
"next": [ "Stop" ] // Directly inherited, without any prefix compared to the Template Task
}
```
- `@`-type task example
Assume that a task `"A"` with the following parameters is defined:
```json
"A": {
"template": "A.png",
...,
"next": [ "N1", "N2" ]
}
"next": [ "N1", "#back" ]
},
```
This would be equivalent to defining:
If the task `"B@A"` is not directly defined, then the task `"B@A"` actually has the following parameters:
```json
"B@A": {
"template": "A.png",
...,
"next": [ "B@N1", "B@N2" ]
"next": [ "B@N1", "B#back" ]
}
```
- If task "B@A" is defined in `tasks.json`, then:
1. If "B@A" has different `algorithm` from "A", derived class parameters are not inherited (only `TaskInfo` parameters inherited)
2. For image matching tasks, if `template` not explicitly defined, uses `B@A.png` (not inheriting "A" template name); otherwise any derived parameters not explicitly defined inherit directly from "A"
3. For `TaskInfo` base class parameters (common to all task types like `algorithm`, `roi`, `next`, etc.), if not explicitly defined in "B@A", inherit directly from "A" except for the five fields mentioned above which get "B@" prefixed when inherited
If the task `"B@A"` is defined as `"B@A": {}`, then the task `"B@A"` actually has the following parameters:
### Base Task
Base task and template task are collectively called **template tasks**.
Tasks with `baseTask` field are base tasks.
Base task logic takes precedence over template task. This means `"B@A": { "baseTask": "C", ... }` has no relation to task A.
Any parameter not explicitly defined uses the corresponding parameter from `baseTask` without prefix, except `template` which remains `"TaskName.png"` when not explicitly defined.
#### Multi-File Tasks
If a task defined in a later-loaded file (e.g., foreign server `tasks.json`, called File 2) is also defined in an earlier-loaded file (e.g., CN server `tasks.json`, called File 1), then:
- If File 2's task has no `baseTask` field, it directly inherits fields from File 1's same-name task.
- If File 2's task has a `baseTask` field, it doesn't inherit fields from File 1's same-name task, but overwrites them instead.
### Virtual Task (`#` Task)
Virtual tasks are also called sharp tasks (`#` type tasks).
Tasks with `#` in name are virtual tasks. `#` can be followed by `next`, `back`, `self`, `sub`, `on_error_next`, `exceeded_next`, `reduce_other_times`.
| Virtual Task Type | Meaning | Simple Example |
| :----------: | :----------------: | :--------------------------------------------------------------------------------------------------------------------------------------: |
| self | Parent task name | `"A": {"next": "#self"}` where `"#self"` interpreted as `"A"`<br>`"B": {"next": "A@B@C#self"}` where `"A@B@C#self"` interpreted as `"B"`<sup>1</sup> |
| back | Task name before # | `"A@B#back"` interpreted as `"A@B"`<br>`"#back"` directly appears will be skipped |
| next, sub, etc. | Field of task name before # | For example with `next`:<br>`"A#next"` interpreted as `Task.get("A")->next`<br>`"#next"` directly appears will be skipped |
_Note<sup>1</sup>: `"XXX#self"` has same meaning as `"#self"`._
#### Simple Example
```json
{
"A": { "next": ["N1", "N2"] },
"C": { "next": ["B@A#next"] },
"Loading": {
"next": ["#self", "#next", "#back"]
},
"B": {
"next": ["Other", "B@Loading"]
```json
"B@A": {
"template": "B@A.png",
...,
"next": [ "B@N1", "B#back" ]
}
}
```
```
Results in:
- Virtual task example
```cpp
Task.get("C")->next = { "B@N1", "B@N2" };
```json
{
"A": { "next": ["N1", "N2"] },
"C": { "next": ["B@A#next"] },
Task.get("B@Loading")->next = { "B@Loading", "Other", "B" };
Task.get("Loading")->next = { "Loading" };
Task.get_raw("B@Loading")->next = { "B#self", "B#next", "B#back" };
```
"Loading": {
"next": ["#self", "#next", "#back"]
},
"B": {
"next": ["Other", "B@Loading"]
}
}
```
#### Some Use Cases
Results in:
- When several tasks have `"next": [ "#back" ]`, `"Task1@Task2@Task3"` means execute `Task3`, then `Task2`, then `Task1` in sequence.
```cpp
Task.get("C")->next = { "B@N1", "B@N2" };
#### Other Related Cases
Task.get("B@Loading")->next = { "B@Loading", "Other", "B" };
Task.get("Loading")->next = { "Loading" };
Task.get_raw("B@Loading")->next = { "B#self", "B#next", "B#back" };
```
```json
{
"A": { "next": ["N0"] },
"B": { "next": ["A#next"] },
"C@A": { "next": ["N1"] }
}
```
### Precautions
In this case, `"C@B" -> next` (i.e., `C@A#next`) is `[ "N1" ]`, not `[ "C@N0" ]`.
If the tasks defined in the task list type field (`next`, etc.) contain low-priority operations, the actual results may not match expectations, so please be aware of this.
1. Special cases caused by the order of operations between `@` and double `#`
```json
{
"A": { "next": ["N0"] },
"B": { "next": ["A#next"] },
"C@A": { "next": ["N1"] }
}
```
In the above case, `"C@B" -> next` (i.e., `C@A#next`) is `[ "N1" ]` rather than `[ "C@N0" ]`.
2. Special cases caused by the order of operations between `@` and `+`
```json
{
"A": { "next": ["#back + N0"] },
"B@A": {}
}
```
In the above case,
```cpp
Task.get("A")->next = { "N0" };
Task.get_raw("B@A")->next = { "B#back + N0" };
Task.get("B@A")->next = { "B", "N0" }; // Note that it is not [ "B", "B@N0" ]
```
In fact, you can use this feature to avoid adding unnecessary prefixes by simply defining
```json
{
"A": { "next": ["#none + N0"] }
}
```
## Runtime Task Modification
- `Task.lazy_parse()` loads JSON task configuration files at runtime. Lazy_parse rules match [Multi-File Tasks](#multi-file-tasks).
- `Task.lazy_parse()` loads JSON task configuration files at runtime. Lazy_parse rules match [Multi-File Task](#multi-file-task).
- `Task.set_task_base()` modifies a task's `baseTask` field.
### Usage Example
@@ -329,19 +425,6 @@ default:
}
```
## Expression Calculation
| Symbol | Meaning | Example |
| :---------: | :------------------------------------------------------: | :------------------------------------: |
| `@` | Template task | `Fight@ReturnTo` |
| `#` (unary) | Virtual task | `#self` |
| `#` (binary) | Virtual task | `StartUpThemes#next` |
| `*` | Repeat multiple tasks | `(ClickCornerAfterPRTS+ClickCorner)*5` |
| `+` | Task list merge (in next-type attributes, only first occurrence of same-name tasks kept) | `A+B` |
| `^` | Task list difference (in first but not second, order preserved) | `(A+A+B+C)^(A+B+D)` (result is `C`) |
Operators `@`, `#`, `*`, `+`, `^` have precedence: `#` (unary) > `@` = `#` (binary) > `*` > `+` = `^`.
## Schema Validation
This project configures JSON schema validation for `tasks.json`, schema file is `docs/maa_tasks_schema.json`.

View File

@@ -12,11 +12,11 @@ dir:
![MAA Logo =256x256](/images/maa-logo_512x512.png)
<!-- markdownlint-restore -->
# MaaAssistantArknights
# MAA
![C++](https://img.shields.io/badge/C++-20-%2300599C?logo=cplusplus)
![platform](https://img.shields.io/badge/platform-Windows%20%7C%20Linux%20%7C%20macOS-blueviolet)
![license](https://img.shields.io/github/license/MaaAssistantArknights/MaaAssistantArknights) ![commit](https://img.shields.io/github/commit-activity/m/MaaAssistantArknights/MaaAssistantArknights?color=%23ff69b4)
![C++](https://img.shields.io/badge/C++-20-%2300599C?logo=cplusplus)
![platform](https://img.shields.io/badge/platform-Windows%20%7C%20Linux%20%7C%20macOS-blueviolet)
![license](https://img.shields.io/github/license/MaaAssistantArknights/MaaAssistantArknights) ![commit](https://img.shields.io/github/commit-activity/m/MaaAssistantArknights/MaaAssistantArknights?color=%23ff69b4)
![stars](https://img.shields.io/github/stars/MaaAssistantArknights/MaaAssistantArknights?style=social) ![GitHub all releases](https://img.shields.io/github/downloads/MaaAssistantArknights/MaaAssistantArknights/total?style=social)
MAA stands for MAA Assistant Arknights
@@ -48,28 +48,24 @@ Please read the [documentation](./manual/newbie.md) and then visit the [official
See it in action!
```component Image4
{
"imageList": [
{
"light": "images/en-us/readme/1-light.png",
"dark": "images/en-us/readme/1-dark.png"
},
{
"light": "images/en-us/readme/2-light.png",
"dark": "images/en-us/readme/2-dark.png"
},
{
"light": "images/en-us/readme/3-light.png",
"dark": "images/en-us/readme/3-dark.png"
},
{
"light": "images/en-us/readme/4-light.png",
"dark": "images/en-us/readme/4-dark.png"
}
]
}
```
<ImageGrid :imageList="[
{
light: 'images/en-us/readme/1-light.png',
dark: 'images/en-us/readme/1-dark.png'
},
{
light: 'images/en-us/readme/2-light.png',
dark: 'images/en-us/readme/2-dark.png'
},
{
light: 'images/en-us/readme/3-light.png',
dark: 'images/en-us/readme/3-dark.png'
},
{
light: 'images/en-us/readme/4-light.png',
dark: 'images/en-us/readme/4-dark.png'
}
]" />
## Usage Instructions

View File

@@ -1,30 +0,0 @@
---
home: true
navbar: false
containerClass: home
heroText: MAA 文档站 | Document
tagline: 选择语言 | Select Language
heroAlt: MAA Logo
heroImage: /images/maa-logo_512x512.png
heroFullScreen: true
actions:
- text: 简体中文
link: ./zh-cn/
type: primary
- text: 繁體中文
link: ./zh-tw/
type: primary
- text: English
link: ./en-us/
type: primary
- text: 日本語
link: ./ja-jp/
type: primary
- text: 한국어
link: ./ko-kr/
type: primary
---

View File

@@ -9,7 +9,13 @@ icon: jam:write-f
このドキュメントの目的は、ドキュメント作成者がテーマが提供する機能をより良く活用し、読みやすさを向上させることを指導することです。
:::
私たちのドキュメントは [vuepress](https://github.com/vuejs/vuepress) に基づいて構築されており、[vuepress-theme-hope](https://github.com/vuepress-theme-hope/vuepress-theme-hope) テーマが使用されています。詳細な説明については[公式ドキュメント](https://theme-hope.vuejs.press/)をご覧いただけます。ここでは一部の一般的な機能について紹介します。
私たちのドキュメントは [vuepress](https://github.com/vuejs/vuepress) に基づいて構築されており、[vuepress-theme-plume](https://github.com/pengzhanbo/vuepress-theme-plume) テーマが使用されています。詳細な説明については[公式ドキュメント](https://theme-plume.vuejs.press/)をご覧いただけます。ここでは一部の一般的な機能について紹介します。
## ローカルデプロイ
1. [pnpm](https://pnpm.io/installation) をインストールし、[Pull Request ワークフローの概要](./development.md#github-pull-request-プロセス概要)を参照してリポジトリをローカルにクローンします。
2. `docs` ディレクトリでターミナルを開き、`pnpm i` を実行して依存関係をインストールします。
3. `pnpm run dev` を実行してデプロイします。
## コンテナ

View File

@@ -24,16 +24,12 @@ repo、コードやその他のリソースファイルを保存する場所で
👇 これはMAAのリポジトリです一般的にMAAのメインリポジトリと呼ばれます
```component Image1
{
"imageList": [
{
"light": "images/zh-cn/pr-tutorial/repository-light.png",
"dark": "images/zh-cn/pr-tutorial/repository-dark.png"
}
]
}
```
<ImageGrid :imageList="[
{
light: 'images/zh-cn/pr-tutorial/repository-light.png',
dark: 'images/zh-cn/pr-tutorial/repository-dark.png'
}
]" />
### Fork複製
@@ -44,16 +40,12 @@ repo、コードやその他のリソースファイルを保存する場所で
区別するために、元のMAAリポジトリは「主リポジトリ」「upstream上流リポジトリ」「origin元のリポジトリ」と呼ばれます。
それぞれの人がコピーできるので、コピーしたものを「個人リポジトリ」と呼びます。
```component Image1
{
"imageList": [
{
"light": "images/zh-cn/pr-tutorial/fork-light.png",
"dark": "images/zh-cn/pr-tutorial/fork-dark.png"
}
]
}
```
<ImageGrid :imageList="[
{
light: 'images/zh-cn/pr-tutorial/fork-light.png',
dark: 'images/zh-cn/pr-tutorial/fork-dark.png'
}
]" />
### Pull Requestプルリクエスト、マージリクエスト
@@ -65,16 +57,12 @@ repo、コードやその他のリソースファイルを保存する場所で
👇 以下は、現在承認待ちの提出されたPRの例です。
```component Image1
{
"imageList": [
{
"light": "images/zh-cn/pr-tutorial/pull-request-light.png",
"dark": "images/zh-cn/pr-tutorial/pull-request-dark.png"
}
]
}
```
<ImageGrid :imageList="[
{
light: 'images/zh-cn/pr-tutorial/pull-request-light.png',
dark: 'images/zh-cn/pr-tutorial/pull-request-dark.png'
}
]" />
### Conflictコンフリクト
@@ -87,164 +75,116 @@ Conflictを解決するのは少し面倒ですが、ここでは概念につい
1. まず、MAAのメインリポジトリにアクセスして、コードをforkします。
```component Image1
{
"imageList": [
{
"light": "images/zh-cn/pr-tutorial/fork-light.png",
"dark": "images/zh-cn/pr-tutorial/fork-dark.png"
}
]
}
```
<ImageGrid :imageList="[
{
light: 'images/zh-cn/pr-tutorial/fork-light.png',
dark: 'images/zh-cn/pr-tutorial/fork-dark.png'
}
]" />
2. 「Copy the master branch only」オプションを外して、Create Forkをクリックします。
```component Image1
{
"imageList": [
{
"light": "images/zh-cn/pr-tutorial/pr-2-light.png",
"dark": "images/zh-cn/pr-tutorial/pr-2-dark.png"
}
]
}
```
<ImageGrid :imageList="[
{
light: 'images/zh-cn/pr-tutorial/pr-2-light.png',
dark: 'images/zh-cn/pr-tutorial/pr-2-dark.png'
}
]" />
3. 次に、あなたの個人リポジトリに移動し、「あなたの名前/ MaaAssistantArknights」というタイトルが表示され、下に「MAAメインリポジトリから複製されたMaaAssistantArknights/MaaAssistantArknights」という文言が表示されます。
```component Image1
{
"imageList": [
{
"light": "images/zh-cn/pr-tutorial/pr-3-light.png",
"dark": "images/zh-cn/pr-tutorial/pr-3-dark.png"
}
]
}
```
<ImageGrid :imageList="[
{
light: 'images/zh-cn/pr-tutorial/pr-3-light.png',
dark: 'images/zh-cn/pr-tutorial/pr-3-dark.png'
}
]" />
4. 変更するファイルを探します。 "Go to file" をクリックしてグローバル検索を行うか、下のフォルダーから直接検索することもできます(ファイルの場所を知っている場合)。
```component Image1
{
"imageList": [
{
"light": "images/zh-cn/pr-tutorial/pr-4-light.png",
"dark": "images/zh-cn/pr-tutorial/pr-4-dark.png"
}
]
}
```
<ImageGrid :imageList="[
{
light: 'images/zh-cn/pr-tutorial/pr-4-light.png',
dark: 'images/zh-cn/pr-tutorial/pr-4-dark.png'
}
]" />
5. ファイルを開いたら、ファイルの右上隅にある✏️をクリックして編集を開始します。
```component Image1
{
"imageList": [
{
"light": "images/zh-cn/pr-tutorial/pr-5-light.png",
"dark": "images/zh-cn/pr-tutorial/pr-5-dark.png"
}
]
}
```
<ImageGrid :imageList="[
{
light: 'images/zh-cn/pr-tutorial/pr-5-light.png',
dark: 'images/zh-cn/pr-tutorial/pr-5-dark.png'
}
]" />
6. 変更を加えますもちろん、リソースファイルなどの場合は、まずMAAフォルダー内で変更をテストし、問題がないことを確認してから、ウェブページに貼り付けて変更を行ってください
7. 変更が完了したら、一番下までスクロールして、変更内容を記述します。
```component Image1
{
"imageList": [
{
"light": "images/zh-cn/pr-tutorial/pr-7-1-light.png",
"dark": "images/zh-cn/pr-tutorial/pr-7-1-dark.png"
}
]
}
```
<ImageGrid :imageList="[
{
light: 'images/zh-cn/pr-tutorial/pr-7-1-light.png',
dark: 'images/zh-cn/pr-tutorial/pr-7-1-dark.png'
}
]" />
```component Image1
{
"imageList": [
{
"light": "images/zh-cn/pr-tutorial/pr-7-2-light.png",
"dark": "images/zh-cn/pr-tutorial/pr-7-2-dark.png"
}
]
}
```
<ImageGrid :imageList="[
{
light: 'images/zh-cn/pr-tutorial/pr-7-2-light.png',
dark: 'images/zh-cn/pr-tutorial/pr-7-2-dark.png'
}
]" />
8. 変更するもう1つのファイルがある場合は、5-8を繰り返してください。
9. 変更が完了したら、PRを行います個人リポジトリのPull Requestタブをクリックします。
「Compare & Pull Request」ボタンがある場合は、それをクリックしてください。ない場合は、「New Pull Request」をクリックしてください。
```component Image1
{
"imageList": [
{
"light": "images/zh-cn/pr-tutorial/pr-9-light.png",
"dark": "images/zh-cn/pr-tutorial/pr-9-dark.png"
}
]
}
```
<ImageGrid :imageList="[
{
light: 'images/zh-cn/pr-tutorial/pr-9-light.png',
dark: 'images/zh-cn/pr-tutorial/pr-9-dark.png'
}
]" />
10. これでメインリポジトリに移動します。PRする内容を確認してください。
スクリーンショットのように、真ん中に左向きの矢印があり、右側の「個人名/MAA」のdevブランチを「メインリポジトリ/MAA」のdevブランチにマージすることを申請しています。
```component Image1
{
"imageList": [
{
"light": "images/zh-cn/pr-tutorial/pr-10-1-light.png",
"dark": "images/zh-cn/pr-tutorial/pr-10-1-dark.png"
}
]
}
```
<ImageGrid :imageList="[
{
light: 'images/zh-cn/pr-tutorial/pr-10-1-light.png',
dark: 'images/zh-cn/pr-tutorial/pr-10-1-dark.png'
}
]" />
次に、タイトルや変更内容などを記述して、承認をリクエストします。
```component Image1
{
"imageList": [
{
"light": "images/zh-cn/pr-tutorial/pr-10-2-light.png",
"dark": "images/zh-cn/pr-tutorial/pr-10-2-dark.png"
}
]
}
```
<ImageGrid :imageList="[
{
light: 'images/zh-cn/pr-tutorial/pr-10-2-light.png',
dark: 'images/zh-cn/pr-tutorial/pr-10-2-dark.png'
}
]" />
11. MAAチームの大佬たちに承認していただきましょうもちろん、意見を提供してくださることもあるかもしれません
👇例えば(純粋に娯楽のために、本気にしないでください)
```component Image1
{
"imageList": [
{
"light": "images/zh-cn/pr-tutorial/pr-11-light.png",
"dark": "images/zh-cn/pr-tutorial/pr-11-dark.png"
}
]
}
```
<ImageGrid :imageList="[
{
light: 'images/zh-cn/pr-tutorial/pr-11-light.png',
dark: 'images/zh-cn/pr-tutorial/pr-11-dark.png'
}
]" />
12. 大佬たちがさらに小さな問題を修正するように言った場合、あなたの個人のリポジトリに戻って、以前のdevブランチに切り替え、手順3-9を繰り返すだけで大丈夫です
手順2再度フォークするを実行する必要はなく、手順10再度プルリクエストするを実行する必要もありません。現在のプルリクエストはまだ承認待ちの状態にあり、後続の変更はこのプルリクエストに直接反映されます。
👇 以下は例です。最下部に「再度変更デモを変更」というメッセージが追加されたことがわかります。
```component Image1
{
"imageList": [
{
"light": "images/zh-cn/pr-tutorial/pr-12-light.png",
"dark": "images/zh-cn/pr-tutorial/pr-12-dark.png"
}
]
}
```
<ImageGrid :imageList="[
{
light: 'images/zh-cn/pr-tutorial/pr-12-light.png',
dark: 'images/zh-cn/pr-tutorial/pr-12-dark.png'
}
]" />
13. 大佬たちの承認を得たら、すべて完了です! バージョンがリリースされた後、あなたのGitHubプロフィールアイコンは自動的に貢献者リストに追加されます。皆様のご奉仕に深く感謝申し上げます
~~なんで全部二次元キャラなんだろう、あ、私も二次元好きだったわ。ま、いいか~~
@@ -263,19 +203,15 @@ Conflictを解決するのは少し面倒ですが、ここでは概念につい
私が言ったことが何を意味するのか分からない/関係ない場合は、左側のボタンをクリックしてください。
```component Image1
{
"imageList": [
{
"light": "images/zh-cn/pr-tutorial/pr-14-1-light.png",
"dark": "images/zh-cn/pr-tutorial/pr-14-1-dark.png"
},
{
"light": "images/zh-cn/pr-tutorial/pr-14-2-light.png",
"dark": "images/zh-cn/pr-tutorial/pr-14-2-dark.png"
}
]
}
```
<ImageGrid :imageList="[
{
light: 'images/zh-cn/pr-tutorial/pr-14-1-light.png',
dark: 'images/zh-cn/pr-tutorial/pr-14-1-dark.png'
},
{
light: 'images/zh-cn/pr-tutorial/pr-14-2-light.png',
dark: 'images/zh-cn/pr-tutorial/pr-14-2-dark.png'
}
]" />
その後、ステップ3-14を繰り返し、変更を加え、PRを提出することができます。

View File

@@ -0,0 +1,104 @@
---
order: 8
icon: iconoir:code-brackets
---
# Dedicated VSCode Extension Tutorial
* [Extension Store](https://marketplace.visualstudio.com/items?itemName=nekosu.maa-support)
* [Repository](https://github.com/neko-para/maa-support-extension)
## Installation
Searching `Maa` and installing it from VSCode extensions list is recommended.
## Features
### Control Panel
A dedicated control panel is added to the left, with icon ![MaaSupport ControlPanel](/images/maa-support-panel.svg)
The major features of the extension are based on the `interface.json` configuration. Select the activated `interface.json` on the top of the control panel.
The extension has a `Maa` compatiable mode. If `src/MaaCore` folder exists inside the opened workspace, the mode will be enabled automatically.
### Semantic resource analysis
Select expected resource via the `Resource` select inside the control panel. The extension will index and diagnose resource via corresponding paths.
If you find that the editing json isn't hinted by the extension, please check if the activated resource contains it.
> The term `definitions of task / task defs` refers to key props of task objects.
>
> The term `references of task / task refs` refers to values containing task name (e.g. in `next`) in other task objects.
#### Query task defs / task refs
The extension supports Jump to task defs, Jump to task refs and View task defs.
When enabling the `Maa` compatible mode, the extension will be able to parse `template task`, supporting querying task defs and task refs in conjunction with base tasks. Images that has the same name of the task will be shown when hovering the task defs.
#### Query / open images
The extension supports open images.
When enabling the `Maa` compatible mode, the extension will be able to recursively search for the image.
#### Task completion
The extension supports autocompletion according to all known tasks.
When enabling the `Maa` compatible mode, typing `@` will trigger completion.
#### Image path completion
The extension supports autocompletion according to the path of all known images.
When enabling the `Maa` compatible mode, the extension will be able to recursively search for the image.
#### Check tasks / image paths
The extension supports scheduled scanning and diagnosing all tasks.
* Check if contains task defs with same names.
* Check if contains unknown task refs.
* Check if contains unknown image refs.
* Check if contains duplicated task refs in a single task.
#### Multiple paths resource support
The extension supports resource with multiple paths. The extension will perform logical overlapping according to specified order, thus content loaded later can reference content loaded earlier.
### Evaluate Task / Tsak List Expression (Only Maa)
Evaluating the expanded task object and the sources of each properties, and the result of the task list expression via the control panel.
### MaaPiCli feature (Only MaaFramework projects)
Scanning and selecting controllers, selecting resource, adding and manipulating tasks, and launching tasks can be done via the control panel.
### Take screenshots and crop images
Searching and launching `Maa: open crop tool` inside VSCode command panel can open `Screenshots / Crop` panel.
> Use `Ctrl+Shift+P` (`Command+Shift+P` on MacOS) to open command panel
* After selecting and connecting to the controller, use `Screencap` button to obtain screenshots
* Use `Upload` button to manually upload images.
* Hold `Ctrl` key and select cropping area
* Use wheels to zoom
* After finishing cropping, use `Download` button to save the cropping result to the folder of the topest layer of the activated resource
### Bottom status bar
#### MaaSupport \[Extension Version\]
Click to reveal control panel
#### MaaFramework \[MaaFw Version\]
Click to switch `MaaFramework` version used by the extension
> When used for the first time, the preset version will be downloaded.
>
> Search command `Maa: select fetch registry` to switch downloading source (npm / cnpm).

View File

@@ -0,0 +1,9 @@
---
title: 使用説明
icon: mdi:user
index: false
dir:
order: 1
---
<Catalog base='/ja-jp/manual/' />

View File

@@ -1,7 +1,7 @@
---
title: CLI ユーザーガイド
icon: material-symbols:terminal
index: false
index: true
dir:
order: 6
---

View File

@@ -1,5 +1,5 @@
---
order: 4
order: 2
icon: ph:question-fill
---

View File

@@ -179,6 +179,8 @@ MAA は現在 `bluestacks.conf` の保存場所をレジストリから読み取
- 国際版のデフォルトパスは `C:\ProgramData\BlueStacks_nxt\bluestacks.conf` です。
- 中国本土版のデフォルトパスは `C:\ProgramData\BlueStacks_nxt_cn\bluestacks.conf` です。
注意:`C:\ProgramData`は隠しディレクトリです。必要に応じて、このアドレスをファイルエクスプローラのアドレスバーに直接貼り付けて、アクセスしてください。
2. 初めて使用する場合は、一度 MAA を実行して、MAA が設定ファイルを自動生成するようにします。
3. **MAA を閉じた後に**、`gui.json` を開き、`Configurations` の下の現在の設定名フィールド(設定-切り替え設定 で確認できます。デフォルトは `Default`)を検索し、`Bluestacks.Config.Path` フィールドを検索して、`bluestacks.conf` の完全なパスを入力します。(スラッシュはエスケープ `\\` を使用してください)

View File

@@ -1,5 +1,5 @@
---
order: 4
order: 2
icon: ph:question-fill
---

View File

@@ -3,7 +3,7 @@ title: 詳細説明
icon: mdi:information-outline
index: false
dir:
order: 2
order: 4
---
<Catalog base='/ja-jp/manual/introduction/' />

View File

@@ -2,44 +2,43 @@
order: 9
icon: ph:sword-bold
---
# 自動戦闘
# 自动战斗
作業共有サイト [prts.plus](https://prts.plus) で作業ファイルをご利用・共有ください。
::: important Translation Required
This page is outdated and maybe still in Simplified Chinese. Translation is needed.
::: warning
自動戦闘に関わるすべての機能は、最低60フレームの安定したゲームフレームレートが必要です。これには自動戦闘や自動ローグライクが含まれますが、これに限定されません。
:::
欢迎使用作业分享站 [prts.plus](https://prts.plus) 使用及分享作业文件。
## 自動攻略のコピー
## 抄作业
任意の `編成可能ステージ``保全駐在` モードの自動戦闘をサポートします。
支持任意 `可编队关卡``保全派驻` 模式的自动战斗。
- 本功能需要在有 `开始行动` 按钮的编队选择界面开始运行。
之后在 MAA 左侧上部的框中 `导入本地 JSON 作业文件``填写作业站神秘代码` 即可导入作业
- `自动编队` 功能会**清空当前编队**并根据作业需要的干员自动完成编队
- 自動編成に対応するオペレーターの特別フォーカスを解除する必要があります。
- 可根据任务需要为自动编队 `追加自定干员``补充低信赖干员`
- 可根据个人需要(例如需要使用 `好友助战` 时)取消 `自动编队`,手动编队后开始
- 对于「悖论模拟」关卡,必须关闭 `自动编队`,手动选择技能后,在有**开始模拟**按钮的界面开始自动战斗
- 对于「保全派驻」关卡,`自动编队` 无效,必须手动完成**初始**任务准备,直到在关卡详情有**开始部署**按钮的界面才能开始自动战斗
- 可设置 `循环次数`,例如保全。但 MAA 不会借干员,如需借干员请勿使用。
- 可使用 `战斗列表` 功能进行同一区域关卡的自动连续战斗
- 战斗列表下方三个按钮从左到右依次为 `批量导入``添加关卡``清空关卡`
`添加关卡` 右键为添加突袭关卡,`清空关卡` 右键为清空未勾选关卡,
- 导入作业后,战斗列表下方会出现关卡名,确认正确后再添加该关卡。列表中的关卡可以拖拽调整顺序,勾选是否执行
- 开启本功能后改为在**关卡所在的地图界面**开始自动战斗。在理智不足/战斗失败/非三星结算时将停止自动战斗队列。
- 请确保列表中的关卡在同一区域(只通过左右滑动地图界面就可以导航到)。
- **请务必为优质作业点赞,以提高作业评分并激励作业制作者。**
- 本機能は `作戦開始` ボタンがある編成選択画面で開始する必要があります。
その後、MAA 左側上部の枠内で `ローカル JSON 作業ファイルをインポート` または `ミステリーコードを入力` して作業をインポートできます。
- `自動編成` 機能は**現在の編成をクリア**し、作業に必要なオペレーターに基づいて自動的に編成を完了します。
- 自動編成に対応するオペレーターのためお気に入り表示を解除する必要があります
- タスクの必要に応じて自動編成に `カスタムオペレーターを追加` および `低信頼度オペレーターを補充` できます
- 個人の必要に応じて(例:`戦友サポート` を使用する場合)、`自動編成` をキャンセルし、手動編成後に開始できます。
- 「逆理演算」ステージの場合、`自動編成` を無効にし、手動でスキルを選択した後、**シミュレーション開始**ボタンがある画面で自動戦闘を開始する必要があります
- 「保全駐在」ステージの場合、`自動編成` は無効で、手動で**初期**タスク準備を完了し、ステージ詳細に**配置開始**ボタンがある画面まで進んで自動戦闘を開始できます
- `ループ回数` を設定できます保全。ただし、MAA はオペレーターを借りないため、オペレーターを借りる必要がある場合は使用しないでください
- `バトルリスト` 機能を使用して、同一エリアのステージの自動連続戦闘を行えます
- バトルリスト下部の3つのボタンは左から右へ順に `一括インポート``ステージ追加``ステージクリア` です。
`ステージ追加` を右クリックすると強襲ステージを追加、`ステージクリア` を右クリックするとチェックされていないステージをクリアします
- 作業をインポートすると、戦闘リスト下部にステージ名が表示されます。正しいことを確認してからそのステージを追加してください。リスト内のステージはドラッグで順序を調整でき、実行するかどうかをチェックできます。
- この機能を有効にすると、**ステージが所在するマップ画面**で自動戦闘を開始するように変更されます。理性不足/戦闘失敗/非三星クリア時に自動戦闘キューが停止します。
- リスト内のステージが同一エリア内(マップ画面の左右スライドだけで移動可能)にあることを確認してください
- **優良な自動攻略には必ずいいねをして、作業評価を向上させ作業制作者を激励してください。**
![image](/images/zh-cn/copilot-click-like.png)
## 写作业
## 作業の作成
- 请使用 [作业编辑器](https://prts.plus/create) 制作,可参考 [战斗流程协议](../../protocol/copilot-schema.md)。
- 地图坐标获取
- 在作业编辑器中填写关卡后,左下角会自动加载可拖动缩放的坐标地图,可点选设置当前干员位置
- 填写关卡并导出 JSON 后直接开始行动,会在 MAA 目录下 `debug\map` 中生成覆盖有坐标信息的地图截图
- [PRTS.Map](https://map.ark-nights.com/areas),在设置中将 `坐标展示` 修改为 `MAA` 后使用
- 支持演习模式
- 建议在作业描述里填上你的署名(作者名)、参考攻略视频链接、其他想说的等等
- 欢迎加入企鹅群 [1169188429](https://jq.qq.com/?_wv=1027&k=QZcGcJ9G) 共同讨论作业制作等问题
- [作業エディター](https://prts.plus/create) をご利用ください。[戦闘フロープロトコル](../../protocol/copilot-schema.md) も参考にしてください
- マップ座標の取得
- 作業エディターでステージを入力すると、左下角にドラッグ・ズーム可能な座標マップが自動読み込みされ、クリックして現在のオペレーター位置を設定できます
- ステージを入力して JSON をエクスポートした後、直接作戦を開始すると、MAA ディレクトリ下の `debug\map` に座標情報が重ねられたマップスクリーンショットが生成されます
- [PRTS.Map](https://map.ark-nights.com/areas) で、設定の `座標表示` `MAA` に変更してご利用ください
- 演習モードをサポートします
- 作業説明には署名(作者名)、参考攻略動画リンク、その他伝えたいことなどを記載することをお勧めします
- 作業制作などの問題について討議するために、QQグループ [1169188429](https://jq.qq.com/?_wv=1027&k=QZcGcJ9G) への参加を歓迎します

View File

@@ -3,27 +3,54 @@ order: 7
icon: ri:game-fill
---
# 自动肉鸽
# 自動ローグ
MAAはデフォルトで最新のテーマを選択しますが、`自動ロゲット` - `ロゲットテーマ`でターゲットテーマを変更することができます。
- ゲーム内で該当のロゲットテーマを端末でピン留めしてください。現在は自動ナビゲートも可能ですが、長期的な使用可否は保証されません。
- **ターゲットテーマ**でない探索は事前に手動で終了してください
- MAAは難易度を自動で選択しません。難易度を選択していない場合、難易度選択画面で停止したり、繰り返し進出したりします。
- 設定で分隊編成、開始時のオペレーター(単一オペレーター名のみ)などを選択できます。
::: warning
すべての自動バトルに関連する機能は、少なくとも 60 フレームの安定したゲームフレームレートが必要です。これには自動バトルや自動ローグが含まれますが、これに限りません
:::
- ゲーム内で該当のロゲットテーマを端末に追加してください。現在は自動ナビゲートも可能ですが、長期的な使用可否は保証されません。
- **ターゲットテーマ**でない探索は事前に手動で終了してください。
- 設定では、テーマ、難易度、分隊、最初のオペレーター(単一のオペレーター名のみ)などを選択できます。
- MAA は、サポートオペレーターでの開始を使用できます。まず「一般設定」→「最初のオペレーター」に目標オペレーター名を入力し、「高度な設定」→「「最初のオペレーター」をサポートから選択」を有効にしてください。
- 新しくインストールしたクライアントで初めてプレイする場合:
- 難易度選択ボタンは表示されません。ゲーム内で一度手動で難易度を選択し、その後 MAA が自動で選択できます。
- 大マップなどの画面に入ると新手のチュートリアルが表示されます。読み終わったら手動で閉じてください。
## おすすめのスタート
::: details _最終更新日 2025/8/30_
| テーマ | 難易度 | 分隊 | 職業組 | オペレーター |
| ---------- | --------------- | --------------------------- | -------- | ------------ |
| ファントム | 正式調査·2 | 指揮分隊 / 突撃戦術分隊 | 前線支援 | ソーンズ |
| ミヅキ | 波瀾万丈·3~7 | 人文主義分隊 / 精神論分隊 | 攻守一体 | ウィシャデル |
| サーミ | 自然の猛威·4~10 | 特訓分隊 / 援護戦術分隊 | 攻守一体 | ウィシャデル |
| サルカズ | 魂に直面·4~10 | 位置測定分隊 / 援護戦術分隊 | 攻守一体 | ウィシャデル |
| 界園 | 請君入園·3~10 | 指揮分隊 / 援護戦術分隊 | 攻守一体 | ウィシャデル |
難易度の推奨は、`敵の難易度``希望消費``スコア倍率`などの要素を総合的に考慮しています。高い練度でテストした場合、比較的安定しており、実際の状況やニーズに応じて自由に調整できます。
| テーマ | 備考 |
| ---------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| ファントム | `正式調査·3` およびそれ以上の難易度で開始すると、希望消費を減少させるアイテムが手に入る場合があり、そのため開始時に六星オペレーターを召集できないことがあります。 |
| ミヅキ | `波瀾万丈·4` およびそれ以上の難易度では、六星オペレーターの召集に必要な希望消費が+1されます。 `精神論分隊` を使用して開始した場合、六星オペレーターを召集できないことがあります。<br>`精神論分隊` はアカウントの練度が高い場合に適しており、運に頼る必要があります。 |
| サーミ | `自然の猛威·6` およびそれ以上の難易度では、六星オペレーターの召集に必要な希望消費が+1されます。 `特訓分隊` を使用して開始した場合、六星オペレーターを召集できないことがあります。 |
| サルカズ | `魂に直面·15` およびそれ以上の難易度では、六星オペレーターの召集に必要な希望消費が+1されます。 `歴史再編`内でまだ `位置測定分隊強化Ⅱ`を有効にしていない場合、 `位置測定分隊` を使用して開始した場合、六星オペレーターを召集できないことがあります。<br> `位置測定分隊`を選択した場合、回避戦略が採用され、 `魂のしおり`を素早く取得できますが、基本的にエンディングをクリアすることはできません。<br>源石錐を収集戦略を使用した場合、開始時の分隊は `破棘成金分隊` とならば、商店更新戦略を使用してプロセスを加速します。 |
| 界園 | `請君入園·15` およびそれ以上の難易度では、六星オペレーターの召集に必要な希望消費が+1されます。 `指揮分隊` を使用して開始した場合、六星オペレーターを召集できないことがあります。<br>難易度が `請君入園·3`に設定され、源石錐を収集戦略を使用して開始時の分隊が `指揮分隊` とならば、 `時の果て` でスキップ戦略を使用してプロセスを加速します。 |
::: details 固定方法「PIN UP」
![固定方法](/images/ja-jp/introduction-i.s.-pin-up.png)
:::
## 戦闘戦略
MAAはロゲット内のすべての操作を予め設定された戦略で行い、すべてのステージ戦闘は内蔵された作業ファイルを呼び出して行われます。該当ステージの作業が存在しない場合、賢くない汎用的な意思決定ツリーを使用して戦闘を行います。
MAA はゲーム内のすべての操作を予め設定された戦略で行い、すべてのステージ戦闘は内蔵された作業ファイルを呼び出して行われます。該当ステージの作業が存在しない場合、賢くない汎用的な意思決定ツリーを使用して戦闘を行います。
詳細については[ロゲットプロトコル](../../protocol/integrated-strategy-schema.md)をご参照ください。
- オペレーターおよびレベルを自動で識別し、最適なオペレーターとスキルを自動で選択します。
- 商店のアイテムを識別し、より強力なコレクションを優先して購入します。
- 商店のアイテムを識別し、より強力なアイテムを優先して購入します。
## 異常検出

View File

@@ -2,29 +2,39 @@
order: 11
icon: icon-park-solid:other
---
# その他
# 其他
## GPU 推論加速
::: important Translation Required
This page is outdated and maybe still in Simplified Chinese. Translation is needed.
:::
DirectML を使用して GPU による認識推論を加速<sup>[PR](https://github.com/MaaAssistantArknights/MaaAssistantArknights/pull/9236)</sup>。わずかな GPU 使用量で大幅な CPU 使用量を削減できるため、有効にすることを推奨します。
テストの結果、一部のグラフィックカードは機能が不足しているか性能が低いため、この機能を使用すると認識の問題が発生することがあります。MAA には一部の GPU ブラックリストが内蔵されています<sup>[PR1](https://github.com/MaaAssistantArknights/MaaAssistantArknights/pull/9990)[PR2](https://github.com/MaaAssistantArknights/MaaAssistantArknights/pull/12134)</sup>。リスト外のグラフィックカードでこの機能を有効にした後に認識の問題が発生した場合は、Issue を報告してください。
## 启动时自动切换配置
## 一回のみ
MAA 支持通过启动参数自动切换配置,在 MAA 进程名后附加 `--config <配置名>` 即可。例子:`./MAA/MAA.exe --config 官服`
メイン画面と設定での設定変更は通常自動保存されますが、以下の項目は MAA 再起動後にリセットされます
部分符号需要转义,参考 Json。例子在配置名为 `"官服"` 时,参数应为 `--config \"官服\"`
- `*` マークが付いたオプション
- `(一回のみ)` マークが付いたオプション
- チェックボックスを右クリックして得られる半選択スイッチ
-
## 开始前/结束后脚本
## 起動時の自動設定切り替え
v4.13.0 后支持设置开始前/结束后脚本,可在任务前后自动执行批处理文件。输入框内需填写批处理文件即 `*.bat` 的绝对或相对路径
MAA は起動パラメータによる自動設定切り替えをサポートしており、MAA プロセス名の後に `--config <設定名>` を付けることで実行できます。例:`./MAA/MAA.exe --config 公式サーバー`
一部の記号はエスケープが必要で、Json を参考にしてください。例:設定名が `"公式サーバー"` の場合、パラメータは `--config \"公式サーバー\"` となります。
## 其他说明
## 開始前/終了後スクリプト
- 首页左侧任务可以拖动改变顺序,基建换班设置中设施顺序同理
- 主界面和设置中的配置更改通常会自动保存,标有 `*` 号或 `(仅一次)` 的选项,以及通过右键单击复选框得到的半选开关都会在 MAA 重启后重置。
- 所有点击操作,都是点击按钮内随机位置,并模拟泊松分布(按钮中心的点击概率最高,距离中心越远,点击概率越低)。
- 底层算法纯 C++ 开发,并设计了多重缓存技术,最大限度降低 CPU 和内存占用。
- 软件支持自动更新 ✿✿ ヽ(°▽°) ✿ ,推荐非杠精的同学使用公测版,一般来说更新快且 bug 少。(什么 MIUI (╯‵□′)╯︵┻━┻
- 如果新版本自动下载失败,可手动下载 OTA 压缩包后直接放到 MAA 目录下,会自动更新的。
- 在 Windows 版本中MAA 目录下 `config` 文件夹中的 `gui.json` 记录了所有设置,如果下载了新的完整包可以将此文件夹复制到新的 MAA 目录下。
v4.13.0 以降、開始前/終了後スクリプトの設定をサポートしており、タスクの前後でバッチファイルを自動実行できます。入力欄にはバッチファイル(`*.bat`)の絶対パスまたは相対パスを入力する必要があります
## 設定移行
Windows 版では、MAA のすべての設定は `config` フォルダ内の `gui.json` に保存されています。このフォルダを移行することで MAA のすべての設定を移行できます。
## その他の説明
- ホーム左側のタスクはドラッグして順序を変更でき、基地シフト設定の施設順序も同様です。
- すべてのクリック操作は、ボタン内のランダムな位置をクリックし、ポアソン分布をシミュレートします(ボタン中心のクリック確率が最も高く、中心から離れるほどクリック確率は低くなります)。
- 底層アルゴリズムは純粋な C++ で開発され、多重キャッシュ技術を設計して CPU とメモリ使用量を最大限に削減しています。
- ソフトウェアは自動更新をサポートしています ✿✿ ヽ(°▽°) ✿ 。揚げ足取りでない方にはベータ版の使用を推奨します。一般的に更新が早く、バグも少ないです。(なんだって MIUI (╯‵□′)╯︵┻━┻
- 新バージョンの自動ダウンロードが失敗した場合、手動で OTA 圧縮パッケージをダウンロードして MAA ディレクトリに直接置くと、自動更新されます。

View File

@@ -2,24 +2,22 @@
order: 8
icon: solar:streets-map-point-linear
---
# 生息演算
::: important Translation Required
This page is outdated and maybe still in Simplified Chinese. Translation is needed.
:::
現在、生息演算のサポートはまだ初期段階にあり、自動攻略は推奨されず、現段階では安定性を保証できません。
目前生息演算的支持仍处于早期阶段,暂不推荐无人值守,现阶段无法保证稳定性。
## デフォルトモード
## 默认模式
1. 生息演算のメイン画面でタスクを開始する必要があります(ナビゲーションはまだ未実装)
2. すでにセーブデータがある状況では使用できません(既存のセーブデータを削除してください)
3. 生息演算の編成にオペレーターがいる状況では使用できません(生息演算の現在の編成をクリアしてください、特にウェーブを完了した後)
1. 需要在生息演算主界面开始任务(导航还没写)
2. 不能在已经有存档的情况下使用(删除现有存档即可)
3. 不能在生息演算的编队中有干员的情况下使用(把生息演算中的当前编队清空即可,特别是打完浪潮之后)
## 製造でポイント稼ぎ
## 制造刷点数
1. 需要在进入生息演算中能看到驻扎地的页面开始
2. 若未填写道具名称,则默认制造荧光棒
3. 前提条件:当前为结算后的第一天,且后续三天没有敌袭进入驻扎地
4. 如果能制造的数量刚好是 99 的倍数会卡住,在存档前可以先用掉一点,这个之后再修
1. 生息演算内で駐屯地が見えるページから開始する必要があります
2. アイテム名が未記入の場合、デフォルトでグローライトを製造します
3. 前提条件現在が決算後の初日で、その後3日間敵襲による駐屯地への侵入がないこと
4. 製造可能数量がちょうど99の倍数の場合、フリーズします。セーブ前に少し使用することができます。これは後で修正予定です

Some files were not shown because too many files have changed in this diff Show More