bugfix: humans start with zero troops on teams, also removed manpower argument to addPlayer()

This commit is contained in:
Evan
2025-04-04 10:03:00 -07:00
parent 51bbf2becd
commit 924ca2c69e
8 changed files with 13 additions and 23 deletions
+2 -2
View File
@@ -39,7 +39,7 @@ describe("Attack", () => {
null,
"attacker_id",
);
game.addPlayer(attackerInfo, 1000);
game.addPlayer(attackerInfo);
const defenderInfo = new PlayerInfo(
"us",
"defender dude",
@@ -47,7 +47,7 @@ describe("Attack", () => {
null,
"defender_id",
);
game.addPlayer(defenderInfo, 1000);
game.addPlayer(defenderInfo);
defenderSpawn = game.ref(0, 15);
attackerSpawn = game.ref(0, 10);
+1 -1
View File
@@ -38,7 +38,7 @@ describe("MissileSilo", () => {
null,
"attacker_id",
);
game.addPlayer(attacker_info, 1000);
game.addPlayer(attacker_info);
game.addExecution(
new SpawnExecution(game.player(attacker_info.id).info(), game.ref(1, 1)),
+2 -2
View File
@@ -50,8 +50,8 @@ describe("SAM", () => {
null,
"attacker_id",
);
game.addPlayer(defender_info, 1000);
game.addPlayer(attacker_info, 1000);
game.addPlayer(defender_info);
game.addPlayer(attacker_info);
game.addExecution(
new SpawnExecution(game.player(defender_info.id).info(), game.ref(1, 1)),
-1
View File
@@ -7,7 +7,6 @@ describe("Territory management", () => {
const game = await setup("Plains");
game.addPlayer(
new PlayerInfo("us", "test_player", PlayerType.Human, null, "test_id"),
1000,
);
const spawnTile = game.map().ref(50, 50);
game.addExecution(
+2 -2
View File
@@ -27,7 +27,7 @@ describe("Warship", () => {
null,
"player_1_id",
);
game.addPlayer(player_1_info, 1000);
game.addPlayer(player_1_info);
const player_2_info = new PlayerInfo(
"us",
"boat dude",
@@ -35,7 +35,7 @@ describe("Warship", () => {
null,
"player_2_id",
);
game.addPlayer(player_2_info, 1000);
game.addPlayer(player_2_info);
game.addExecution(
new SpawnExecution(