PSO2SERVER/Server/Packets/PSOPackets/QuestStartPacket.cs

37 lines
955 B
C#
Raw Normal View History

2024-09-10 00:31:40 +08:00
using System;
using System.Runtime.InteropServices;
2024-09-10 01:13:20 +08:00
using PSO2SERVER.Models;
2024-09-10 00:31:40 +08:00
2024-09-10 01:13:20 +08:00
namespace PSO2SERVER.Packets.PSOPackets
2024-09-10 00:31:40 +08:00
{
class QuestStartPacket : Packet
{
QuestDefiniton data;
QuestDifficultyPacket.QuestDifficulty difficulty;
public QuestStartPacket(QuestDefiniton data, QuestDifficultyPacket.QuestDifficulty difficulty)
{
this.data = data;
this.difficulty = difficulty;
}
public override byte[] Build()
{
PacketWriter writer = new PacketWriter();
writer.Write(0x753A); // Unknown
writer.Write((int)0); // Unknown
writer.WriteStruct<QuestDefiniton>(data);
writer.WriteStruct<QuestDifficultyPacket.QuestDifficulty>(difficulty);
return writer.ToArray();
}
public override PacketHeader GetHeader()
{
return new PacketHeader(0xE, 0x31);
}
}
}