Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion docs/en/guide/maa.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,17 @@ In MAA, go to "Settings → Connection" and set, in order:
4. "MuMu Installation Path": `<ModAVD root>\mumu-shim`, for example `D:\ModAVD\mumu-shim`.
- MAA rejects the path if `shell\sdk\external_renderer_ipc.dll` is not under it.
- MAA may have filled in a real MuMu path from the registry when you ticked the option. Replace it with the one above.
5. Tick "MuMu Network Bridge Connection", click "Confirm" in the warning, then fill in "Instance Number" with the ModAVD instance number (0, 1, 2, ...: the number on the manager card).
5. Tick "MuMu Network Bridge Connection", click "Confirm" in the warning, then fill in "Instance Number" with the instance's console port, which is the connection address port minus 1: for `127.0.0.1:20041`, fill in `20040`.
- If you leave it off, MAA works out MuMu's instance number from the connection address port. The result is wrong and screenshots fail.
- The number on the manager card (0, 1, 2, ...) works too.
6. "Touch Mode": "MaaTouch (Experimental)".
7. "Connection address": `127.0.0.1:<port>`, the adb address shown on the manager card. The default is `20001 + 10 × number`; if you changed the port range of the root, use what the manager shows.
8. "ADB path": `<ModAVD root>\sdk\platform-tools\adb.exe`.

Filled in, it looks like this (MAA's connection settings are at the bottom right, in the Chinese interface: ModAVD in `D:\ModAVD`, instance 4; "Screenshot test" picks MumuExtras, 6 ms):

![MAA set up as MuMu, connected to ModAVD instance 4](/images/maa-mumu-shim.webp)

## Check that it works

After MAA connects:
Expand Down
7 changes: 6 additions & 1 deletion docs/guide/maa.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,17 @@ ModAVD 带一个 MuMu 兼容外壳,在 `<ModAVD 根目录>\mumu-shim\`。MAA
4. 「MuMu 安装路径」填 `<ModAVD 根目录>\mumu-shim`,例如 `D:\ModAVD\mumu-shim`。
- 路径下没有 `shell\sdk\external_renderer_ipc.dll` 时,MAA 会拒绝这个路径。
- 勾上截图增强时 MAA 可能已按注册表填了真 MuMu 的路径,改成上面这个。
5. 勾上「MuMu 网络桥接模式」,在警告里点「确认」,再填「实例编号」:ModAVD 里的实例编号(0、1、2……,就是管理器卡片上的编号)。
5. 勾上「MuMu 网络桥接模式」,在警告里点「确认」,再填「实例编号」:这台实例的控制台端口,就是连接地址的端口减 1,比如连接地址是 `127.0.0.1:20041`,就填 `20040`。
- 不勾的话,MAA 会按连接地址的端口去推 MuMu 的实例号,推出来是错的,截图会失败。
- 填管理器卡片上的编号(0、1、2……)也认。
6. 「触控模式」选「MaaTouch(实验功能)」。
7. 「连接地址」填 `127.0.0.1:<端口>`,就是管理器卡片上显示的 adb 地址。默认是 `20001 + 10 × 编号`;根目录改过端口段的,以管理器显示的为准。
8. 「ADB 路径」填 `<ModAVD 根目录>\sdk\platform-tools\adb.exe`。

填好以后大致是这样(右下角是 MAA 的连接设置:ModAVD 装在 `D:\ModAVD`,连 4 号实例;点「截图测试」,选中的是 MumuExtras,6 ms):

![MAA 按 MuMu 配,连 ModAVD 4 号实例](/images/maa-mumu-shim.webp)

## 确认生效

MAA 连接成功后:
Expand Down
Binary file added docs/public/images/maa-mumu-shim.webp
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
5 changes: 4 additions & 1 deletion scripts/i18n.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,10 +60,13 @@ def parse(path):


def resolve(page, target):
"""The page a link points to, relative to docs/; None for links to other sites."""
"""The page a link points to, relative to docs/; None for links to other sites and to files that are not pages."""
if re.match(r"^[a-z]+:", target):
return None
path = target.split("#")[0]
# Images and other files from docs/public are shared by both languages.
if re.search(r"\.(?!md$|html$)[A-Za-z0-9]+$", path):
return None
if not path:
return page
parts = [] if path.startswith("/") else page.split("/")[:-1]
Expand Down