|
|
@ -143,9 +143,10 @@ namespace Networking.Server |
|
|
|
newClient.Name = loginMsg.Name; |
|
|
|
newClient.conn = msg.conn; |
|
|
|
|
|
|
|
ConnectedClients.ForEach(p => p.conn.Send(LoginProtocols.OtherClientConnected, new LoginProtocols.LoginMsg(newClient.Name, newClient.Color, newClient.characterAnimal))); |
|
|
|
|
|
|
|
|
|
|
|
ConnectedClients.Add(newClient); |
|
|
|
ConnectedClients.ForEach(p => p.conn.Send(LoginProtocols.OtherClientConnected, new LoginProtocols.LoginMsg(newClient.Name, newClient.Color, newClient.characterAnimal))); |
|
|
|
PotentialClients.RemoveAll(p => p == newClient.conn); |
|
|
|
PotentialClients.ForEach(p => p.Send(LoginProtocols.OtherClientConnected, new LoginProtocols.LoginMsg(newClient.Name, newClient.Color, newClient.characterAnimal))); |
|
|
|
|
|
|
@ -153,7 +154,7 @@ namespace Networking.Server |
|
|
|
OnClientsChange.Invoke(ConnectedClients); |
|
|
|
newClient.SendInventory(); |
|
|
|
newClient.SendLives(); |
|
|
|
newClient.ChangeScene("WaitScene"); |
|
|
|
newClient.ChangeScene("LobbyWait"); |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|