Enable various eslint rules (#1773)

## Description:

Enable various eslint rules.

## Please complete the following:

- [x] I have added screenshots for all UI updates
- [x] I process any text displayed to the user through translateText()
and I've added it to the en.json file
- [x] I have added relevant tests to the test directory
- [x] I confirm I have thoroughly tested these changes and take full
responsibility for any bugs introduced
This commit is contained in:
Scott Anderson
2025-08-11 22:14:00 -04:00
committed by GitHub
parent 8a41919ed7
commit ce49599229
109 changed files with 471 additions and 460 deletions
+3 -3
View File
@@ -28,11 +28,11 @@ export class PlayerExecution implements Execution {
tick(ticks: number) {
this.player.decayRelations();
this.player.units().forEach((u) => {
const tileOwner = this.mg!.owner(u.tile());
const tileOwner = this.mg.owner(u.tile());
if (u.info().territoryBound) {
if (tileOwner.isPlayer()) {
if (tileOwner !== this.player) {
this.mg!.player(tileOwner.id()).captureUnit(u);
this.mg.player(tileOwner.id()).captureUnit(u);
}
} else {
u.delete();
@@ -218,7 +218,7 @@ export class PlayerExecution implements Execution {
}
let largestNeighborAttack: Player | null = null;
let largestTroopCount: number = 0;
let largestTroopCount = 0;
for (const id of neighborsIDs) {
const neighbor = this.mg.playerBySmallID(id);
if (!neighbor.isPlayer() || this.player.isFriendly(neighbor)) {