Java Algo not working in local match

I’ve managed to get the local match working for python algos, I can see in the replay that they’re doing what they’re supposed to. However, when I try to run it with a java algo, the java algo seems to not load correctly, nothing happens on its side and the time taken at the end screen suggests that it isn’t doing anything. I’ve compiled the java algo into the algo-target folder. The same thing happens with run_match.py.

edit: I’ve fixed the issue after using the solution in Windows error running match locally with fresh starter kit

PS D:\Storage\VS Code Projects\Terminal\C1GamesStarterKit-master> .\scripts\run_match.ps1 .\megalodon\ .\tidal\algo-target
p1:
.\megalodon\run.ps1
p2:
.\tidal\algo-target\run.ps1
Starting Engine: August_17_2020
Starting single worker game.
Looking for Config file at:
D:\Storage\VS Code Projects\Terminal\C1GamesStarterKit-master/game-configs.json
.\megalodon\run.ps1
.\tidal\algo-target\run.ps1
Saving replay: D:\Storage\VS Code Projects\Terminal\C1GamesStarterKit-master\replays\p1-14-04-2023-15-38-30-1681511910631–1388828298.replay
P1 Name: seasonMode:5
P2 Name: seasonMode:5
Waiting for: 3000 before starting first turn.
SAPlayer 1 : Random seed: 4562945556997343971
SAPlayer 1 : ---------------- Starting Your Algo --------------------
Done waiting starting first turn.
SAPlayer 1 : Configuring your custom algo strategy…
SAPlayer 1 : Performing turn 0 of your custom algo strategy
Invalid command, couldn’t json for player 1 : {“debug”:{“printMapString”:false,“printTStrings”:false,“printActStrings”:false,“printHitStrings”:false,“printPlayerInputStrings”:false,“printBotErrors”:true,“printPlayerGetHitStrings”:false},“unitInformation”:[{“iconxScale”:0.4,“turnsRequiredToRemove”:1,“refundPercentage”:0.75,“cost1”:1.0,“getHitRadius”:0.01,“upgrade”:{“iconxScale”:0.4,“icon”:“S3_filter”,“iconyScale”:0.5,“startHealth”:150.0},“unitCategory”:0,“display”:“filter”,“icon”:“S3_filter”,“iconyScale”:0.5,“startHealth”:75.0,“shorthand”:“FF”},{“iconxScale”:0.5,“refundPercentage”:0.75,“cost1”:7.0,“upgrade”:{“iconxScale”:0.5,“generatesResource2”:2.0,“icon”:“S3_encryptor”,“iconyScale”:0.5},“display”:“encryptor”,“icon”:“S3_encryptor”,“iconyScale”:0.5,“shorthand”:“EF”,“turnsRequiredToRemove”:1,“generatesResource1”:1.0,“getHitRadius”:0.01,“unitCategory”:0,“startHealth”:30.0},{“iconxScale”:0.5,“attackRange”:2.5,“refundPercentage”:0.75,“cost1”:2.0,“upgrade”:{“iconxScale”:0.5,“attackDamageWalker”:15.0,“attackRange”:3.5,“cost1”:4.0,“icon”:“S3_destructor”,“iconyScale”:0.5},“display”:“destructor”,“icon”:“S3_destructor”,“iconyScale”:0.5,“shorthand”:“DF”,“attackDamageWalker”:5.0,“turnsRequiredToRemove”:1,“getHitRadius”:0.01,“unitCategory”:0,“startHealth”:90.0,“attackDamageTower”:0.0},{“iconxScale”:0.7,“attackRange”:3.5,“selfDestructDamageTower”:15.0,“cost2”:1.0,“metalForBreach”:1.0,“display”:“ping”,“icon”:“S3_ping”,“selfDestructStepsRequired”:5,“iconyScale”:0.5,“shorthand”:“PI”,“playerBreachDamage”:1.0,“speed”:1.0,“attackDamageWalker”:2.0,“getHitRadius”:0.01,“unitCategory”:1,“selfDestructDamageWalker”:15.0,“startHealth”:15.0,“selfDestructRange”:1.5,“attackDamageTower”:2.0},{“iconxScale”:0.47,“attackRange”:4.5,“selfDestructDamageTower”:5.0,“cost2”:3.0,“metalForBreach”:1.0,“display”:“emp”,“icon”:“S3_emp”,“selfDestructStepsRequired”:5,“iconyScale”:0.5,“shorthand”:“EI”,“playerBreachDamage”:1.0,“speed”:0.5,“attackDamageWalker”:6.0,“getHitRadius”:0.01,“unitCategory”:1,“selfDestructDamageWalker”:5.0,“startHealth”:5.0,“selfDestructRange”:1.5,“attackDamageTower”:6.0},{“iconxScale”:0.5,“attackRange”:3.5,“selfDestructDamageTower”:40.0,“cost2”:1.0,“metalForBreach”:1.0,“display”:“scrambler”,“icon”:“S3_scrambler”,“selfDestructStepsRequired”:5,“iconyScale”:0.5,“shorthand”:“SI”,“playerBreachDamage”:1.0,“speed”:0.25,“attackDamageWalker”:20.0,“getHitRadius”:0.01,“unitCategory”:1,“selfDestructDamageWalker”:40.0,“startHealth”:40.0,“selfDestructRange”:1.5,“attackDamageTower”:0.0},{“iconxScale”:0.4,“display”:“Remove”,“icon”:“S3_removal”,“iconyScale”:0.5,“shorthand”:“RM”},{“iconxScale”:0.4,“display”:“Upgrade”,“icon”:“S3_upgrade”,“iconyScale”:0.5,“shorthand”:“UP”}],“timingAndReplay”:{“playReplaySave”:1,“waitTimeBotMax”:35000,“waitTimeManual”:1820000,“waitForever”:false,“playWaitTimeBotSoft”:5000,“waitTimeEndGame”:3000,“waitTimeBotSoft”:5000,“playWaitTimeBotMax”:35000,“replaySave”:1,“storeBotTimes”:true,“waitTimeStartGame”:3000},“resources”:{“bitsPerRound”:5.0,“coresPerRound”:5.0,“startingBits”:5.0,“turnIntervalForBitCapSchedule”:10,“turnIntervalForBitSchedule”:10,“bitRampBitCapGrowthRate”:5.0,“bitDecayPerRound”:0.25,“roundStartBitRamp”:10,“bitGrowthRate”:1.0,“startingHP”:40.0,“startingCores”:40.0,“maxBits”:150.0},“seasonCompatibilityModeP2”:5,“seasonCompatibilityModeP1”:5}
com.google.gson.JsonSyntaxException: java.lang.IllegalStateException: Expected BEGIN_ARRAY but was BEGIN_OBJECT at line 1 column 2 path $
at com.google.gson.Gson.fromJson(Gson.java:899)
at com.google.gson.Gson.fromJson(Gson.java:852)
at com.google.gson.Gson.fromJson(Gson.java:801)
at com.c1games.terminal.game.Parser.processInputForPlayer(Parser.java:131)
at com.c1games.terminal.game.Parser.processInputBuild(Parser.java:115)
at com.c1games.terminal.game.GameMain.runLoop(GameMain.java:318)
at com.c1games.terminal.game.GameMain.startGame(GameMain.java:175)
at com.c1games.terminal.game.GameMain.main(GameMain.java:150)
at com.c1games.terminal.Terminal.main(Terminal.java:141)
Caused by: java.lang.IllegalStateException: Expected BEGIN_ARRAY but was BEGIN_OBJECT at line 1 column 2 path $
at com.google.gson.stream.JsonReader.beginArray(JsonReader.java:350)
at com.google.gson.internal.bind.CollectionTypeAdapterFactory$Adapter.read(CollectionTypeAdapterFactory.java:80)
at com.google.gson.internal.bind.CollectionTypeAdapterFactory$Adapter.read(CollectionTypeAdapterFactory.java:61)
at com.google.gson.Gson.fromJson(Gson.java:887)
… 8 more
Invalid command, couldn’t json for player 1 : {“p2Units”:[[],[],[],[],[],[],[],[]],“turnInfo”:[0,0,-1,0],“p1Stats”:[40.0,40.0,5.0,0],“p1Units”:[[],[],[],[],[],[],[],[]],“p2Stats”:[40.0,40.0,5.0,0],“events”:{“selfDestruct”:[],“breach”:[],“damage”:[],“shield”:[],“move”:[],“spawn”:[],“death”:[],“attack”:[],“melee”:[]}}
com.google.gson.JsonSyntaxException: java.lang.IllegalStateException: Expected BEGIN_ARRAY but was BEGIN_OBJECT at line 1 column 2 path $
at com.google.gson.Gson.fromJson(Gson.java:899)
at com.google.gson.Gson.fromJson(Gson.java:852)
at com.google.gson.Gson.fromJson(Gson.java:801)
at com.c1games.terminal.game.Parser.processInputForPlayer(Parser.java:131)
at com.c1games.terminal.game.Parser.processInputDeploy(Parser.java:239)
at com.c1games.terminal.game.GameMain.runLoop(GameMain.java:324)
at com.c1games.terminal.game.GameMain.startGame(GameMain.java:175)
at com.c1games.terminal.game.GameMain.main(GameMain.java:150)
at com.c1games.terminal.Terminal.main(Terminal.java:141)
Caused by: java.lang.IllegalStateException: Expected BEGIN_ARRAY but was BEGIN_OBJECT at line 1 column 2 path $
at com.google.gson.stream.JsonReader.beginArray(JsonReader.java:350)
at com.google.gson.internal.bind.CollectionTypeAdapterFactory$Adapter.read(CollectionTypeAdapterFactory.java:80)
at com.google.gson.internal.bind.CollectionTypeAdapterFactory$Adapter.read(CollectionTypeAdapterFactory.java:61)
at com.google.gson.Gson.fromJson(Gson.java:887)
… 8 more
Invalid command, couldn’t json for player 1 : {“p2Units”:[[[1,14,75.0,“1”],[1,15,75.0,“2”],[0,14,75.0,“3”],[27,14,75.0,“9”],[25,16,75.0,“10”],[24,17,75.0,“11”],[23,18,75.0,“12”],[22,19,75.0,“13”],[5,17,75.0,“14”],[6,18,75.0,“15”],[7,17,75.0,“16”],[8,18,75.0,“17”],[8,20,75.0,“19”],[9,21,75.0,“20”],[10,22,75.0,“21”],[11,23,75.0,“22”],[12,24,75.0,“23”],[13,25,75.0,“24”],[21,20,75.0,“25”],[20,21,75.0,“26”],[19,22,75.0,“27”],[18,23,75.0,“28”],[17,23,75.0,“29”],[16,23,75.0,“30”],[15,24,75.0,“31”],[14,25,75.0,“32”],[4,15,150.0,“33”]],[],[[2,14,90.0,“5”],[3,15,90.0,“6”],[4,16,90.0,“7”],[26,15,90.0,“8”],[7,18,90.0,“18”]],[],[],[[7,21,40.0,“34”]],[],[[4,15,0.0,“33”]]],“turnInfo”:[1,0,0,1],“p1Stats”:[40.0,40.0,5.0,13],“p1Units”:[[],[],[],[],[],[],[],[]],“p2Stats”:[40.0,2.0,4.0,2],“events”:{“selfDestruct”:[],“breach”:[],“damage”:[],“shield”:[],“move”:[],“spawn”:[[[1,14],0,“1”,2],[[1,15],0,“2”,2],[[0,14],0,“3”,2],[[4,15],0,“4”,2],[[2,14],2,“5”,2],[[3,15],2,“6”,2],[[4,16],2,“7”,2],[[26,15],2,“8”,2],[[27,14],0,“9”,2],[[25,16],0,“10”,2],[[24,17],0,“11”,2],[[23,18],0,“12”,2],[[22,19],0,“13”,2],[[5,17],0,“14”,2],[[6,18],0,“15”,2],[[7,17],0,“16”,2],[[8,18],0,“17”,2],[[7,18],2,“18”,2],[[8,20],0,“19”,2],[[9,21],0,“20”,2],[[10,22],0,“21”,2],[[11,23],0,“22”,2],[[12,24],0,“23”,2],[[13,25],0,“24”,2],[[21,20],0,“25”,2],[[20,21],0,“26”,2],[[19,22],0,“27”,2],[[18,23],0,“28”,2],[[17,23],0,“29”,2],[[16,23],0,“30”,2],[[15,24],0,“31”,2],[[14,25],0,“32”,2],[[4,15],7,“33”,2],[[7,21],5,“34”,2]],“death”:[],“attack”:[],“melee”:[]}}
com.google.gson.JsonSyntaxException: java.lang.IllegalStateException: Expected BEGIN_ARRAY but was BEGIN_OBJECT at line 1 column 2 path $
at com.google.gson.Gson.fromJson(Gson.java:899)
at com.google.gson.Gson.fromJson(Gson.java:852)
at com.google.gson.Gson.fromJson(Gson.java:801)
at com.c1games.terminal.game.Parser.processInputForPlayer(Parser.java:131)
at com.c1games.terminal.game.Parser.processInputBuild(Parser.java:115)
at com.c1games.terminal.game.GameMain.runLoop(GameMain.java:318)
at com.c1games.terminal.game.GameMain.startGame(GameMain.java:175)
at com.c1games.terminal.game.GameMain.main(GameMain.java:150)
at com.c1games.terminal.Terminal.main(Terminal.java:141)
Caused by: java.lang.IllegalStateException: Expected BEGIN_ARRAY but was BEGIN_OBJECT at line 1 column 2 path $
at com.google.gson.stream.JsonReader.beginArray(JsonReader.java:350)
at com.google.gson.internal.bind.CollectionTypeAdapterFactory$Adapter.read(CollectionTypeAdapterFactory.java:80)
at com.google.gson.internal.bind.CollectionTypeAdapterFactory$Adapter.read(CollectionTypeAdapterFactory.java:61)
at com.google.gson.Gson.fromJson(Gson.java:887)
… 8 more
Invalid command, couldn’t json for player 1 : {“p2Units”:[[[1,14,75.0,“1”],[1,15,75.0,“2”],[0,14,75.0,“3”],[27,14,75.0,“9”],[25,16,75.0,“10”],[24,17,75.0,“11”],[23,18,75.0,“12”],[22,19,75.0,“13”],[5,17,75.0,“14”],[6,18,75.0,“15”],[7,17,75.0,“16”],[8,18,75.0,“17”],[8,20,75.0,“19”],[9,21,75.0,“20”],[10,22,75.0,“21”],[11,23,75.0,“22”],[12,24,75.0,“23”],[13,25,75.0,“24”],[21,20,75.0,“25”],[20,21,75.0,“26”],[19,22,75.0,“27”],[18,23,75.0,“28”],[17,23,75.0,“29”],[16,23,75.0,“30”],[15,24,75.0,“31”],[14,25,75.0,“32”],[4,15,150.0,“33”]],[],[[2,14,90.0,“5”],[3,15,90.0,“6”],[4,16,90.0,“7”],[26,15,90.0,“8”],[7,18,90.0,“18”]],[],[],[[7,21,40.0,“34”]],[],[[4,15,0.0,“33”]]],“turnInfo”:[1,0,1,2],“p1Stats”:[40.0,40.0,5.0,13],“p1Units”:[[],[],[],[],[],[],[],[]],“p2Stats”:[40.0,2.0,4.0,2],“events”:{“selfDestruct”:[],“breach”:[],“damage”:[],“shield”:[],“move”:[],“spawn”:[],“death”:[],“attack”:[],“melee”:[]}}
com.google.gson.JsonSyntaxException: java.lang.IllegalStateException: Expected BEGIN_ARRAY but was BEGIN_OBJECT at line 1 column 2 path $
at com.google.gson.Gson.fromJson(Gson.java:899)
at com.google.gson.Gson.fromJson(Gson.java:852)
at com.google.gson.Gson.fromJson(Gson.java:801)
at com.c1games.terminal.game.Parser.processInputForPlayer(Parser.java:131)
at com.c1games.terminal.game.Parser.processInputDeploy(Parser.java:239)
at com.c1games.terminal.game.GameMain.runLoop(GameMain.java:324)
at com.c1games.terminal.game.GameMain.startGame(GameMain.java:175)
at com.c1games.terminal.game.GameMain.main(GameMain.java:150)
at com.c1games.terminal.Terminal.main(Terminal.java:141)
Caused by: java.lang.IllegalStateException: Expected BEGIN_ARRAY but was BEGIN_OBJECT at line 1 column 2 path $
at com.google.gson.stream.JsonReader.beginArray(JsonReader.java:350)
at com.google.gson.internal.bind.CollectionTypeAdapterFactory$Adapter.read(CollectionTypeAdapterFactory.java:80)
at com.google.gson.internal.bind.CollectionTypeAdapterFactory$Adapter.read(CollectionTypeAdapterFactory.java:61)
at com.google.gson.Gson.fromJson(Gson.java:887)
… 8 more
SAPlayer 1 : Performing turn 1 of your custom algo strategy
Invalid command, couldn’t json for player 1 : {“p2Units”:[[[1,14,75.0,“1”],[1,15,75.0,“2”],[0,14,75.0,“3”],[27,14,75.0,“9”],[25,16,75.0,“10”],[24,17,75.0,“11”],[23,18,75.0,“12”],[22,19,75.0,“13”],[5,17,75.0,“14”],[6,18,75.0,“15”],[7,17,75.0,“16”],[8,18,75.0,“17”],[8,20,75.0,“19”],[9,21,75.0,“20”],[10,22,75.0,“21”],[11,23,75.0,“22”],[12,24,75.0,“23”],[13,25,75.0,“24”],[21,20,75.0,“25”],[20,21,75.0,“26”],[19,22,75.0,“27”],[18,23,75.0,“28”],[17,23,75.0,“29”],[16,23,75.0,“30”],[15,24,75.0,“31”],[14,25,75.0,“32”],[4,15,150.0,“33”]],[],[[2,14,90.0,“5”],[3,15,90.0,“6”],[4,16,90.0,“7”],[26,15,90.0,“8”],[7,18,90.0,“18”]],[],[],[[7,21,40.0,“34”]],[],[[4,15,0.0,“33”]]],“turnInfo”:[1,0,2,3],“p1Stats”:[40.0,40.0,5.0,13],“p1Units”:[[],[],[],[],[],[],[],[]],“p2Stats”:[40.0,2.0,4.0,2],“events”:{“selfDestruct”:[],“breach”:[],“damage”:[],“shield”:[],“move”:[],“spawn”:[],“death”:[],“attack”:[],“melee”:[]}}
com.google.gson.JsonSyntaxException: java.lang.IllegalStateException: Expected BEGIN_ARRAY but was BEGIN_OBJECT at line 1 column 2 path $
at com.google.gson.Gson.fromJson(Gson.java:899)
at com.google.gson.Gson.fromJson(Gson.java:852)
at com.google.gson.Gson.fromJson(Gson.java:801)
at com.c1games.terminal.game.Parser.processInputForPlayer(Parser.java:131)
at com.c1games.terminal.game.Parser.processInputBuild(Parser.java:115)
at com.c1games.terminal.game.GameMain.runLoop(GameMain.java:318)
at com.c1games.terminal.game.GameMain.startGame(GameMain.java:175)
at com.c1games.terminal.game.GameMain.main(GameMain.java:150)
at com.c1games.terminal.Terminal.main(Terminal.java:141)
Caused by: java.lang.IllegalStateException: Expected BEGIN_ARRAY but was BEGIN_OBJECT at line 1 column 2 path $
at com.google.gson.stream.JsonReader.beginArray(JsonReader.java:350)
at com.google.gson.internal.bind.CollectionTypeAdapterFactory$Adapter.read(CollectionTypeAdapterFactory.java:80)
at com.google.gson.internal.bind.CollectionTypeAdapterFactory$Adapter.read(CollectionTypeAdapterFactory.java:61)
at com.google.gson.Gson.fromJson(Gson.java:887)
… 8 more
Invalid command, couldn’t json for player 1 : {“p2Units”:[[[1,14,75.0,“1”],[1,15,75.0,“2”],[0,14,75.0,“3”],[27,14,75.0,“9”],[25,16,75.0,“10”],[24,17,75.0,“11”],[23,18,75.0,“12”],[22,19,75.0,“13”],[5,17,75.0,“14”],[6,18,75.0,“15”],[7,17,75.0,“16”],[8,18,75.0,“17”],[8,20,75.0,“19”],[9,21,75.0,“20”],[10,22,75.0,“21”],[11,23,75.0,“22”],[12,24,75.0,“23”],[13,25,75.0,“24”],[21,20,75.0,“25”],[20,21,75.0,“26”],[19,22,75.0,“27”],[18,23,75.0,“28”],[17,23,75.0,“29”],[16,23,75.0,“30”],[15,24,75.0,“31”],[14,25,75.0,“32”],[4,15,150.0,“33”]],[],[[2,14,90.0,“5”],[3,15,90.0,“6”],[4,16,90.0,“7”],[26,15,90.0,“8”],[7,18,90.0,“18”]],[],[],[[7,20,40.0,“34”]],[],[[4,15,0.0,“33”]]],“turnInfo”:[1,0,3,4],“p1Stats”:[40.0,40.0,5.0,13],“p1Units”:[[],[],[],[],[],[],[],[]],“p2Stats”:[40.0,2.0,4.0,2],“events”:{“selfDestruct”:[],“breach”:[],“damage”:[],“shield”:[],“move”:[[[7,21],[7,20],[27,27],5,“34”,2]],“spawn”:[],“death”:[],“attack”:[],“melee”:[]}}

text omitted to fit post character maximum

com.google.gson.JsonSyntaxException: java.lang.IllegalStateException: Expected BEGIN_ARRAY but was BEGIN_OBJECT at line 1 column 2 path $
at com.google.gson.Gson.fromJson(Gson.java:899)
at com.google.gson.Gson.fromJson(Gson.java:852)
at com.google.gson.Gson.fromJson(Gson.java:801)
at com.c1games.terminal.game.Parser.processInputForPlayer(Parser.java:131)
at com.c1games.terminal.game.Parser.processInputBuild(Parser.java:115)
at com.c1games.terminal.game.GameMain.runLoop(GameMain.java:318)
at com.c1games.terminal.game.GameMain.startGame(GameMain.java:175)
at com.c1games.terminal.game.GameMain.main(GameMain.java:150)
at com.c1games.terminal.Terminal.main(Terminal.java:141)
Caused by: java.lang.IllegalStateException: Expected BEGIN_ARRAY but was BEGIN_OBJECT at line 1 column 2 path $
at com.google.gson.stream.JsonReader.beginArray(JsonReader.java:350)
at com.google.gson.internal.bind.CollectionTypeAdapterFactory$Adapter.read(CollectionTypeAdapterFactory.java:80)
at com.google.gson.internal.bind.CollectionTypeAdapterFactory$Adapter.read(CollectionTypeAdapterFactory.java:61)
at com.google.gson.Gson.fromJson(Gson.java:887)
… 8 more
Invalid command, couldn’t json for player 1 : {“p2Units”:[[[1,14,75.0,“1”],[1,15,75.0,“2”],[0,14,75.0,“3”],[27,14,75.0,“9”],[25,16,75.0,“10”],[24,17,75.0,“11”],[23,18,75.0,“12”],[22,19,75.0,“13”],[5,17,75.0,“14”],[6,18,75.0,“15”],[7,17,75.0,“16”],[8,18,75.0,“17”],[8,20,75.0,“19”],[9,21,75.0,“20”],[10,22,75.0,“21”],[11,23,75.0,“22”],[12,24,75.0,“23”],[13,25,75.0,“24”],[21,20,75.0,“25”],[20,21,75.0,“26”],[19,22,75.0,“27”],[18,23,75.0,“28”],[17,23,75.0,“29”],[16,23,75.0,“30”],[15,24,75.0,“31”],[14,25,75.0,“32”],[4,15,150.0,“33”]],[],[[2,14,90.0,“5”],[3,15,90.0,“6”],[4,16,90.0,“7”],[26,15,90.0,“8”],[7,18,90.0,“18”]],[],[],[[8,19,40.0,“34”]],[],[[4,15,0.0,“33”]]],“turnInfo”:[1,0,11,12],“p1Stats”:[40.0,40.0,5.0,13],“p1Units”:[[],[],[],[],[],[],[],[]],“p2Stats”:[40.0,2.0,4.0,2],“events”:{“selfDestruct”:[],“breach”:[],“damage”:[],“shield”:[],“move”:[[[7,19],[8,19],[27,27],5,“34”,2]],“spawn”:[],“death”:[],“attack”:[],“melee”:[]}}
com.google.gson.JsonSyntaxException: java.lang.IllegalStateException: Expected BEGIN_ARRAY but was BEGIN_OBJECT at line 1 column 2 path $
at com.google.gson.Gson.fromJson(Gson.java:899)
at com.google.gson.Gson.fromJson(Gson.java:852)
at com.google.gson.Gson.fromJson(Gson.java:801)
at com.c1games.terminal.game.Parser.processInputForPlayer(Parser.java:131)
at com.c1games.terminal.game.Parser.processInputDeploy(Parser.java:239)
at com.c1games.terminal.game.GameMain.runLoop(GameMain.java:324)
at com.c1games.terminal.game.GameMain.startGame(GameMain.java:175)
at com.c1games.terminal.game.GameMain.main(GameMain.java:150)
at com.c1games.terminal.Terminal.main(Terminal.java:141)
Caused by: java.lang.IllegalStateException: Expected BEGIN_ARRAY but was BEGIN_OBJECT at line 1 column 2 path $
at com.google.gson.stream.JsonReader.beginArray(JsonReader.java:350)
at com.google.gson.internal.bind.CollectionTypeAdapterFactory$Adapter.read(CollectionTypeAdapterFactory.java:80)
at com.google.gson.internal.bind.CollectionTypeAdapterFactory$Adapter.read(CollectionTypeAdapterFactory.java:61)
at com.google.gson.Gson.fromJson(Gson.java:887)
… 8 more
SAPlayer 1 : Performing turn 6 of your custom algo strategy
Invalid command, couldn’t json for player 1 : {“p2Units”:[[[1,14,75.0,“1”],[1,15,75.0,“2”],[0,14,75.0,“3”],[27,14,75.0,“9”],[25,16,75.0,“10”],[24,17,75.0,“11”],[23,18,75.0,“12”],[22,19,75.0,“13”],[5,17,75.0,“14”],[6,18,75.0,“15”],[7,17,75.0,“16”],[8,18,75.0,“17”],[8,20,75.0,“19”],[9,21,75.0,“20”],[10,22,75.0,“21”],[11,23,75.0,“22”],[12,24,75.0,“23”],[13,25,75.0,“24”],[21,20,75.0,“25”],[20,21,75.0,“26”],[19,22,75.0,“27”],[18,23,75.0,“28”],[17,23,75.0,“29”],[16,23,75.0,“30”],[15,24,75.0,“31”],[14,25,75.0,“32”],[4,15,150.0,“33”]],[],[[2,14,90.0,“5”],[3,15,90.0,“6”],[4,16,90.0,“7”],[26,15,90.0,“8”],[7,18,90.0,“18”]],[],[],[[8,19,40.0,“34”]],[],[[4,15,0.0,“33”]]],“turnInfo”:[1,0,12,13],“p1Stats”:[40.0,40.0,5.0,13],“p1Units”:[[],[],[],[],[],[],[],[]],“p2Stats”:[40.0,2.0,4.0,2],“events”:{“selfDestruct”:[],“breach”:[],“damage”:[],“shield”:[],“move”:[],“spawn”:[],“death”:[],“attack”:[],“melee”:[]}}
com.google.gson.JsonSyntaxException: java.lang.IllegalStateException: Expected BEGIN_ARRAY but was BEGIN_OBJECT at line 1 column 2 path $
at com.google.gson.Gson.fromJson(Gson.java:899)
at com.google.gson.Gson.fromJson(Gson.java:852)
at com.google.gson.Gson.fromJson(Gson.java:801)
at com.c1games.terminal.game.Parser.processInputForPlayer(Parser.java:131)
at com.c1games.terminal.game.Parser.processInputBuild(Parser.java:115)
at com.c1games.terminal.game.GameMain.runLoop(GameMain.java:318)
at com.c1games.terminal.game.GameMain.startGame(GameMain.java:175)
at com.c1games.terminal.game.GameMain.main(GameMain.java:150)
at com.c1games.terminal.Terminal.main(Terminal.java:141)
Caused by: java.lang.IllegalStateException: Expected BEGIN_ARRAY but was BEGIN_OBJECT at line 1 column 2 path $
at com.google.gson.stream.JsonReader.beginArray(JsonReader.java:350)
at com.google.gson.internal.bind.CollectionTypeAdapterFactory$Adapter.read(CollectionTypeAdapterFactory.java:80)
at com.google.gson.internal.bind.CollectionTypeAdapterFactory$Adapter.read(CollectionTypeAdapterFactory.java:61)
at com.google.gson.Gson.fromJson(Gson.java:887)
… 8 more
Invalid command, couldn’t json for player 1 : {“p2Units”:[[[1,14,75.0,“1”],[1,15,75.0,“2”],[0,14,75.0,“3”],[27,14,75.0,“9”],[25,16,75.0,“10”],[24,17,75.0,“11”],[23,18,75.0,“12”],[22,19,75.0,“13”],[5,17,75.0,“14”],[6,18,75.0,“15”],[7,17,75.0,“16”],[8,18,75.0,“17”],[8,20,75.0,“19”],[9,21,75.0,“20”],[10,22,75.0,“21”],[11,23,75.0,“22”],[12,24,75.0,“23”],[13,25,75.0,“24”],[21,20,75.0,“25”],[20,21,75.0,“26”],[19,22,75.0,“27”],[18,23,75.0,“28”],[17,23,75.0,“29”],[16,23,75.0,“30”],[15,24,75.0,“31”],[14,25,75.0,“32”],[4,15,150.0,“33”]],[],[[2,14,90.0,“5”],[3,15,90.0,“6”],[4,16,90.0,“7”],[26,15,90.0,“8”],[7,18,90.0,“18”]],[],[],[[8,19,40.0,“34”]],[],[[4,15,0.0,“33”]]],“turnInfo”:[1,0,13,14],“p1Stats”:[40.0,40.0,5.0,13],“p1Units”:[[],[],[],[],[],[],[],[]],“p2Stats”:[40.0,2.0,4.0,2],“events”:{“selfDestruct”:[],“breach”:[],“damage”:[],“shield”:[],“move”:[],“spawn”:[],“death”:[],“attack”:[],“melee”:[]}}
com.google.gson.JsonSyntaxException: java.lang.IllegalStateException: Expected BEGIN_ARRAY but was BEGIN_OBJECT at line 1 column 2 path $
at com.google.gson.Gson.fromJson(Gson.java:899)
at com.google.gson.Gson.fromJson(Gson.java:852)
at com.google.gson.Gson.fromJson(Gson.java:801)
at com.c1games.terminal.game.Parser.processInputForPlayer(Parser.java:131)
at com.c1games.terminal.game.Parser.processInputDeploy(Parser.java:239)
at com.c1games.terminal.game.GameMain.runLoop(GameMain.java:324)
at com.c1games.terminal.game.GameMain.startGame(GameMain.java:175)
at com.c1games.terminal.game.GameMain.main(GameMain.java:150)
at com.c1games.terminal.Terminal.main(Terminal.java:141)
Caused by: java.lang.IllegalStateException: Expected BEGIN_ARRAY but was BEGIN_OBJECT at line 1 column 2 path $
at com.google.gson.stream.JsonReader.beginArray(JsonReader.java:350)
at com.google.gson.internal.bind.CollectionTypeAdapterFactory$Adapter.read(CollectionTypeAdapterFactory.java:80)
at com.google.gson.internal.bind.CollectionTypeAdapterFactory$Adapter.read(CollectionTypeAdapterFactory.java:61)
at com.google.gson.Gson.fromJson(Gson.java:887)
… 8 more
SAPlayer 1 : Performing turn 7 of your custom algo strategy
Invalid command, couldn’t json for player 1 : {“p2Units”:[[[1,14,75.0,“1”],[1,15,75.0,“2”],[0,14,75.0,“3”],[27,14,75.0,“9”],[25,16,75.0,“10”],[24,17,75.0,“11”],[23,18,75.0,“12”],[22,19,75.0,“13”],[5,17,75.0,“14”],[6,18,75.0,“15”],[7,17,75.0,“16”],[8,18,75.0,“17”],[8,20,75.0,“19”],[9,21,75.0,“20”],[10,22,75.0,“21”],[11,23,75.0,“22”],[12,24,75.0,“23”],[13,25,75.0,“24”],[21,20,75.0,“25”],[20,21,75.0,“26”],[19,22,75.0,“27”],[18,23,75.0,“28”],[17,23,75.0,“29”],[16,23,75.0,“30”],[15,24,75.0,“31”],[14,25,75.0,“32”],[4,15,150.0,“33”]],[],[[2,14,90.0,“5”],[3,15,90.0,“6”],[4,16,90.0,“7”],[26,15,90.0,“8”],[7,18,90.0,“18”]],[],[],[[8,19,40.0,“34”]],[],[[4,15,0.0,“33”]]],“turnInfo”:[1,0,14,15],“p1Stats”:[40.0,40.0,5.0,13],“p1Units”:[[],[],[],[],[],[],[],[]],“p2Stats”:[40.0,2.0,4.0,2],“events”:{“selfDestruct”:[],“breach”:[],“damage”:[],“shield”:[],“move”:[],“spawn”:[],“death”:[],“attack”:[],“melee”:[]}}
com.google.gson.JsonSyntaxException: java.lang.IllegalStateException: Expected BEGIN_ARRAY but was BEGIN_OBJECT at line 1 column 2 path $
at com.google.gson.Gson.fromJson(Gson.java:899)
at com.google.gson.Gson.fromJson(Gson.java:852)
at com.google.gson.Gson.fromJson(Gson.java:801)
at com.c1games.terminal.game.Parser.processInputForPlayer(Parser.java:131)
at com.c1games.terminal.game.Parser.processInputBuild(Parser.java:115)
at com.c1games.terminal.game.GameMain.runLoop(GameMain.java:318)
at com.c1games.terminal.game.GameMain.startGame(GameMain.java:175)
at com.c1games.terminal.game.GameMain.main(GameMain.java:150)
at com.c1games.terminal.Terminal.main(Terminal.java:141)
Caused by: java.lang.IllegalStateException: Expected BEGIN_ARRAY but was BEGIN_OBJECT at line 1 column 2 path $
at com.google.gson.stream.JsonReader.beginArray(JsonReader.java:350)
at com.google.gson.internal.bind.CollectionTypeAdapterFactory$Adapter.read(CollectionTypeAdapterFactory.java:80)
at com.google.gson.internal.bind.CollectionTypeAdapterFactory$Adapter.read(CollectionTypeAdapterFactory.java:61)
at com.google.gson.Gson.fromJson(Gson.java:887)
… 8 more
Invalid command, couldn’t json for player 1 : {“p2Units”:[[[1,14,75.0,“1”],[1,15,75.0,“2”],[0,14,75.0,“3”],[27,14,75.0,“9”],[25,16,75.0,“10”],[24,17,75.0,“11”],[23,18,75.0,“12”],[22,19,75.0,“13”],[5,17,75.0,“14”],[6,18,75.0,“15”],[7,17,75.0,“16”],[8,18,75.0,“17”],[8,20,75.0,“19”],[9,21,75.0,“20”],[10,22,75.0,“21”],[11,23,75.0,“22”],[12,24,75.0,“23”],[13,25,75.0,“24”],[21,20,75.0,“25”],[20,21,75.0,“26”],[19,22,75.0,“27”],[18,23,75.0,“28”],[17,23,75.0,“29”],[16,23,75.0,“30”],[15,24,75.0,“31”],[14,25,75.0,“32”],[4,15,150.0,“33”]],[],[[2,14,90.0,“5”],[3,15,90.0,“6”],[4,16,90.0,“7”],[26,15,90.0,“8”],[7,18,90.0,“18”]],[],[],[[9,19,40.0,“34”]],[],[[4,15,0.0,“33”]]],“turnInfo”:[1,0,15,16],“p1Stats”:[40.0,40.0,5.0,13],“p1Units”:[[],[],[],[],[],[],[],[]],“p2Stats”:[40.0,2.0,4.0,2],“events”:{“selfDestruct”:[],“breach”:[],“damage”:[],“shield”:[],“move”:[[[8,19],[9,19],[27,27],5,“34”,2]],“spawn”:[],“death”:[],“attack”:[],“melee”:[]}}
com.google.gson.JsonSyntaxException: java.lang.IllegalStateException: Expected BEGIN_ARRAY but was BEGIN_OBJECT at line 1 column 2 path $
at com.google.gson.Gson.fromJson(Gson.java:899)
at com.google.gson.Gson.fromJson(Gson.java:852)
at com.google.gson.Gson.fromJson(Gson.java:801)
at com.c1games.terminal.game.Parser.processInputForPlayer(Parser.java:131)
at com.c1games.terminal.game.Parser.processInputDeploy(Parser.java:239)
at com.c1games.terminal.game.GameMain.runLoop(GameMain.java:324)
at com.c1games.terminal.game.GameMain.startGame(GameMain.java:175)
at com.c1games.terminal.game.GameMain.main(GameMain.java:150)
at com.c1games.terminal.Terminal.main(Terminal.java:141)
Caused by: java.lang.IllegalStateException: Expected BEGIN_ARRAY but was BEGIN_OBJECT at line 1 column 2 path $
at com.google.gson.stream.JsonReader.beginArray(JsonReader.java:350)
at com.google.gson.internal.bind.CollectionTypeAdapterFactory$Adapter.read(CollectionTypeAdapterFactory.java:80)
at com.google.gson.internal.bind.CollectionTypeAdapterFactory$Adapter.read(CollectionTypeAdapterFactory.java:61)
at com.google.gson.Gson.fromJson(Gson.java:887)
… 8 more
Winner (p1 perspective, 1 = p1 2 = p2): 1
Waiting to exit finished game.
SAPlayer 1 : Performing turn 8 of your custom algo strategy
SAPlayer 1 : Got end state, game over. Stopping algo.
sent game end playerIndex: 0
sent game end playerIndex: 1
sent game end playerIndex: 0
sent game end playerIndex: 1
Done waiting now exiting finished game.
Hard Exiting Now
Closing stream
Closing playerIndex: 0
Closing stream
Closing playerIndex: 1
Exited for loop
End of main
Closing stream
Closing stream

1 Like