diff options
author | Jérémy Zurcher <jeremy@asynk.ch> | 2014-11-16 16:07:19 +0100 |
---|---|---|
committer | Jérémy Zurcher <jeremy@asynk.ch> | 2014-11-16 16:07:19 +0100 |
commit | d45fe0d6b1ad80016a4b85709e8d0ec7b15f410d (patch) | |
tree | a9f8465c0baf38eebc8173fbe2ce9a18c8b6dc03 /core/src/ch/asynk/tankontank/game | |
parent | 397bfdac6ce93ea7a72601e216443db690e9e023 (diff) | |
download | RustAndDust-d45fe0d6b1ad80016a4b85709e8d0ec7b15f410d.zip RustAndDust-d45fe0d6b1ad80016a4b85709e8d0ec7b15f410d.tar.gz |
Ctrl: add Player getPlayer(Army)
Diffstat (limited to 'core/src/ch/asynk/tankontank/game')
-rw-r--r-- | core/src/ch/asynk/tankontank/game/Ctrl.java | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/core/src/ch/asynk/tankontank/game/Ctrl.java b/core/src/ch/asynk/tankontank/game/Ctrl.java index 6dc1c44..78fdeba 100644 --- a/core/src/ch/asynk/tankontank/game/Ctrl.java +++ b/core/src/ch/asynk/tankontank/game/Ctrl.java @@ -86,6 +86,11 @@ public class Ctrl implements Disposable map.dispose(); } + public Player getPlayer(Army army) + { + return (player.is(army) ? player : opponent); + } + public boolean isInAction() { return (state != selectState); |