I’ve read this thread, and Question about Player2 info in state.json, and Different State file many times over, but I still can’t figure this out.
I’m working in Java. My problem is closest to @MarkMyb’s. My GameState.PlayerMap and GameState.OpponentMap is always null, because the state.json file that’s passed in at the start of every turn, has these values set to null. If I change my GateState to include:
public PlayerMap Player2Map; public OpponentMap Player1Map;
then these 2 fields are populated. I understand that Player*Map will be null in each round, and only populated at the end of the match, so I can’t use it at all.
Unfortunately I can’t decipher Mark’s fix If it’s a ‘json error’, and the json file is created externally, then what was the solution? My bot always used
OpponentMap.Cells, but I don’t see how changing that would help if the json
OpponentMap is always null.
Please help! Here is my state.json (10.7 KB) created in Phase 2 Round 5.
Battleships.exe --pretty -b ../javaOP ../ME
In summary, why is my json