PSO2SERVER/Server/Protocol/Packets/1F-DailyOrderPacket/1F-03-OrderListPacket.cs

40 lines
1014 B
C#

using PSO2SERVER.Models;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using static PSO2SERVER.Models.Orders;
namespace PSO2SERVER.Protocol.Packets
{
public class OrderListPacket : Packet
{
public ObjectHeader user { get; set; } = new ObjectHeader();
public ClientOrder[] orders { get; set; } = new ClientOrder[100];
public uint unk1 { get; set; }
public uint unk2 { get; set; }
public OrderListPacket()
{
}
#region implemented abstract members of Packet
public override byte[] Build()
{
var pkt = new PacketWriter();
pkt.WriteObjectHeader(user);
pkt.WriteStructArray(orders);
pkt.Write(unk1);
pkt.Write(unk2);
return pkt.ToArray();
}
public override PacketHeader GetHeader()
{
return new PacketHeader(0x1F, 0x03, PacketFlags.None);
}
#endregion
}
}