fix(ui): preserve retail item titles and spacing

Carry PublicWeenieDesc material type into the live object model so examination titles use the DAT-authored material prefix. Preserve retail AddItemInfo empty appends and embedded armor separator, restoring the deliberate blank rows between appraisal sections.

Co-authored-by: Codex <codex@openai.com>
This commit is contained in:
Erik 2026-07-24 05:21:01 +02:00
parent d78d09cfbc
commit 6718ee45a0
19 changed files with 341 additions and 46 deletions

View file

@ -681,6 +681,7 @@ public sealed class CreateObjectTests
var parsed = CreateObject.TryParse(body);
Assert.NotNull(parsed);
Assert.Equal(7u, parsed.Value.MaterialType);
Assert.Equal(11u, parsed.Value.CooldownId);
Assert.Equal(12.5, parsed.Value.CooldownDuration);
Assert.Equal(0x50000001u, parsed.Value.PetOwnerId);

View file

@ -70,6 +70,7 @@ public sealed class ObjectTableWiringTests
PetOwnerId = 0x50000001u,
CooldownId = 42u,
CooldownDuration = 30d,
MaterialType = 77u,
};
var d = ObjectTableWiring.ToWeenieData(spawn);
@ -122,6 +123,7 @@ public sealed class ObjectTableWiringTests
Assert.Equal(0x50000001u, d.PetOwnerId);
Assert.Equal(42u, d.CooldownId);
Assert.Equal(30d, d.CooldownDuration);
Assert.Equal(77u, d.MaterialType);
}
[Fact]

View file

@ -50,6 +50,17 @@ public sealed class WorldSessionRadarTests
Assert.Equal(0x50000002u, spawn.PetOwnerId);
}
[Fact]
public void ToEntitySpawn_PreservesMaterialType()
{
var spawn = WorldSession.ToEntitySpawn(MinimalParsed() with
{
MaterialType = 77u,
});
Assert.Equal(77u, spawn.MaterialType);
}
private static CreateObject.Parsed MinimalParsed() => new(
Guid: 0x50000001u,
Position: null,