mirror of
https://github.com/Rundll86/Dog-Lynx-And-HCN.git
synced 2026-05-31 00:11:54 +08:00
feat(多人游戏): 实现多人游戏状态同步和单机/多人模式切换
添加多人游戏状态管理,包括连接状态和玩家名称同步 修改WorldManager和EntityBase以支持多人游戏逻辑 在Starter面板中实现单机和多人游戏启动功能
This commit is contained in:
@@ -20,9 +20,12 @@ static var stateColorMap = {
|
||||
ConnectionState.CONNECTED_CLIENT: Color.GREEN,
|
||||
}
|
||||
|
||||
static var isMultiplayer: bool = false
|
||||
static var state: ConnectionState = ConnectionState.DISCONNECTED
|
||||
static var playerName: String
|
||||
|
||||
static var connection: ENetMultiplayerPeer
|
||||
|
||||
static var maxPlayer: int = 10
|
||||
|
||||
static func isConnected():
|
||||
|
||||
Reference in New Issue
Block a user