acdream/tests/AcDream.Core.Net.Tests
Erik 7e95c45ece fix(net): ranged speech carries a range float our parser was eating
HearSpeech decoded 0x02BB and 0x02BC with one layout. They do not share one.
ACE's GameMessageHearRangedSpeech writes senderID, range, chatMessageType
where GameMessageHearSpeech writes only senderID, chatMessageType, and
holtburger's HearRangedSpeechData declares the same range: f32 that
HearSpeechData lacks. Two oracles, no ambiguity.

The consequence was quiet rather than loud. The tail is twelve bytes, our
guard demanded eight, so nothing ever failed to parse. We read the guid
correctly, then read range's float bits as the chat type and discarded the
real one. A shout at range 60.0f arrived with a chat type of 0x42700000
instead of 0x0B. Nothing downstream consumes ChatType for local speech today,
which is why this survived, but the record is public and any future consumer
would have inherited garbage.

TryParse now branches its tail size on the opcode and Parsed gains Range,
which stays zero for local speech because there is no such field on that
wire. The existing ChatTests ranged case was itself built on the misreading,
constructing a local-shaped tail; it is corrected to the oracle layout and
now asserts both range and chat type rather than only the ranged flag.

New golden tests drive both opcodes through AceWireWriter in ACE's write
order, covering empty strings, string lengths one through four so every
residue of the four-byte padding rule is exercised, CP1252 accented names,
and a regression pin asserting the chat type is not the range float's bits.
A ranged body four bytes short is now rejected instead of silently decoded.

Core.Net tests go 617 to 630, all green.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-29 01:51:34 +02:00
..
Cryptography feat(net): PacketHeader + PacketHeaderFlags + Hash32 checksum (Phase 4.2) 2026-04-11 14:17:37 +02:00
Messages fix(net): ranged speech carries a range float our parser was eating 2026-07-29 01:51:34 +02:00
Packets perf(net): frame recurring sends in place 2026-07-25 06:02:52 +02:00
AcDream.Core.Net.Tests.csproj feat(net): AcDream.Core.Net scaffold + ISAAC keystream (Phase 4.1) 2026-04-11 14:14:28 +02:00
CombatStateWiringTests.cs feat(inventory): port retail weapon switching 2026-07-12 23:06:31 +02:00
GameEventWiringTests.cs fix #234: port retail appraisal floaty and inscriptions 2026-07-23 12:12:57 +02:00
LiveHandshakeTests.cs fix(net): conform character entry and session shutdown 2026-07-21 10:33:03 +02:00
NetClientTests.cs perf(net): own one pooled async receive 2026-07-25 05:50:18 +02:00
ObjectTableWiringTests.cs fix(ui): preserve retail item titles and spacing 2026-07-24 05:21:01 +02:00
PlayerDescriptionParserTests.cs feat: port retail magic lifecycle and retained spell UI 2026-07-15 10:55:22 +02:00
PrivateUpdateVitalTests.cs feat(player): #5 PlayerDescription parser — Stam/Mana via attribute block 2026-04-25 16:42:24 +02:00
SubscriptionSetTests.cs refactor(net): own live session composition 2026-07-22 10:36:06 +02:00
WorldSessionChatTests.cs feat(chat): route retail lifestone commands 2026-07-13 11:43:19 +02:00
WorldSessionCombatTests.cs feat(ui): finish retail toolbar controls 2026-07-11 12:11:53 +02:00
WorldSessionConstructionTests.cs perf(net): own one pooled async receive 2026-07-25 05:50:18 +02:00
WorldSessionInboundBudgetTests.cs fix(net): timeslice WorldSession.Tick inbound drain (#2 flood) 2026-06-22 15:39:50 +02:00
WorldSessionInventoryActionTests.cs fix #234: port retail appraisal floaty and inscriptions 2026-07-23 12:12:57 +02:00
WorldSessionLinkStatusTests.cs feat(ui): share indicator detail panels 2026-07-17 10:27:41 +02:00
WorldSessionNegotiationShutdownTests.cs fix(net): conform character entry and session shutdown 2026-07-21 10:33:03 +02:00
WorldSessionNetReceiveLoopResilienceTests.cs perf(net): own one pooled async receive 2026-07-25 05:50:18 +02:00
WorldSessionRadarTests.cs fix(ui): preserve retail item titles and spacing 2026-07-24 05:21:01 +02:00
WorldSessionShutdownTests.cs fix(net): conform character entry and session shutdown 2026-07-21 10:33:03 +02:00
WorldSessionWiringOwnershipTests.cs refactor(net): own live session routing 2026-07-21 11:17:09 +02:00