mirror of
https://github.com/LHY0125/Gobang-Game.git
synced 2026-05-10 02:19:46 +08:00
feat(network): 集成ENet库并实现局域网联机对战功能
- 添加ENet库作为网络通信基础,替换原有的原生Socket实现 - 扩展游戏模式支持局域网联机对战(PvP网络模式) - 重构网络状态结构以适配ENet的Host/Peer模型 - 在图形界面中添加网络对战菜单,支持创建房间和加入房间 - 实现网络消息的发送与接收,包括落子、断开连接等消息类型 - 为网络对战添加定时器轮询机制,实时处理网络事件 - 更新构建系统以编译和链接ENet库
This commit is contained in:
+21
@@ -0,0 +1,21 @@
|
||||
on: [push, pull_request]
|
||||
|
||||
name: CMake
|
||||
|
||||
jobs:
|
||||
cmake-build:
|
||||
name: CMake ${{ matrix.os }} ${{ matrix.build_type }}
|
||||
runs-on: ${{ matrix.os }}
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
os: ["ubuntu-latest", "windows-latest", "macos-latest"]
|
||||
build_type: ["Debug", "Release"]
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
|
||||
- name: Configure CMake
|
||||
run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{ matrix.build_type }}
|
||||
|
||||
- name: Build
|
||||
run: cmake --build ${{github.workspace}}/build --config ${{ matrix.build_type }}
|
||||
Reference in New Issue
Block a user