diff options
-rw-r--r-- | Client/Assembly-CSharp/AmongUsClient.cs | 6 | ||||
-rw-r--r-- | Client/Assembly-CSharp/Assembly-CSharp.csproj.user | 10 | ||||
-rw-r--r-- | Client/Assembly-CSharp/FindAGameManager.cs | 1 | ||||
-rw-r--r-- | Client/Assembly-CSharp/GameStartManager.cs | 4 | ||||
-rw-r--r-- | Client/Assembly-CSharp/InnerNet/GameListing.cs | 1 | ||||
-rw-r--r-- | Client/Assembly-CSharp/InnerNet/InnerNetClient.cs | 316 | ||||
-rw-r--r-- | Client/Assembly-CSharp/InnerNet/InnerNetServer.cs | 10 | ||||
-rw-r--r-- | Client/Assembly-CSharp/IntroCutscene.cs | 7 | ||||
-rw-r--r-- | Client/Assembly-CSharp/MatchMakerGameButton.cs | 2 | ||||
-rw-r--r-- | Client/Assembly-CSharp/Msg.cs | 87 | ||||
-rw-r--r-- | Client/Assembly-CSharp/obj/Debug/Assembly-CSharp.csproj.CoreCompileInputs.cache | 2 | ||||
-rw-r--r-- | Client/Assembly-CSharp/obj/Debug/Assembly-CSharp.csprojAssemblyReference.cache | bin | 307687 -> 367844 bytes | |||
-rw-r--r-- | Client/Assembly-CSharp/obj/Debug/DesignTimeResolveAssemblyReferencesInput.cache | bin | 7691 -> 7117 bytes |
13 files changed, 276 insertions, 170 deletions
diff --git a/Client/Assembly-CSharp/AmongUsClient.cs b/Client/Assembly-CSharp/AmongUsClient.cs index 5a83263..433144e 100644 --- a/Client/Assembly-CSharp/AmongUsClient.cs +++ b/Client/Assembly-CSharp/AmongUsClient.cs @@ -82,6 +82,7 @@ public class AmongUsClient : InnerNetClient SceneManager.LoadScene(this.MainMenuScene); } + // 收到游戏房间数据后的处理 protected override void OnGetGameList(int totalGames, List<GameListing> availableGames) { for (int i = 0; i < this.GameListHandlers.Count; i++) @@ -100,6 +101,10 @@ public class AmongUsClient : InnerNetClient { } + /// <summary>
+ ///
+ /// </summary>
+ /// <param name="gameIdString"></param> protected override void OnWaitForHost(string gameIdString) { if (this.GameState != InnerNetClient.GameStates.Joined) @@ -112,6 +117,7 @@ public class AmongUsClient : InnerNetClient } } + // 开始游戏后的处理 protected override void OnStartGame() { Debug.Log("Received game start: " + base.AmHost.ToString()); diff --git a/Client/Assembly-CSharp/Assembly-CSharp.csproj.user b/Client/Assembly-CSharp/Assembly-CSharp.csproj.user index 8e510e4..e1af94b 100644 --- a/Client/Assembly-CSharp/Assembly-CSharp.csproj.user +++ b/Client/Assembly-CSharp/Assembly-CSharp.csproj.user @@ -1,6 +1,6 @@ -<?xml version="1.0" encoding="utf-8"?> -<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> - <PropertyGroup> - <ReferencePath>D:\Download\depotdownloader-2.4.0-prerelease\depots\945361\5946232\Among Us_Data\Managed\</ReferencePath> - </PropertyGroup> +<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+ <PropertyGroup>
+ <ReferencePath>D:\Download\depotdownloader-2.4.0-prerelease\depots\945361\5946232\Among Us_Data\Managed\;D:\UnityProject\AmongUs\Game\Among Us_Data\Managed\</ReferencePath>
+ </PropertyGroup>
</Project>
\ No newline at end of file diff --git a/Client/Assembly-CSharp/FindAGameManager.cs b/Client/Assembly-CSharp/FindAGameManager.cs index b428861..085bc8e 100644 --- a/Client/Assembly-CSharp/FindAGameManager.cs +++ b/Client/Assembly-CSharp/FindAGameManager.cs @@ -91,6 +91,7 @@ public class FindAGameManager : DestroyableSingleton<FindAGameManager>, IGameLis base.OnDestroy(); } + // 收到游戏房间后的处理 public void HandleList(int totalGames, List<GameListing> availableGames) { Debug.Log(string.Format("TotalGames: {0}\tAvailable: {1}", totalGames, availableGames.Count)); diff --git a/Client/Assembly-CSharp/GameStartManager.cs b/Client/Assembly-CSharp/GameStartManager.cs index 69f1967..f92e8ba 100644 --- a/Client/Assembly-CSharp/GameStartManager.cs +++ b/Client/Assembly-CSharp/GameStartManager.cs @@ -108,7 +108,7 @@ public class GameStartManager : DestroyableSingleton<GameStartManager>, IDisconn } } } - if (AmongUsClient.Instance.AmHost) + if (AmongUsClient.Instance.AmHost) // host来控制开始游戏 { if (this.startState == GameStartManager.StartingStates.Countdown) { @@ -122,7 +122,7 @@ public class GameStartManager : DestroyableSingleton<GameStartManager>, IDisconn } if (num2 <= 0) { - this.FinallyBegin(); + this.FinallyBegin(); // 开始游戏 return; } } diff --git a/Client/Assembly-CSharp/InnerNet/GameListing.cs b/Client/Assembly-CSharp/InnerNet/GameListing.cs index d10ea34..8ad38a8 100644 --- a/Client/Assembly-CSharp/InnerNet/GameListing.cs +++ b/Client/Assembly-CSharp/InnerNet/GameListing.cs @@ -2,6 +2,7 @@ namespace InnerNet { + // 游戏房间数据 [Serializable] public struct GameListing { diff --git a/Client/Assembly-CSharp/InnerNet/InnerNetClient.cs b/Client/Assembly-CSharp/InnerNet/InnerNetClient.cs index 5806605..30121eb 100644 --- a/Client/Assembly-CSharp/InnerNet/InnerNetClient.cs +++ b/Client/Assembly-CSharp/InnerNet/InnerNetClient.cs @@ -588,6 +588,7 @@ namespace InnerNet } // 加入游戏 + // MsgWrite:JoinGame public void JoinGame() { this.ClientId = -1; @@ -617,7 +618,7 @@ namespace InnerNet return this.IsGameStarted || this.AmHost; } - // 踢玩家 + // 踢玩家 MsgWrite:KickPlayer public void KickPlayer(int clientId, bool ban) { if (!this.AmHost) @@ -651,6 +652,7 @@ namespace InnerNet msg.Recycle(); } + // MsgWrite:RemovePlayer , 移除玩家 protected void SendLateRejection(int targetId, DisconnectReasons reason) { MessageWriter messageWriter = MessageWriter.Get(SendOption.Reliable); @@ -688,6 +690,7 @@ namespace InnerNet clientData.IsReady = true; } + // MsgWrite:StartGame protected void SendStartGame() { MessageWriter messageWriter = MessageWriter.Get(SendOption.Reliable); @@ -698,17 +701,19 @@ namespace InnerNet messageWriter.Recycle(); } + // MsgWrite:GetGameList , 获得游戏房间列表 public void RequestGameList(bool includePrivate, IBytesSerializable settings) { MessageWriter messageWriter = MessageWriter.Get(SendOption.Reliable); - messageWriter.StartMessage(9); - messageWriter.Write(includePrivate); + messageWriter.StartMessage(9); // GetGameList
+ messageWriter.Write(includePrivate); messageWriter.WriteBytesAndSize(settings.ToBytes()); messageWriter.EndMessage(); this.SendOrDisconnect(messageWriter); messageWriter.Recycle(); } + // MsgWrite:AlterGame , 切换房间的public和private public void ChangeGamePublic(bool isPublic) { if (this.AmHost) @@ -796,20 +801,65 @@ namespace InnerNet return; } break; - case 1: - goto IL_2F5; - case (int)TagAlias.StartGame: - this.GameState = InnerNetClient.GameStates.Started; - obj = this.Dispatcher; - lock (obj) + case Tags.JoinGame: //MsgRead:JoinGame + goto IL_2F5;
+ IL_2F5:
+ int num8 = reader.ReadInt32(); // 如果加入失败,gameId存失败原因
+ DisconnectReasons disconnectReasons = (DisconnectReasons)num8;
+ if (InnerNetClient.disconnectReasons.Contains(disconnectReasons))
+ {
+ if (disconnectReasons == DisconnectReasons.Custom)
+ {
+ this.LastCustomDisconnect = reader.ReadString();
+ }
+ this.GameId = -1;
+ this.EnqueueDisconnect(disconnectReasons, null);
+ return;
+ }
+ if (this.GameId == num8)
+ {
+ int num9 = reader.ReadInt32();
+ bool amHost = this.AmHost;
+ this.HostId = reader.ReadInt32();
+ ClientData client = this.GetOrCreateClient(num9);
+ Debug.Log(string.Format("Player {0} joined", num9));
+ obj = this.Dispatcher;
+ lock (obj)
+ {
+ this.Dispatcher.Add(delegate
+ {
+ // 某个玩家加入了本局
+ this.OnPlayerJoined(client);
+ });
+ }
+ if (!this.AmHost || amHost)
+ {
+ return;
+ }
+ obj = this.Dispatcher;
+ lock (obj)
+ {
+ this.Dispatcher.Add(delegate
+ {
+ this.OnBecomeHost();
+ });
+ return;
+ }
+ }
+ this.EnqueueDisconnect(DisconnectReasons.IncorrectGame, null);
+ return;
+ case Tags.StartGame: // MsgRead:StartGame + this.GameState = InnerNetClient.GameStates.Started; + obj = this.Dispatcher; + lock (obj) + { + this.Dispatcher.Add(delegate { - this.Dispatcher.Add(delegate - { - this.OnStartGame(); - }); - return; - } - goto IL_675; + this.OnStartGame(); + }); + return; + } + goto IL_675; case (int)TagAlias.Disconnect: { DisconnectReasons reason3 = DisconnectReasons.ServerRequest; @@ -820,7 +870,7 @@ namespace InnerNet this.EnqueueDisconnect(reason3, null); return; } - case Tags.RemovePlayer: + case Tags.RemovePlayer: // MsgRead:RemovePlayer , 这里不知道为什么没处理 break; case (int)TagAlias.GameData: case (int)TagAlias.GameDataTo: // 把这类消息存在队列里,主线程后续调用 @@ -866,9 +916,33 @@ namespace InnerNet } return; } - case (int)TagAlias.JoinGame: - goto IL_235; - case (int)TagAlias.Gameover: + case (int)Tags.JoinedGame: // MsgRead:JoinedGame , 加入游戏成功的反馈,创建client实例 + goto IL_235;
+ IL_235:
+ int num6 = reader.ReadInt32();
+ if (this.GameId != num6 || this.GameState == InnerNetClient.GameStates.Joined)
+ {
+ return;
+ }
+ this.GameState = InnerNetClient.GameStates.Joined;
+ this.ClientId = reader.ReadInt32();
+ ClientData myClient = this.GetOrCreateClient(this.ClientId);
+ this.HostId = reader.ReadInt32();
+ int num7 = reader.ReadPackedInt32();
+ for (int i = 0; i < num7; i++)
+ {
+ this.GetOrCreateClient(reader.ReadPackedInt32());
+ }
+ obj = this.Dispatcher;
+ lock (obj)
+ {
+ this.Dispatcher.Add(delegate
+ {
+ this.OnGameJoined(InnerNetClient.IntToGameName(this.GameId), myClient);
+ });
+ return;
+ }
+ case Tags.EndGame: // MsgRead:EndGame , 结束游戏 { int num3 = reader.ReadInt32(); if (this.GameId == num3 && this.GameState != InnerNetClient.GameStates.Ended) @@ -894,15 +968,73 @@ namespace InnerNet } return; } - case 9: - goto IL_517; - case 10: - goto IL_5BC; - case 11: - goto IL_675; - case 12: - goto IL_1DD; - case 13: + case Tags.GetGameList: // MsgRead:GetGameList , 获得游戏房间列表 + goto IL_517;
+ IL_517:
+ int totalGames = reader.ReadPackedInt32();
+ List<GameListing> output = new List<GameListing>(); // 房间
+ while (reader.Position < reader.Length)
+ {
+ output.Add(new GameListing(reader.ReadInt32(), reader.ReadByte(), reader.ReadByte(), reader.ReadByte(), reader.ReadPackedInt32(), reader.ReadString()));
+ }
+ obj = this.Dispatcher;
+ lock (obj)
+ {
+ this.Dispatcher.Add(delegate
+ {
+ this.OnGetGameList(totalGames, output);
+ });
+ return;
+ }
+ case Tags.AlterGame: // MsgRead:AlterGame + goto IL_5BC;
+ IL_5BC:
+ int num10 = reader.ReadInt32();
+ if (this.GameId != num10)
+ {
+ return;
+ }
+ byte b = reader.ReadByte();
+ if (b == 1)
+ {
+ this.IsGamePublic = reader.ReadBoolean();
+ string str = "Alter Public = ";
+ bool flag = this.IsGamePublic;
+ Debug.Log(str + flag.ToString());
+ return;
+ }
+ Debug.Log("Alter unknown");
+ return;
+ case Tags.KickPlayer: // MsgRead:KickPlayer , 被踢掉 + goto IL_675;
+ IL_675:
+ int num11 = reader.ReadInt32();
+ if (this.GameId == num11 && reader.ReadPackedInt32() == this.ClientId)
+ {
+ this.EnqueueDisconnect(reader.ReadBoolean() ? DisconnectReasons.Banned : DisconnectReasons.Kicked, null);
+ return;
+ }
+ return;
+ case Tags.WaitForHost: // MsgRead:WaitForHost , 等主机进行操作 + goto IL_1DD;
+ IL_1DD:
+ int num5 = reader.ReadInt32();
+ if (this.GameId != num5)
+ {
+ return;
+ }
+ this.ClientId = reader.ReadInt32();
+ obj = this.Dispatcher;
+ lock (obj)
+ {
+ this.Dispatcher.Add(delegate
+ {
+ // 这里会弹出一个等待主机操作的界面
+ this.OnWaitForHost(InnerNetClient.IntToGameName(this.GameId));
+ });
+ return;
+ }
+ case Tags.Redirect: // MsgRead:Redirect { uint address = reader.ReadUInt32(); ushort port = reader.ReadUInt16(); @@ -948,132 +1080,6 @@ namespace InnerNet return; } return; - IL_1DD: - int num5 = reader.ReadInt32(); - if (this.GameId != num5) - { - return; - } - this.ClientId = reader.ReadInt32(); - obj = this.Dispatcher; - lock (obj) - { - this.Dispatcher.Add(delegate - { - this.OnWaitForHost(InnerNetClient.IntToGameName(this.GameId)); - }); - return; - } - IL_235: - int num6 = reader.ReadInt32(); - if (this.GameId != num6 || this.GameState == InnerNetClient.GameStates.Joined) - { - return; - } - this.GameState = InnerNetClient.GameStates.Joined; - this.ClientId = reader.ReadInt32(); - ClientData myClient = this.GetOrCreateClient(this.ClientId); - this.HostId = reader.ReadInt32(); - int num7 = reader.ReadPackedInt32(); - for (int i = 0; i < num7; i++) - { - this.GetOrCreateClient(reader.ReadPackedInt32()); - } - obj = this.Dispatcher; - lock (obj) - { - this.Dispatcher.Add(delegate - { - this.OnGameJoined(InnerNetClient.IntToGameName(this.GameId), myClient); - }); - return; - } - IL_2F5: // 同时处理join game和disconnect - int num8 = reader.ReadInt32(); - DisconnectReasons disconnectReasons = (DisconnectReasons)num8; - if (InnerNetClient.disconnectReasons.Contains(disconnectReasons)) - { - if (disconnectReasons == DisconnectReasons.Custom) - { - this.LastCustomDisconnect = reader.ReadString(); - } - this.GameId = -1; - this.EnqueueDisconnect(disconnectReasons, null); - return; - } - if (this.GameId == num8) - { - int num9 = reader.ReadInt32(); - bool amHost = this.AmHost; - this.HostId = reader.ReadInt32(); - ClientData client = this.GetOrCreateClient(num9); - Debug.Log(string.Format("Player {0} joined", num9)); - obj = this.Dispatcher; - lock (obj) - { - this.Dispatcher.Add(delegate - { - // 某个玩家加入了本局 - this.OnPlayerJoined(client); - }); - } - if (!this.AmHost || amHost) - { - return; - } - obj = this.Dispatcher; - lock (obj) - { - this.Dispatcher.Add(delegate - { - this.OnBecomeHost(); - }); - return; - } - } - this.EnqueueDisconnect(DisconnectReasons.IncorrectGame, null); - return; - IL_517: - int totalGames = reader.ReadPackedInt32(); - List<GameListing> output = new List<GameListing>(); - while (reader.Position < reader.Length) - { - output.Add(new GameListing(reader.ReadInt32(), reader.ReadByte(), reader.ReadByte(), reader.ReadByte(), reader.ReadPackedInt32(), reader.ReadString())); - } - obj = this.Dispatcher; - lock (obj) - { - this.Dispatcher.Add(delegate - { - this.OnGetGameList(totalGames, output); - }); - return; - } - IL_5BC: - int num10 = reader.ReadInt32(); - if (this.GameId != num10) - { - return; - } - byte b = reader.ReadByte(); - if (b == 1) - { - this.IsGamePublic = reader.ReadBoolean(); - string str = "Alter Public = "; - bool flag = this.IsGamePublic; - Debug.Log(str + flag.ToString()); - return; - } - Debug.Log("Alter unknown"); - return; - IL_675: - int num11 = reader.ReadInt32(); - if (this.GameId == num11 && reader.ReadPackedInt32() == this.ClientId) - { - this.EnqueueDisconnect(reader.ReadBoolean() ? DisconnectReasons.Banned : DisconnectReasons.Kicked, null); - return; - } - return; IL_70A: Debug.Log(string.Format("Bad tag {0} at {1}+{2}={3}: ", new object[] { diff --git a/Client/Assembly-CSharp/InnerNet/InnerNetServer.cs b/Client/Assembly-CSharp/InnerNet/InnerNetServer.cs index 3e09a4c..f0b37a1 100644 --- a/Client/Assembly-CSharp/InnerNet/InnerNetServer.cs +++ b/Client/Assembly-CSharp/InnerNet/InnerNetServer.cs @@ -264,7 +264,7 @@ namespace InnerNet return; } break; - case 3: // RemoveGame + case 3: // RemoveGame , MsgRead:RemoveGame if (reader.ReadInt32() == 32) { this.ClientDisconnect(client); @@ -333,7 +333,7 @@ namespace InnerNet } } - // 踢玩家 + // 踢玩家(断开它的连接) private void KickPlayer(int targetId, bool ban) { List<InnerNetServer.Player> clients = this.Clients; @@ -383,8 +383,8 @@ namespace InnerNet { MessageWriter messageWriter = MessageWriter.Get(SendOption.Reliable); messageWriter.StartMessage(1); - messageWriter.Write(6); - messageWriter.EndMessage(); + messageWriter.Write(6); // 6 = DisconnectReasons.Banned
+ messageWriter.EndMessage(); client.Connection.Send(messageWriter); messageWriter.Recycle(); return; @@ -452,6 +452,7 @@ namespace InnerNet } this.Clients.Add(client); client.LimboState = LimboStates.WaitingForHost; + // MsgWrite:WaitForHost MessageWriter messageWriter3 = MessageWriter.Get(SendOption.Reliable); try { @@ -634,6 +635,7 @@ namespace InnerNet this.Broadcast(msg, client); } + // MsgWrite:JoinedGame private void WriteJoinedMessage(InnerNetServer.Player client, MessageWriter msg, bool clear) { if (clear) diff --git a/Client/Assembly-CSharp/IntroCutscene.cs b/Client/Assembly-CSharp/IntroCutscene.cs index 3271c11..fca050a 100644 --- a/Client/Assembly-CSharp/IntroCutscene.cs +++ b/Client/Assembly-CSharp/IntroCutscene.cs @@ -1,6 +1,7 @@ using System; using System.Collections; using System.Collections.Generic; +using System.Runtime; using UnityEngine; public class IntroCutscene : MonoBehaviour @@ -77,7 +78,7 @@ public class IntroCutscene : MonoBehaviour int adjustedNumImpostors = PlayerControl.GameOptions.GetAdjustedNumImpostors(GameData.Instance.PlayerCount); if (adjustedNumImpostors == 1) { - this.ImpostorText.Text = DestroyableSingleton<TranslationController>.Instance.GetString(StringNames.NumImpostorsS, Array.Empty<object>()); + this.ImpostorText.Text = DestroyableSingleton<TranslationController>.Instance.GetString(StringNames.NumImpostorsS,/* Array.Empty<object>()*/null); } else { @@ -87,7 +88,7 @@ public class IntroCutscene : MonoBehaviour }); } this.BackgroundBar.material.SetColor("_Color", Palette.CrewmateBlue); - this.Title.Text = DestroyableSingleton<TranslationController>.Instance.GetString(StringNames.Crewmate, Array.Empty<object>()); + this.Title.Text = DestroyableSingleton<TranslationController>.Instance.GetString(StringNames.Crewmate, /*Array.Empty<object>()*/null); this.Title.Color = Palette.CrewmateBlue; for (int i = 0; i < yourTeam.Count; i++) { @@ -121,7 +122,7 @@ public class IntroCutscene : MonoBehaviour private void BeginImpostor(List<PlayerControl> yourTeam) { this.ImpostorText.gameObject.SetActive(false); - this.Title.Text = DestroyableSingleton<TranslationController>.Instance.GetString(StringNames.Impostor, Array.Empty<object>()); + this.Title.Text = DestroyableSingleton<TranslationController>.Instance.GetString(StringNames.Impostor, /*Array.Empty<object>()*/null); this.Title.Color = Palette.ImpostorRed; for (int i = 0; i < yourTeam.Count; i++) { diff --git a/Client/Assembly-CSharp/MatchMakerGameButton.cs b/Client/Assembly-CSharp/MatchMakerGameButton.cs index 64be6de..c330179 100644 --- a/Client/Assembly-CSharp/MatchMakerGameButton.cs +++ b/Client/Assembly-CSharp/MatchMakerGameButton.cs @@ -4,6 +4,7 @@ using InnerNet; using PowerTools; using UnityEngine; +// 游戏列表中单个游戏的入口按钮 public class MatchMakerGameButton : PoolableBehavior, IConnectButton { public TextRenderer NameText; @@ -49,6 +50,7 @@ public class MatchMakerGameButton : PoolableBehavior, IConnectButton this.connectIcon.GetComponent<SpriteRenderer>().sprite = null; } + // 根据收到的游戏列表设置按钮内容 public void SetGame(GameListing gameListing) { this.myListing = gameListing; diff --git a/Client/Assembly-CSharp/Msg.cs b/Client/Assembly-CSharp/Msg.cs index 5976a0e..c47fb63 100644 --- a/Client/Assembly-CSharp/Msg.cs +++ b/Client/Assembly-CSharp/Msg.cs @@ -2,11 +2,98 @@ 所有网络消息 ////////////////////////////////////////////// 不需要同步的消息 ////////////////////////////////////////////// +HostGame // 作为Host建房间 +{ + HostGame // 0 + gameSettings // 单局配置 +} + +JoinGame // 加入游戏 +{ + JoinGame + gameId // 如果加入失败,gameId存失败原因 +} + +StartGame // host玩家开始游戏 +{ + StartGame // 2 + gameId +} + +RemoveGame // 玩家退出游戏 +{ + gameId +} + +RemovePlayer // 如果在连接过程中出现错误(DisconnectReasons),移除某个玩家 +{ + RemovePlayer // 4 + gameId + clientId + reason // DisconnectReasons +} + +JoinedGame // 加入游戏, S2C,在InnerNetServer,用来分发局内玩家数据,是JoinGame的ACK +{ + JointedGame // 7 + gameId + clientId + hostId + clientCount + playerIdList // playerId,分配给每个玩家的clientId +} + EndGame // 本局结束 { + EndGame // 8 + gameId + endReason // 游戏结束原因 + showAd // 是否显示广告 +} + +GetGameList // 游戏房间数据 +{ + GetGameList // 9 + includePrivate // 是否包含私密房 + gameSearchOptions // 搜索条件 +} +AlterGame // 切换房间的public和private (只有主机可以) +{ + AlterGame // 10 + 1 // 未知 + gameId + isPublic +} + +KickPlayer_C2S // 踢玩家 +{ + KickPlayer // 11 + gameId + clientId + ban // 是否ban掉这个ip } +KickPlayer_S2C // 发给被踢玩家的消息 +{ + KickPlayer // 11 + gameId + clientId + ban +} + +WaitForHost // 等待主机玩家进一步操作(比如开始游戏) +{ + gameID + clientId +} + +Redirect // 游戏服务器推给所有玩家,切换连接的服务器IP和端口 +{ + Redirect // 13 + address + port +} ////////////////////////////////////////////// 高频率的同步消息 ////////////////////////////////////////////// // 对应 GameData(5)和GameDataTo(6) diff --git a/Client/Assembly-CSharp/obj/Debug/Assembly-CSharp.csproj.CoreCompileInputs.cache b/Client/Assembly-CSharp/obj/Debug/Assembly-CSharp.csproj.CoreCompileInputs.cache index e0b3b5f..484e09c 100644 --- a/Client/Assembly-CSharp/obj/Debug/Assembly-CSharp.csproj.CoreCompileInputs.cache +++ b/Client/Assembly-CSharp/obj/Debug/Assembly-CSharp.csproj.CoreCompileInputs.cache @@ -1 +1 @@ -36a668f4a9e0f3bfc026d9ff7da5880a4afbe3aa +cea92bb7656dcc91fb83232f4547ce2a8b82fc54
diff --git a/Client/Assembly-CSharp/obj/Debug/Assembly-CSharp.csprojAssemblyReference.cache b/Client/Assembly-CSharp/obj/Debug/Assembly-CSharp.csprojAssemblyReference.cache Binary files differindex 60cbbd2..8d90cd0 100644 --- a/Client/Assembly-CSharp/obj/Debug/Assembly-CSharp.csprojAssemblyReference.cache +++ b/Client/Assembly-CSharp/obj/Debug/Assembly-CSharp.csprojAssemblyReference.cache diff --git a/Client/Assembly-CSharp/obj/Debug/DesignTimeResolveAssemblyReferencesInput.cache b/Client/Assembly-CSharp/obj/Debug/DesignTimeResolveAssemblyReferencesInput.cache Binary files differindex 18bc980..d991f50 100644 --- a/Client/Assembly-CSharp/obj/Debug/DesignTimeResolveAssemblyReferencesInput.cache +++ b/Client/Assembly-CSharp/obj/Debug/DesignTimeResolveAssemblyReferencesInput.cache |