The upgrade array
const testUpg = [
{
id: "upgId1",
cost: (level: Decimal): Decimal => level.mul(10),
},
{
id: "upgId2",
cost: (level: Decimal): Decimal => level.mul(20),
},
] as const satisfies UpgradeInit[] // Must be readonly and satisfy UpgradeInit
type test = UpgradeInitArrayType<typeof testUpg> // "upgId1" | "upgId2"
Infers the id type of an upgrade array