Files
FunConnect/README.md
FunMC 09470c0465 feat: 新增移动客户端(iOS + Android)
- 新增 mobile/ 项目:React Native + Expo
- 5个核心页面:连接服务器、房间列表、创建房间、加入房间、设置
- Tab 导航 + Minecraft 风格深色 UI
- 房间搜索/筛选(名称、房间号、房主、版本类型)
- 15秒自动刷新房间列表
- 设置持久化(AsyncStorage)
- EAS Build 配置(云端构建 iOS/Android)
- 完整 README 含构建指南
- 更新顶层 README 为三项目全平台架构
2026-02-23 08:08:46 +08:00

102 lines
3.7 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# FunConnect - Minecraft 联机平台
一个支持多节点中继的 Minecraft 联机平台让玩家无需公网IP即可轻松联机。
本仓库包含 **三个独立项目**,覆盖全平台客户端和服务端。
## 支持平台
| 平台 | 类型 | 项目 |
|------|------|------|
| **Windows** | 桌面客户端 (NSIS 安装包) | `client/` |
| **macOS** | 桌面客户端 (DMG, x64/arm64) | `client/` |
| **Linux** | 桌面客户端 (AppImage/deb) | `client/` |
| **iOS** | 移动客户端 | `mobile/` |
| **Android** | 移动客户端 (APK/AAB) | `mobile/` |
| **Ubuntu** | 中继服务器 + Web 管理面板 | `server/` |
## 项目结构
```
FunConnect/
├── server/ # 服务端(中继服务器 + Web 管理面板 + 部署脚本)
├── client/ # 桌面客户端Electron: Windows / macOS / Linux
└── mobile/ # 移动客户端React Native + Expo: iOS / Android
```
## 服务端 (`server/`)
中继服务器 + Web 管理面板,部署在 Ubuntu 服务器上。
- **TCP 中继引擎** - 转发 Minecraft 流量,支持 Java 版和基岩版
- **多节点集群** - 主节点 + 工作节点架构,水平扩展
- **房间系统** - 创建/加入/密码保护/过期清理
- **流量监控** - 实时统计各房间流量
- **Token 认证** - 保护写操作 API
- **Web 管理面板** - React + TailwindCSS 可视化管理
- **一键部署** - Ubuntu 自动安装脚本 + systemd 服务
```bash
cd server && npm install && cp .env.example .env && npm run dev
```
📖 [server/README.md](server/README.md) · 📦 [部署教程 DEPLOY.md](server/DEPLOY.md)
## 桌面客户端 (`client/`)
Electron 跨平台桌面客户端,支持 Windows / macOS / Linux。
- **本地代理** - 自动建立 TCP 代理MC 添加 `127.0.0.1:25566` 即可联机
- **设置持久化** - 记住服务器地址、玩家名等偏好
- **系统托盘** - 最小化到托盘后台运行
```bash
cd client && npm install && npm run dev # 开发
npm run dist:win # 打包 Windows
npm run dist:mac # 打包 macOS
npm run dist:linux # 打包 Linux
```
📖 [client/README.md](client/README.md)
## 移动客户端 (`mobile/`)
React Native + Expo 移动客户端,支持 iOS / Android。
- **房间管理** - 浏览/搜索/创建/加入联机房间
- **设置持久化** - 记住服务器地址和玩家名
- **深色 UI** - Minecraft 风格暗色主题
```bash
cd mobile && npm install && npm start # 开发Expo
eas build --platform android --profile preview # 构建 Android APK
eas build --platform ios --profile production # 构建 iOS
```
📖 [mobile/README.md](mobile/README.md)
## 架构
```
┌──────────────────┐
│ 桌面客户端 │ Windows / macOS / Linux
│ Electron │ TCP 本地代理
│ client/ │─────────┐
└──────────────────┘ │
┌──────────────────┐ ┌──────────────────────────┐
│ 移动客户端 │ │ 中继服务器 (Ubuntu) │
│ React Native │──►│ TCP 中继 + REST API │
│ mobile/ │ │ Web 管理面板 (React) │
└──────────────────┘ └──────────────────────────┘
┌──────────────────┐ │
│ Minecraft │─────────┘
│ 游戏客户端 │ TCP 直连中继
└──────────────────┘
```
## License
MIT