PSO2SERVER/Server/Protocol/Handlers/0E-PartyHandler/0E-0C-QuestCounterHandler.cs
2024-11-27 18:05:53 +08:00

55 lines
2.1 KiB
C#

using System;
using PSO2SERVER.Models;
using PSO2SERVER.Protocol.Packets;
namespace PSO2SERVER.Protocol.Handlers
{
[PacketHandlerAttr(0x0E, 0x0C)]
class QuestDifficultyStartHandler : PacketHandler
{
// Go go maximum code duplication (for now)
public override void HandlePacket(Client context, byte flags, byte[] data, uint position, uint size)
{
var reader = new PacketReader(data, position, size);
var info = string.Format("[<--] 接收到的数据 (hex): {0}字节", data.Length);
Logger.WriteHex(info, data);
//QuestDefiniton def = new QuestDefiniton
//{
// dateOrSomething = "2024/09/21",
// needsToBeNonzero = 0x00000020,
// getsSetToWord = 0x0000000B,
// questNameString = 30010,
// playTime = (byte)QuestListPacket.EstimatedTime.Short,
// partyType = (byte)QuestListPacket.PartyType.SinglePartyQuest,
// difficulties = (byte)QuestListPacket.Difficulties.Normal | (byte)QuestListPacket.Difficulties.hard | (byte)QuestListPacket.Difficulties.VeryHard | (byte)QuestListPacket.Difficulties.SuperHard,
// requiredLevel = 1,
// // Not sure why but these need to be set for the quest to be enabled
// field_FF = 0xF1,
// field_101 = 1
//};
//QuestDifficultyPacket.QuestDifficulty diff = new QuestDifficultyPacket.QuestDifficulty
//{
// dateOrSomething = "2024/09/21",
// something = 0x20,
// something2 = 0x0B,
// questNameString = 30010,
// // These are likely bitfields
// something3 = 0x00030301
//};
//var quest = new Quest("arks_010120")
//{
// questDef = def
//};
//context.currentParty.currentQuest = quest;
//context.SendPacket(new SetQuestInfoPacket(def, context._account.AccountId));
//context.SendPacket(new QuestStartPacket(def, diff));
}
}
}