- server asks the clients whether they're ready to start a round, giving some time to load the selected sub before the round starts
- fixed joining clients not being informed about vote status or voting being enabled
This commit is contained in:
@@ -487,6 +487,17 @@ namespace Barotrauma.Networking
|
||||
|
||||
switch (packetType)
|
||||
{
|
||||
case (byte)PacketTypes.CanStartGame:
|
||||
string subName = inc.ReadString();
|
||||
string subHash = inc.ReadString();
|
||||
|
||||
if (GameMain.NetLobbyScreen.TrySelectSub(subName,subHash))
|
||||
{
|
||||
NetOutgoingMessage readyToStartMsg = client.CreateMessage();
|
||||
readyToStartMsg.Write((byte)PacketTypes.StartGame);
|
||||
client.SendMessage(readyToStartMsg, NetDeliveryMethod.ReliableUnordered);
|
||||
}
|
||||
break;
|
||||
case (byte)PacketTypes.StartGame:
|
||||
if (Screen.Selected == GameMain.GameScreen) continue;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user