namespace Model;

public sealed record UnitData(
    string Id,
    string Name,
    int Hexite,
    int Flux,
    int Supply,
    int ProductionTime,
    int Health,
    int Energy,
    int Shields,
    int ArmorRating,
    int MovementSpeed,
    int DamagePerSecond,
    int AttackRange,
    IReadOnlyList<string> Attributes,
    int Tier,
    string Faction,
    string? Hotkey,
    int BuildAtSameTime,
    int? Limit)
{
    public double DpsPerHexite => UnitEfficiency.CalculateDpsPerHexite(DamagePerSecond, Hexite);
    public double DpsPerFlux => UnitEfficiency.CalculateDpsPerFlux(DamagePerSecond, Flux);
    public double DpsPerTotalCost => UnitEfficiency.CalculateDpsPerTotalCost(DamagePerSecond, Hexite, Flux);

    public double HealthPerHexite => UnitEfficiency.CalculateHealthPerHexite(Health, Hexite);
    public double HealthPerFlux => UnitEfficiency.CalculateHealthPerFlux(Health, Flux);
    public double HealthPerTotalCost => UnitEfficiency.CalculateHealthPerTotalCost(Health, Hexite, Flux);
}

