refactor(battle-node): switch MsgEnvelope.Body to IMsgBody, migrate all sites

This commit is contained in:
gamer147
2026-06-01 10:40:09 -04:00
parent 118be92dc5
commit 5ee270eb16
11 changed files with 183 additions and 231 deletions

View File

@@ -24,7 +24,7 @@ public class MsgPayloadCodecTests
Cat: EmitCategory.Battle,
PubSeq: 3,
PlaySeq: null,
Body: new Dictionary<string, object?>());
Body: new RawBody(new Dictionary<string, object?>()));
var bytes = MsgPayloadCodec.Encode(env, key: FreshKey());
var back = MsgPayloadCodec.Decode(bytes);
@@ -48,6 +48,6 @@ public class MsgPayloadCodecTests
Assert.That(env.Uri, Is.EqualTo(NetworkBattleUri.InitNetwork));
Assert.That(env.Cat, Is.EqualTo(EmitCategory.General));
Assert.That(env.Body["resultCode"], Is.EqualTo(1L));
Assert.That(((RawBody)env.Body).Entries["resultCode"], Is.EqualTo(1L));
}
}