diff --git a/Assets/Mirror/Runtime/NetworkClient.cs b/Assets/Mirror/Runtime/NetworkClient.cs index 04a9596e3..716281ca0 100644 --- a/Assets/Mirror/Runtime/NetworkClient.cs +++ b/Assets/Mirror/Runtime/NetworkClient.cs @@ -220,33 +220,6 @@ public static void RegisterHandler(Action handler, bool requireAuthenticat RegisterHandler((NetworkConnection _, T value) => { handler(value); }, requireAuthentication); } - /// - /// Replaces a handler for a particular message type. - /// See also RegisterHandler(T)(Action(NetworkConnection, T), bool) - /// - /// Message type - /// Function handler which will be invoked when this message type is received. - /// True if the message requires an authenticated connection - public static void ReplaceHandler(Action handler, bool requireAuthentication = true) - where T : struct, NetworkMessage - { - int msgType = MessagePacker.GetId(); - handlers[msgType] = MessagePacker.MessageHandler(handler, requireAuthentication); - } - - /// - /// Replaces a handler for a particular message type. - /// See also RegisterHandler(T)(Action(NetworkConnection, T), bool) - /// - /// Message type - /// Function handler which will be invoked when this message type is received. - /// True if the message requires an authenticated connection - public static void ReplaceHandler(Action handler, bool requireAuthentication = true) - where T : struct, NetworkMessage - { - ReplaceHandler((NetworkConnection _, T value) => { handler(value); }, requireAuthentication); - } - /// /// Unregisters a network message handler. ///