mirror of
https://github.com/MirrorNetworking/Mirror.git
synced 2024-11-18 11:00:32 +00:00
Remove unused, obsolete private method
This commit is contained in:
parent
ec5434b087
commit
85faddfdd0
@ -215,29 +215,6 @@ internal static void ActivateLocalClientScene()
|
||||
}
|
||||
}
|
||||
|
||||
// this is like SendToReady - but it doesn't check the ready flag on the connection.
|
||||
// this is used for ObjectDestroy messages.
|
||||
[EditorBrowsable(EditorBrowsableState.Never), Obsolete("use SendToObservers<T> instead")]
|
||||
static bool SendToObservers(NetworkIdentity identity, short msgType, MessageBase msg)
|
||||
{
|
||||
if (LogFilter.Debug) Debug.Log("Server.SendToObservers id:" + msgType);
|
||||
|
||||
if (identity != null && identity.observers != null)
|
||||
{
|
||||
// pack message into byte[] once
|
||||
byte[] bytes = MessagePacker.PackMessage((ushort)msgType, msg);
|
||||
|
||||
// send to all observers
|
||||
bool result = true;
|
||||
foreach (KeyValuePair<int, NetworkConnection> kvp in identity.observers)
|
||||
{
|
||||
result &= kvp.Value.Send(new ArraySegment<byte>(bytes));
|
||||
}
|
||||
return result;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
// this is like SendToReady - but it doesn't check the ready flag on the connection.
|
||||
// this is used for ObjectDestroy messages.
|
||||
static bool SendToObservers<T>(NetworkIdentity identity, T msg) where T: IMessageBase
|
||||
|
Loading…
Reference in New Issue
Block a user