Files
metin2-client/README.md
T
shenandshen 507e687867 feat: add MeshPort overlay networking, item actions window, and AVA2 client enhancements
- add MeshPort peer-to-peer overlay networking SDK, C++ integration, and Python bindings
- add item actions quick use/split/delete/lock overlay window (mt_item_actions)
- add shop name range and NPC name visibility settings to system display options
- support battlepass ticket activation and month validation in mt_battlepass
- support boss tracking teleport destination button in mt_bosses
- support asynchronous account registration cancellation and pending login cancellation
- update AVA2 item conversion for attr lock scrolls and battlepass tickets
- update .gitignore for local build outputs and caches
2026-10-16 01:29:57 -07:00

2.0 KiB

Metin2 原生客户端

40250 客户端的 macOS / Android 移植。SDL3 负责窗口与输入,Vulkan 负责 3D 和 UI 渲染;macOS 上通过 MoltenVK 使用 Metal。40250 的 C++ 逻辑、Python 2.7 脚本和 EPK 资源由 src/port 与 src/platform 提供。运行时不依赖 Godot。

macOS

需要 Rust 1.95+、protoc、CMake、SDL3、Vulkan loader、MoltenVK、glslc(第三方库均已随仓库提供源码,无需子模块):

./scripts/build_meshport.sh macos
cmake -S . -B build/release -DCMAKE_BUILD_TYPE=Release \
  -DMT_BUILD_NATIVE_RENDER=ON -DCMAKE_PREFIX_PATH=/opt/homebrew
cmake --build build/release --target mt_native_render -j8
./build/release/src/host/mt_native_render \
  --live-client "/path/to/40250/Client" --login-screen --width 1024 --height 768

MeshPort SDK 源码在 third_party/meshport,无需单独检出 MeshPort 项目。频道查询、登录、注册、地图/公会连接及 UDP 都在公共网络层判断:同网段直连,跨网段组网,使用 DHCP 动态 IP;远端连接验证成功后提示“组网成功”。私有配置与构建说明见 docs/MESHPORT.md。

详见 src/host/README.md。

Android

./android/build.sh              # 构建 APK;连着手机时自动安装并增量推送中文资源
./android/build.sh --launch     # 同上,完成后唤醒手机并启动

APK 由 SDLActivity、libSDL3.so 和 Vulkan 原生 libmain.so 组成。40250 Client 资源单独同步到应用数据目录(android/push-client.sh,只传有变化的文件);--live-server HOST:AUTH_PORT:GAME_PORT --login-screen 可连接服务器。构建与启动细节见 src/host/README.md。

测试

./script/port_gate.sh macos

port_gate.sh 构建并运行 40250 移植层的 C++ 测试。原生渲染验收入口是 scripts/native_mac_acceptance.mjs。历史迁移记录保留在 docs/PORT-PLAN.md;其中旧 Godot 路径已经退役。