mirror of
https://github.com/MirrorNetworking/Mirror.git
synced 2024-11-18 02:50:32 +00:00
DisconnectAllConnections was renamed to DisconnectAllExternalConnections because that's what it does.
This commit is contained in:
parent
207501de4e
commit
f54f9c3599
@ -504,13 +504,13 @@ internal static bool GetNetworkIdentity(GameObject go, out NetworkIdentity ident
|
||||
/// <summary>Disconnect all connections, including the local connection.</summary>
|
||||
public static void DisconnectAll()
|
||||
{
|
||||
DisconnectAllConnections();
|
||||
DisconnectAllExternalConnections();
|
||||
localConnection = null;
|
||||
active = false;
|
||||
}
|
||||
|
||||
/// <summary>Disconnect all currently connected clients except the local connection.</summary>
|
||||
public static void DisconnectAllConnections()
|
||||
public static void DisconnectAllExternalConnections()
|
||||
{
|
||||
// disconnect and remove all connections.
|
||||
// we can not use foreach here because if
|
||||
@ -533,6 +533,9 @@ public static void DisconnectAllConnections()
|
||||
connections.Clear();
|
||||
}
|
||||
|
||||
[Obsolete("DisconnectAllConnections was renamed to DisconnectAllExternalConnections because that's what it does.")]
|
||||
public static void DisconnectAllConnections() => DisconnectAllExternalConnections();
|
||||
|
||||
// add/remove/replace player ///////////////////////////////////////////
|
||||
/// <summary>Called by server after AddPlayer message to add the player for the connection.</summary>
|
||||
// When a player is added for a connection, the client for that
|
||||
|
@ -364,7 +364,7 @@ public void DisconnectAllConnectionsTest()
|
||||
Assert.That(NetworkServer.connections.Count, Is.EqualTo(1));
|
||||
|
||||
// disconnect all connections
|
||||
NetworkServer.DisconnectAllConnections();
|
||||
NetworkServer.DisconnectAllExternalConnections();
|
||||
Assert.That(NetworkServer.connections.Count, Is.EqualTo(0));
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user