Rename pending commit catalog ids

This commit is contained in:
Meta Vens 2026-06-13 21:30:42 +01:00
commit fd74c87377
4 changed files with 18 additions and 14 deletions

View file

@ -187,7 +187,7 @@ try
PositionZ = 3.0,
DirectionX = 0.0,
DirectionY = 1.0,
HullItemLegacyId = "smoke:hull",
HullItemDefinitionLegacyId = "smoke:hull",
Equipment = new[]
{
new AetheriaRuntimeLoadoutItemSlotCommit
@ -196,7 +196,7 @@ try
Y = 0,
Item = new AetheriaRuntimeLoadoutItemCommit
{
ItemLegacyId = "smoke:weapon",
ItemDefinitionLegacyId = "smoke:weapon",
Quality = 0.9,
Durability = 0.8
}

View file

@ -266,7 +266,7 @@ public class ActionGameManager : MonoBehaviour
{
Name = blueprint.Name ?? "",
Kind = blueprint is RuntimeShipBlueprint ? "ship" : blueprint is RuntimeOrbitalEntityBlueprint ? "orbital" : "entity",
FactionLegacyId = blueprint.Faction == Guid.Empty ? "" : blueprint.Faction.ToString("D"),
CorporationLegacyId = blueprint.Faction == Guid.Empty ? "" : blueprint.Faction.ToString("D"),
Hull = ProjectLoadoutItem(blueprint.Hull),
Equipment = ProjectSlots(blueprint.Equipment),
CargoBays = ProjectSlots(blueprint.CargoBays),
@ -315,7 +315,7 @@ public class ActionGameManager : MonoBehaviour
return new AetheriaRuntimeLoadoutItemCommit
{
ItemLegacyId = item.Data?.ItemId.ToString("D") ?? "",
ItemDefinitionLegacyId = item.Data?.ItemId.ToString("D") ?? "",
Quality = item is CraftedItemInstance crafted ? crafted.Quality : 1.0,
Durability = item is EquippableItem equippable ? equippable.Durability : 1.0,
Quantity = item is SimpleCommodity commodity ? commodity.Quantity : 1
@ -379,8 +379,8 @@ public class ActionGameManager : MonoBehaviour
PositionZ = entity.Position.z,
DirectionX = entity.Direction.x,
DirectionY = entity.Direction.y,
FactionLegacyId = entity.Faction?.ID.ToString("D") ?? "",
HullItemLegacyId = entity.Hull?.Data?.ItemId.ToString("D") ?? "",
CorporationLegacyId = entity.Faction?.ID.ToString("D") ?? "",
HullItemDefinitionLegacyId = entity.Hull?.Data?.ItemId.ToString("D") ?? "",
Equipment = ProjectEquippedSlots(entity.Equipment),
CargoBays = ProjectEquippedSlots(entity.CargoBays),
DockingBays = ProjectEquippedSlots(entity.DockingBays),

View file

@ -76,7 +76,7 @@ namespace GameCult.Aetheria.State.Unity
{
public string Name { get; set; } = "";
public string Kind { get; set; } = "";
public string FactionLegacyId { get; set; } = "";
public string CorporationLegacyId { get; set; } = "";
public AetheriaRuntimeLoadoutItemCommit Hull { get; set; } = new AetheriaRuntimeLoadoutItemCommit();
public IReadOnlyList<AetheriaRuntimeLoadoutItemSlotCommit> Equipment { get; set; } = Array.Empty<AetheriaRuntimeLoadoutItemSlotCommit>();
public IReadOnlyList<AetheriaRuntimeLoadoutItemSlotCommit> CargoBays { get; set; } = Array.Empty<AetheriaRuntimeLoadoutItemSlotCommit>();
@ -90,7 +90,7 @@ namespace GameCult.Aetheria.State.Unity
public sealed class AetheriaRuntimeLoadoutItemCommit
{
public string ItemLegacyId { get; set; } = "";
public string ItemDefinitionLegacyId { get; set; } = "";
public double Quality { get; set; } = 1.0;
public double Durability { get; set; } = 1.0;
public int Quantity { get; set; } = 1;
@ -142,8 +142,8 @@ namespace GameCult.Aetheria.State.Unity
public double PositionZ { get; set; }
public double DirectionX { get; set; }
public double DirectionY { get; set; }
public string FactionLegacyId { get; set; } = "";
public string HullItemLegacyId { get; set; } = "";
public string CorporationLegacyId { get; set; } = "";
public string HullItemDefinitionLegacyId { get; set; } = "";
public IReadOnlyList<AetheriaRuntimeLoadoutItemSlotCommit> Equipment { get; set; } = Array.Empty<AetheriaRuntimeLoadoutItemSlotCommit>();
public IReadOnlyList<AetheriaRuntimeLoadoutItemSlotCommit> CargoBays { get; set; } = Array.Empty<AetheriaRuntimeLoadoutItemSlotCommit>();
public IReadOnlyList<AetheriaRuntimeLoadoutItemSlotCommit> DockingBays { get; set; } = Array.Empty<AetheriaRuntimeLoadoutItemSlotCommit>();
@ -301,7 +301,7 @@ namespace GameCult.Aetheria.State.Unity
writer.WriteArrayHeader(12);
writer.Write(entity.Name ?? "");
writer.Write(entity.Kind ?? "");
writer.Write(entity.FactionLegacyId ?? "");
writer.Write(entity.CorporationLegacyId ?? "");
WriteLoadoutItem(ref writer, entity.Hull);
WriteItemSlots(ref writer, entity.Equipment);
WriteItemSlots(ref writer, entity.CargoBays);
@ -316,7 +316,7 @@ namespace GameCult.Aetheria.State.Unity
private static void WriteLoadoutItem(ref MessagePackWriter writer, AetheriaRuntimeLoadoutItemCommit item)
{
writer.WriteArrayHeader(4);
writer.Write(item.ItemLegacyId ?? "");
writer.Write(item.ItemDefinitionLegacyId ?? "");
writer.Write(item.Quality);
writer.Write(item.Durability);
writer.Write(item.Quantity);
@ -397,8 +397,8 @@ namespace GameCult.Aetheria.State.Unity
writer.Write(entity.PositionZ);
writer.Write(entity.DirectionX);
writer.Write(entity.DirectionY);
writer.Write(entity.FactionLegacyId ?? "");
writer.Write(entity.HullItemLegacyId ?? "");
writer.Write(entity.CorporationLegacyId ?? "");
writer.Write(entity.HullItemDefinitionLegacyId ?? "");
WriteItemSlots(ref writer, entity.Equipment);
WriteItemSlots(ref writer, entity.CargoBays);
WriteItemSlots(ref writer, entity.DockingBays);

View file

@ -252,6 +252,10 @@ legacy catalog cache, and legacy UI paths should be migration-only or deleted.
- The dead Unity `NameFile` projection class has been deleted. Runtime name
generation reads `AetheriaRuntimeNameFile` records from the typed catalog
facade; legacy `GameData/NameFile/*.msgpack` remains migration input only.
- Pending Unity runtime commit envelopes now name their source catalog IDs as
`CorporationLegacyId`, `ItemDefinitionLegacyId`, and
`HullItemDefinitionLegacyId`; the applier has always projected those fields
into typed corporation and item-definition record keys.
- Entity restore and loadout manufacturer-distance weighting no longer read
legacy `Faction` entries through `ItemManager`; they use `Galaxy.ResolveFaction`
over the typed corporation projection.