X-Git-Url: https://troll.desast.re/troll.git/blobdiff_plain/b327ce8704f1585747bbb5b206cc357b6fbfef51..67375eefceac8e1ff648bc76f25a450a3143535f:/src/main/java/com/codingame/game/Player.java?ds=sidebyside diff --git a/src/main/java/com/codingame/game/Player.java b/src/main/java/com/codingame/game/Player.java index 936a3f5..79d5aeb 100644 --- a/src/main/java/com/codingame/game/Player.java +++ b/src/main/java/com/codingame/game/Player.java @@ -23,10 +23,10 @@ public class Player extends AbstractMultiplayerPlayer { } // same-typed positional parameters… a disaster waiting to happen - void gameInit(int roadLength, int initialStones, long seed) { - sendInputLine(String.format("%d %d %d %d 0", + void gameInit(int roadLength, int initialStones, long seed, long salt) { + sendInputLine(String.format("%d %d %d %d %d", roadLength, initialStones, seed, - model.getMultiplier())); + model.getMultiplier(), salt)); } void sendGameTurn() { @@ -61,7 +61,7 @@ public class Player extends AbstractMultiplayerPlayer { catch (NoSuchElementException e) { type = Action.Invalid; return; } s.useDelimiter(eol); - if (s.hasNext(rest)) messageString = s.next(rest); + if (s.hasNext(rest)) messageString = s.next(rest).trim(); else messageString = ""; type = Action.Throw; }