public void LogOutgoingPacket(NecClient client, NecPacket packet) { if (_setting.LogOutgoingPackets) { NecLogPacket logPacket = new NecLogPacket(client, packet, NecLogType.Out); Packet(logPacket); } }
public void LogOutgoingPacket(NecClient client, NecPacket packet, ServerType serverType) { if (_setting.LogOutgoingPackets) { NecLogPacket logPacket = new NecLogPacket(client.Identity, packet, NecLogType.PacketOut, serverType); WritePacket(logPacket); } }
public void LogUnknownIncomingPacket(NecClient client, NecPacket packet, string identity) { if (_setting.LogUnknownIncomingPackets) { NecLogPacket logPacket = new NecLogPacket(client, packet, NecLogType.Unhandled, identity); Packet(logPacket); } }
public void LogIncomingPacket(NecClient client, NecPacket packet, ServerType serverType) { if (_setting.logIncomingPackets) { NecLogPacket logPacket = new NecLogPacket(client.identity, packet, NecLogType.PacketIn, serverType); WritePacket(logPacket); } }
public void LogUnknownIncomingPacket(NecClient client, NecPacket packet, ServerType serverType) { if (_setting.LogUnknownIncomingPackets) { NecLogPacket logPacket = new NecLogPacket(client.Identity, packet, NecLogType.PacketUnhandled, serverType); WritePacket(logPacket); } }
public void LogOutgoingPacket(NecConnection connection, NecPacket packet, ServerType serverType) { NecClient client = connection.Client; if (client != null) { LogOutgoingPacket(client, packet, serverType); return; } if (!_setting.LogIncomingPackets) { return; } NecLogPacket logPacket = new NecLogPacket(connection.Identity, packet, NecLogType.PacketOut, serverType); WritePacket(logPacket); }
public void LogUnknownIncomingPacket(NecConnection connection, NecPacket packet, ServerType serverType) { NecClient client = connection.client; if (client != null) { LogUnknownIncomingPacket(client, packet, serverType); return; } if (!_setting.logIncomingPackets) { return; } NecLogPacket logPacket = new NecLogPacket(connection.identity, packet, NecLogType.PacketUnhandled, serverType); WritePacket(logPacket); }
private void WritePacket(NecLogPacket packet) { Write(LogLevel.Info, packet.ToLogText(), packet); }
public void Packet(NecLogPacket packet) { Write(LogLevel.Info, packet.LogType, packet.ToLogText()); }