diff options
author | Jannis Harder <harder@informatik.uni-luebeck.de> | 2011-05-25 15:51:34 +0200 |
---|---|---|
committer | Jannis Harder <harder@informatik.uni-luebeck.de> | 2011-05-25 15:51:34 +0200 |
commit | 157bd4f60635dc27d2c9baebea5589455b05f17b (patch) | |
tree | b85dda7fea57ca297c79f26c3764954683465eec /mock/jrummikub/model | |
parent | e3b5a0790dbb5c9ffeb5c23db81528faef3a1a05 (diff) | |
download | JRummikub-157bd4f60635dc27d2c9baebea5589455b05f17b.tar JRummikub-157bd4f60635dc27d2c9baebea5589455b05f17b.zip |
Tested and implemented scoring
git-svn-id: svn://sunsvr01.isp.uni-luebeck.de/swproj13/trunk@272 72836036-5685-4462-b002-a69064685172
Diffstat (limited to 'mock/jrummikub/model')
-rw-r--r-- | mock/jrummikub/model/MockRoundState.java | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/mock/jrummikub/model/MockRoundState.java b/mock/jrummikub/model/MockRoundState.java index ee483c6..1ebc575 100644 --- a/mock/jrummikub/model/MockRoundState.java +++ b/mock/jrummikub/model/MockRoundState.java @@ -104,4 +104,13 @@ public class MockRoundState implements IRoundState { } activePlayer = j; } + + @Override + public IPlayer getNthPlayer(int i) { + int j = i % players.size(); + if (j < 0) { + j += players.size(); + } + return players.get(j); + } } |