add defense post unit (no execution)

This commit is contained in:
Evan
2024-11-30 20:54:42 -08:00
parent 7ff0509b40
commit e7039d3e07
13 changed files with 126 additions and 8 deletions
+5
View File
@@ -64,6 +64,11 @@ export class DefaultConfig implements Config {
cost: () => 1_000_000,
territoryBound: true
}
case UnitType.DefensePost:
return {
cost: (p: Player) => Math.pow(2, p.units(UnitType.Port).length) * 100_000,
territoryBound: true
}
default:
assertNever(type)
}
+1 -1
View File
@@ -5,7 +5,7 @@ export const devConfig = new class extends DefaultConfig {
unitInfo(type: UnitType): UnitInfo {
const info = super.unitInfo(type)
const oldCost = info.cost
// info.cost = (p: Player) => oldCost(p) / 1000
info.cost = (p: Player) => oldCost(p) / 1000
return info
}