public void SendToServer(SendablePacket packet) { if (this.streamProv.ProviderType == L2NetMode.Sniffer || this.serverCrypt is NullCryptor) return; byte[] tmp = packet.GetPacket(); this.serverCrypt.EnCrypt(ref tmp, tmp.Length, 2, PacketType.ClientToGameserver); this.streamProv.ServerStreamOut.AddData(tmp); }
public void SendToClient(SendablePacket packet) { if (this.streamProv.ProviderType != L2NetMode.Proxy || this.clientCrypt is NullCryptor) return; byte[] tmp = packet.GetPacket(); this.clientCrypt.EnCrypt(ref tmp, tmp.Length, 2, PacketType.GameserverToClient); this.streamProv.ClientStreamOut.AddData(tmp); }
public void SendToClient(SendablePacket packet) { if (this.streamProv.ProviderType != L2NetMode.Proxy || this.clientCrypt is NullCryptor) { return; } byte[] tmp = packet.GetPacket(); this.clientCrypt.EnCrypt(ref tmp, tmp.Length, 2, PacketType.GameserverToClient); this.streamProv.ClientStreamOut.AddData(tmp); }
public void SendToServer(SendablePacket packet) { if (this.streamProv.ProviderType == L2NetMode.Sniffer || this.serverCrypt is NullCryptor) { return; } byte[] tmp = packet.GetPacket(); this.serverCrypt.EnCrypt(ref tmp, tmp.Length, 2, PacketType.ClientToGameserver); this.streamProv.ServerStreamOut.AddData(tmp); }