Aetheria/Aetheria.State/Documents/AetheriaCorporation.cs

79 lines
1.9 KiB
C#
Raw Normal View History

2026-06-13 00:31:22 +01:00
using GameCult.Caching;
using MessagePack;
namespace Aetheria.State.Documents;
2026-06-13 13:18:03 +01:00
[CultDocument("aetheria.corporation", "aetheria.corporation.v2")]
2026-06-13 00:31:22 +01:00
[MessagePackObject]
public sealed class AetheriaCorporation
{
[Key(0)]
[CultName]
public string Name { get; set; } = "";
[Key(1)]
[CultIndex("legacyId")]
public string LegacyId { get; set; } = "";
[IgnoreMember]
public string CorporationKey => string.IsNullOrWhiteSpace(LegacyId)
? ""
: $"aetheria.corporation:legacy:{LegacyId}";
2026-06-13 00:31:22 +01:00
[Key(2)]
2026-06-13 08:09:41 +01:00
public string ShortName { get; set; } = "";
[Key(3)]
2026-06-13 00:31:22 +01:00
public string Description { get; set; } = "";
2026-06-13 08:09:41 +01:00
[Key(4)]
[CultIndex("geonameFileLegacyId")]
public string GeonameFileLegacyId { get; set; } = "";
[IgnoreMember]
public string GeonameFileKey => string.IsNullOrWhiteSpace(GeonameFileLegacyId)
? ""
: $"aetheria.name_file:legacy:{GeonameFileLegacyId}";
2026-06-13 08:09:41 +01:00
[Key(5)]
[CultIndex("bossHullLegacyId")]
public string BossHullLegacyId { get; set; } = "";
[IgnoreMember]
public string BossHullItemKey => string.IsNullOrWhiteSpace(BossHullLegacyId)
? ""
: $"aetheria.item_definition:legacy:{BossHullLegacyId}";
2026-06-13 08:09:41 +01:00
[Key(6)]
public int InfluenceDistance { get; set; }
[Key(7)]
public int AllegianceCount { get; set; }
[Key(8)]
public uint OverworldMusic { get; set; }
[Key(9)]
public uint CombatMusic { get; set; }
[Key(10)]
public uint BossMusic { get; set; }
2026-06-13 13:18:03 +01:00
[Key(11)]
public AetheriaCorporationAllegiance[] Allegiances { get; set; } = [];
}
[MessagePackObject]
public sealed class AetheriaCorporationAllegiance
{
[Key(0)]
public string CorporationLegacyId { get; set; } = "";
[IgnoreMember]
public string CorporationKey => string.IsNullOrWhiteSpace(CorporationLegacyId)
? ""
: $"aetheria.corporation:legacy:{CorporationLegacyId}";
2026-06-13 13:18:03 +01:00
[Key(1)]
public double Weight { get; set; }
2026-06-13 00:31:22 +01:00
}