diff --git a/Assets/Mirror/Runtime/NetworkServer.cs b/Assets/Mirror/Runtime/NetworkServer.cs index 175a72908..a0eead0e7 100644 --- a/Assets/Mirror/Runtime/NetworkServer.cs +++ b/Assets/Mirror/Runtime/NetworkServer.cs @@ -356,10 +356,10 @@ public static bool SendToReady(NetworkIdentity identity, short msgType, MessageB /// Message type. /// /// Message structure. - /// Send to observers including self.. + /// Send to observers including self.. /// Transport channel to use /// - public static bool SendToReady(NetworkIdentity identity, T msg, bool includeSelf = true, int channelId = Channels.DefaultReliable) where T : IMessageBase + public static bool SendToReady(NetworkIdentity identity, T msg, bool includeOwner = true, int channelId = Channels.DefaultReliable) where T : IMessageBase { if (LogFilter.Debug) Debug.Log("Server.SendToReady msgType:" + typeof(T)); @@ -380,9 +380,8 @@ public static bool SendToReady(NetworkIdentity identity, T msg, bool includeS int count = 0; foreach (KeyValuePair kvp in identity.observers) { - bool isSelf = kvp.Value == identity.connectionToClient; - if ((!isSelf || includeSelf) && - kvp.Value.isReady) + bool isOwner = kvp.Value == identity.connectionToClient; + if ((!isOwner || includeOwner) && kvp.Value.isReady) { count++;