Skip to content

Commit 3bdfcfb

Browse files
erwan-jolyclaude
andauthored
feat: add Qnamli2Packet and ServerPackets.Player.BpmPacket (17.5.0) (#453)
- `qnamli2 100 #rl 1646 13 2514 Gladi` — new class, mirrors QnamliPacket with an extra trailing string. - `bpm 0 0 0` server-side — compact 3-byte marker, distinct from the existing client-side BpmPacket that ships the full quest list. Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
1 parent ef78e9e commit 3bdfcfb

4 files changed

Lines changed: 71 additions & 1 deletion

File tree

documentation/DocumentationTest.PacketsDocumentation.verified.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -396,6 +396,7 @@
396396

397397
### Player
398398
- [bn](../src/NosCore.Packets/ServerPackets/Player/BnPacket.cs) *InGame*
399+
- [bpm](../src/NosCore.Packets/ServerPackets/Player/BpmPacket.cs) *InGame*
399400
- [c_info](../src/NosCore.Packets/ServerPackets/Player/CInfoPacket.cs) *InGame*
400401
- [c_info_reset](../src/NosCore.Packets/ServerPackets/Player/CInfoResetPacket.cs) *InGame*
401402
- [c_mode](../src/NosCore.Packets/ServerPackets/Player/CModePacket.cs) *InGame*
@@ -429,6 +430,7 @@
429430
- [gp](../src/NosCore.Packets/ServerPackets/Portals/GpPacket.cs) *InGame*
430431

431432
### Quest
433+
- [qnamli2](../src/NosCore.Packets/ServerPackets/Quest/Qnamli2Packet.cs) *InGame*
432434
- [qnamli](../src/NosCore.Packets/ServerPackets/Quest/QnamliPacket.cs) *InGame*
433435
- [qr](../src/NosCore.Packets/ServerPackets/Quest/QrPacket.cs) *InGame*
434436
- [qsti](../src/NosCore.Packets/ServerPackets/Quest/QstiPacket.cs) *InGame*

src/NosCore.Packets/NosCore.Packets.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
<RepositoryUrl>https://github.com/NosCoreIO/NosCore.Packets.git</RepositoryUrl>
1313
<PackageIconUrl></PackageIconUrl>
1414
<PackageTags>nostale, noscore, chickenapi, nostale private server source, nostale emulator</PackageTags>
15-
<Version>17.4.0</Version>
15+
<Version>17.5.0</Version>
1616
<PackageRequireLicenseAcceptance>false</PackageRequireLicenseAcceptance>
1717
<Description>NosCore's Packets (Nostale packets) defined over classes</Description>
1818
<PackageLicenseExpression>MIT</PackageLicenseExpression>
Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
// __ _ __ __ ___ __ ___ ___
2+
// | \| |/__\ /' _/ / _//__\| _ \ __|
3+
// | | ' | \/ |`._`.| \_| \/ | v / _|
4+
// |_|\__|\__/ |___/ \__/\__/|_|_\___|
5+
// -----------------------------------
6+
7+
using NosCore.Packets.Attributes;
8+
using NosCore.Packets.Enumerations;
9+
10+
namespace NosCore.Packets.ServerPackets.Player
11+
{
12+
/// <summary>
13+
/// Server-side compact battle-pass marker, observed as <c>bpm 0 0 0</c>
14+
/// (three bytes). Distinct from the large
15+
/// <see cref="NosCore.Packets.ClientPackets.Player.BpmPacket"/> request that
16+
/// carries the full quest list.
17+
/// </summary>
18+
[PacketHeader("bpm", Scope.InGame)]
19+
public class BpmPacket : PacketBase
20+
{
21+
[PacketIndex(0)]
22+
public byte State { get; set; }
23+
24+
[PacketIndex(1)]
25+
public byte Unknown1 { get; set; }
26+
27+
[PacketIndex(2)]
28+
public byte Unknown2 { get; set; }
29+
}
30+
}
Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
// __ _ __ __ ___ __ ___ ___
2+
// | \| |/__\ /' _/ / _//__\| _ \ __|
3+
// | | ' | \/ |`._`.| \_| \/ | v / _|
4+
// |_|\__|\__/ |___/ \__/\__/|_|_\___|
5+
// -----------------------------------
6+
7+
using NosCore.Packets.Attributes;
8+
using NosCore.Packets.Enumerations;
9+
10+
namespace NosCore.Packets.ServerPackets.Quest
11+
{
12+
/// <summary>
13+
/// Server-side variant of <see cref="QnamliPacket"/> with a trailing
14+
/// character/target name. Observed wire:
15+
/// <c>qnamli2 100 #rl 1646 13 2514 Gladi</c>.
16+
/// </summary>
17+
[PacketHeader("qnamli2", Scope.InGame)]
18+
public class Qnamli2Packet : PacketBase
19+
{
20+
[PacketIndex(0)]
21+
public int QuestId { get; set; }
22+
23+
[PacketIndex(1, RemoveHash = true)]
24+
public string? Guri { get; set; }
25+
26+
[PacketIndex(2)]
27+
public int TargetId { get; set; }
28+
29+
[PacketIndex(3)]
30+
public int Value1 { get; set; }
31+
32+
[PacketIndex(4)]
33+
public int Value2 { get; set; }
34+
35+
[PacketIndex(5)]
36+
public string? TargetName { get; set; }
37+
}
38+
}

0 commit comments

Comments
 (0)