From 048239cf7539a64202306db464db590d0bd4f400 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Franti=C5=A1ek=20Boh=C3=A1=C4=8Dek?= Date: Sat, 7 Jan 2023 12:49:30 +0100 Subject: [PATCH] feat(packets): add use partner skill packet --- .../Client/Battle/UseAOESkillPacket.cs | 2 +- .../Client/Battle/UsePartnerSkillPacket.cs | 36 +++++++++++++++++++ 2 files changed, 37 insertions(+), 1 deletion(-) create mode 100644 Packets/NosSmooth.Packets/Client/Battle/UsePartnerSkillPacket.cs diff --git a/Packets/NosSmooth.Packets/Client/Battle/UseAOESkillPacket.cs b/Packets/NosSmooth.Packets/Client/Battle/UseAOESkillPacket.cs index d939fff..c7a7202 100644 --- a/Packets/NosSmooth.Packets/Client/Battle/UseAOESkillPacket.cs +++ b/Packets/NosSmooth.Packets/Client/Battle/UseAOESkillPacket.cs @@ -13,7 +13,7 @@ namespace NosSmooth.Packets.Client.Battle; /// /// The id of the skill. /// The x coordinate where to target to. -/// The y coordinate where to targe to. +/// The y coordinate where to target to. [PacketHeader("u_as", PacketSource.Client)] [GenerateSerializer(true)] public record UseAOESkillPacket diff --git a/Packets/NosSmooth.Packets/Client/Battle/UsePartnerSkillPacket.cs b/Packets/NosSmooth.Packets/Client/Battle/UsePartnerSkillPacket.cs new file mode 100644 index 0000000..d7b5252 --- /dev/null +++ b/Packets/NosSmooth.Packets/Client/Battle/UsePartnerSkillPacket.cs @@ -0,0 +1,36 @@ +// +// UsePartnerSkillPacket.cs +// +// Copyright (c) František Boháček. All rights reserved. +// Licensed under the MIT license. See LICENSE file in the project root for full license information. + +using NosSmooth.Packets.Enums.Entities; +using NosSmooth.PacketSerializer.Abstractions.Attributes; + +namespace NosSmooth.Packets.Client.Battle; + +/// +/// Sent to use a pet skill. +/// +/// The pet skill id. +/// The target entity type. +/// The target id. +/// The x coordinate to target to, present if the skill is area skill. +/// The y coordinate to target to, present if the skill is area skill. +[PacketHeader("u_ps", PacketSource.Client)] +[GenerateSerializer(true)] +public record UsePartnerSkillPacket +( + [PacketIndex(0)] + long MateTransportId, + [PacketIndex(1)] + EntityType TargetEntityType, + [PacketIndex(2)] + long TargetId, + [PacketIndex(3)] + byte SkillSlot, + [PacketIndex(4, IsOptional = true)] + short? MapX, + [PacketIndex(5, IsOptional = true)] + short? MapY +) : IPacket; \ No newline at end of file -- 2.48.1