Changeset View
Changeset View
Standalone View
Standalone View
binaries/data/mods/public/simulation/ai/petra/config.js
Show First 20 Lines • Show All 203 Lines • ▼ Show 20 Lines | if (this.difficulty < 2) | ||||
this.Economy.targetNumWorkers = Math.max(1, Math.min(40, maxPop)); | this.Economy.targetNumWorkers = Math.max(1, Math.min(40, maxPop)); | ||||
else if (this.difficulty < 3) | else if (this.difficulty < 3) | ||||
this.Economy.targetNumWorkers = Math.max(1, Math.min(60, Math.floor(maxPop/2))); | this.Economy.targetNumWorkers = Math.max(1, Math.min(60, Math.floor(maxPop/2))); | ||||
else | else | ||||
this.Economy.targetNumWorkers = Math.max(1, Math.min(120, Math.floor(maxPop/3))); | this.Economy.targetNumWorkers = Math.max(1, Math.min(120, Math.floor(maxPop/3))); | ||||
this.Economy.targetNumTraders = 2 + this.difficulty; | this.Economy.targetNumTraders = 2 + this.difficulty; | ||||
if (gameState.getGameType() === "wonder") | if (gameState.getVictoryConditions().indexOf("wonder") != -1) | ||||
{ | { | ||||
this.Economy.workPhase3 = Math.floor(0.9 * this.Economy.workPhase3); | this.Economy.workPhase3 = Math.floor(0.9 * this.Economy.workPhase3); | ||||
this.Economy.workPhase4 = Math.floor(0.9 * this.Economy.workPhase4); | this.Economy.workPhase4 = Math.floor(0.9 * this.Economy.workPhase4); | ||||
} | } | ||||
if (maxPop < 300) | if (maxPop < 300) | ||||
{ | { | ||||
this.popScaling = Math.sqrt(maxPop / 300); | this.popScaling = Math.sqrt(maxPop / 300); | ||||
Show All 37 Lines |
Wildfire Games · Phabricator