Implement city production projects for units and buildings

This commit is contained in:
bart
2026-11-08 21:22:04 +01:00
parent ae04619dae
commit f8cd221e37
19 changed files with 444 additions and 12 deletions
+2 -1
View File
@@ -39,6 +39,7 @@ struct UnitConfig {
int health;
float movementSpeed;
int cost;
int laborCost;
int attackDamage;
int attackRange; // 1 for melee, >1 for ranged
int buildCharges;
@@ -52,7 +53,7 @@ struct UnitConfig {
UnitConfig()
: id(""), name(""), category(UnitCategory::Builder),
movementDomain(MovementDomain::Land), health(100),
movementSpeed(2.0f), cost(10), attackDamage(0), attackRange(1),
movementSpeed(2.0f), cost(10), laborCost(1000), attackDamage(0), attackRange(1),
buildCharges(-1), infiniteCharges(true), iconPath("") {}
bool isRanged() const { return attackRange > 1; }