better name rendering, game attack balancing

This commit is contained in:
evanpelle
2024-09-06 20:43:14 -07:00
parent 75adcd2989
commit 5bc7d6e023
2 changed files with 4 additions and 3 deletions
+2 -1
View File
@@ -27,12 +27,13 @@ export function placeName(game: Game, player: Player): [position: Cell, fontSize
largestRectangle.width = largestRectangle.width * scalingFactor
largestRectangle.height = largestRectangle.height * scalingFactor
const center = new Cell(
let center = new Cell(
Math.floor(largestRectangle.x + largestRectangle.width / 2 + boundingBox.min.x),
Math.floor(largestRectangle.y + largestRectangle.height / 2 + boundingBox.min.y),
)
const fontSize = calculateFontSize(largestRectangle, player.name());
center = new Cell(center.x, center.y - fontSize / 3)
return [center, fontSize]
}
+2 -2
View File
@@ -36,10 +36,10 @@ export class DefaultConfig implements Config {
mag = 1
break
case TerrainType.Highland:
mag = 20
mag = 15
break
case TerrainType.Mountain:
mag = 100
mag = 50
break
}
if (defender.isPlayer()) {