From 2a9c53c2715aae687335b7c842e4142973f28ad7 Mon Sep 17 00:00:00 2001 From: JBM Date: Sun, 24 May 2020 17:51:50 +0200 Subject: [PATCH] Cleanup and meta updates --- PLAN.org | 5 ++++- src/main/java/com/codingame/game/Referee.java | 18 +++++++++--------- .../resources/view/assets/avatar_frame.xcf | Bin 0 -> 15919 bytes 3 files changed, 13 insertions(+), 10 deletions(-) create mode 100644 src/main/resources/view/assets/avatar_frame.xcf diff --git a/PLAN.org b/PLAN.org index 8872d2f..a73572d 100644 --- a/PLAN.org +++ b/PLAN.org @@ -5,12 +5,15 @@ * DONE easter egg for YannT * DONE messages * TODO referee cleanup + +That one's probably never going to be DONE ^^' + * DONE left win bias bug * DONE upgrade deps * DONE Timings * TODO Protocol * DONE fenceposts -* Quotes +* Quotes to include Trolls, it is said, were bred by Melkor because he desired a race as powerful as the giant Ents, the Tree-herds. David Day in Tolkien : The Illustrated Encyclopaedia (1993), p. 226 diff --git a/src/main/java/com/codingame/game/Referee.java b/src/main/java/com/codingame/game/Referee.java index b678534..979e283 100644 --- a/src/main/java/com/codingame/game/Referee.java +++ b/src/main/java/com/codingame/game/Referee.java @@ -30,16 +30,16 @@ public class Referee extends AbstractReferee { gameManager.getPlayer(0).model = model.p0; gameManager.getPlayer(1).model = model.p1; - for (Player p : gameManager.getPlayers()) { - p.sendInputLine(String.format("%d %d", model.roadLength, model.initialStones)); + for (Player p: gameManager.getPlayers()) { + p.sendInputLine(String.format("%d %d", + model.roadLength, + model.initialStones)); } view.init(model); - gameManager.getPlayer(0).view = view.p0; gameManager.getPlayer(1).view = view.p1; - - gameManager.setFrameDuration(2000); // XXX + gameManager.setFrameDuration(2000); } @Override @@ -56,10 +56,10 @@ public class Referee extends AbstractReferee { for (Player player : gameManager.getActivePlayers()) { Model.Player p = player.model; { - int trollDistance = p.getTrollDistance(); - int stones = p.getStones(); - int oppStones = p.getOppStones(); - player.sendInputLine(String.format("%d %d %d", trollDistance, stones, oppStones)); + player.sendInputLine(String.format("%d %d %d", + p.getTrollDistance(), + p.getStones(), + p.getOppStones())); } player.execute(); } diff --git a/src/main/resources/view/assets/avatar_frame.xcf b/src/main/resources/view/assets/avatar_frame.xcf new file mode 100644 index 0000000000000000000000000000000000000000..a4f839c6ffdcefa8e571b28dd785bbb01b24eeb9 GIT binary patch literal 15919 zcmeHu2V7Lg_VB%Tdx51bRf>gb10$lMpn|F}d5+-Z zQBVYO@Hv4K3(i@9D4iCZ9-K`aG^Op-#96aqXDh|2Bw<0kPv8E7 zhoTreoHSw9ro~N7oS8V!Cjf)C^WvsV z_6f$nkU)r@@+;9HKKO^C7tNnDd1}J!IG>PUz!o>b1f=c9vlABhB+Q-~A3GoANSrop ze(VAtoW4<*1e+#CZEp0@X9?2w2!UPF8%08}+vrC4E(jxs`Yi1;Z}O~I6e$IV2ABue z9EBs7gAbDc4$)C+g%AcnwP+M>)+nrO6!vKpRy7K%8-;Beg*6aH^`S{clPm*=>PF@J z3Sj_LD-`D81K6@rxG|Fe+4?c3ts#Kc-lKBiW1bV(c9Q^6y!ErD1zgmT5LG`AXnTP` zt&p$TC4x7*O<>Dc1o}@PFz6706xE+{;De}Ud~+&PRk2eijQ(Iyba;mVFGr<>p(Ru;Z5OfZQh~wDaXim(r53Z9 zWlg4r27_MrwxsCgi|oe_?%ln^+^WpHk#Xhn`BR5?ZAzLwx^IZDyQ`QoO8gQ|71Uc` z$#S%XHaD;)BQ&9|jxo@+Rr;E$%JPze=MQgQIJRy5!ucY~NNaj-eNxAH@Jf!c7|g7x z-cVIm@Z!-U5oKar$DS)Ux8-Rl3Sx{6Kohr^d#jdvkB8QYC|2UX^ie}6912*OZNec@ z%cW0Ah;Fvv0gg4%+L%lO7Ych5tNAEZPeST}XDTf!o`;G>Tyqqs>V2%-qU5X1^}346 zYJFXU$z(QLEH<1Cj*U80Vpi}KTwQ+Z`R~)O{q*Qr{+p7wx*C10)IitO*EbkhNX>Cl zoVwS+Vo3eg^7iul4+f8qS-5n=mwOMLxsZ1CMk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