PSO2SERVER/Server/Protocol/Packets/11-ClientPacket/11-0E-ClientPongPacket.cs
2024-12-03 18:17:43 +08:00

37 lines
914 B
C#

using PSO2SERVER.Models;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace PSO2SERVER.Protocol.Packets
{
public class ClientPongPacket : Packet
{
private readonly ulong _clientTime;
private readonly long _serverTime;
public ClientPongPacket(ulong clientTime, long serverTime)
{
_clientTime = clientTime;
_serverTime = serverTime;
}
#region implemented abstract members of Packet
public override byte[] Build()
{
var pkt = new PacketWriter();
pkt.Write(_clientTime);
pkt.Write(_serverTime);
pkt.Write((uint)0);
return pkt.ToArray();
}
public override PacketHeader GetHeader()
{
return new PacketHeader(0x11, 0x0E, PacketFlags.None);
}
#endregion
}
}