NetworkServer.SetAllClientsNotReady: simplify code

This commit is contained in:
vis2k 2019-04-05 22:00:15 +02:00
parent a526c39228
commit 7b550fdf4b

View File

@ -820,9 +820,8 @@ internal static void HideForConnection(NetworkIdentity identity, NetworkConnecti
// call this to make all the clients not ready, such as when changing levels. // call this to make all the clients not ready, such as when changing levels.
public static void SetAllClientsNotReady() public static void SetAllClientsNotReady()
{ {
foreach (KeyValuePair<int, NetworkConnection> kvp in connections) foreach (NetworkConnection conn in connections.Values)
{ {
NetworkConnection conn = kvp.Value;
SetClientNotReady(conn); SetClientNotReady(conn);
} }
} }