fix pop ratio for growth

This commit is contained in:
1brucben
2025-05-29 12:27:29 +02:00
parent 4443459bc5
commit 7ea0b931dd
+6 -2
View File
@@ -76,8 +76,12 @@ export class PlayerExecution implements Execution {
}
const popInc = this.config.populationIncreaseRate(this.player);
this.player.addWorkers(popInc * (1 - this.player.targetTroopRatio()));
this.player.addTroops(popInc * this.player.targetTroopRatio());
this.player.addWorkers(
(popInc * this.player.workers()) / this.player.totalPopulation(),
);
this.player.addTroops(
popInc * (1 - this.player.workers() / this.player.totalPopulation()),
);
const goldFromWorkers = this.config.goldAdditionRate(this.player);
this.player.addGold(goldFromWorkers);