summaryrefslogtreecommitdiffstats
path: root/core
diff options
context:
space:
mode:
authorJérémy Zurcher <jeremy@asynk.ch>2014-10-13 00:32:09 +0200
committerJérémy Zurcher <jeremy@asynk.ch>2014-10-13 00:32:09 +0200
commit7ec5e1ae3d5ba5324481a93c9cb63503ed7f8587 (patch)
treede4cf3fe30198cfdf9c4a21132976e9ae9b8924f /core
parent27ddaf24edbc47498416b61d216a0f93d2de0e0d (diff)
downloadRustAndDust-7ec5e1ae3d5ba5324481a93c9cb63503ed7f8587.zip
RustAndDust-7ec5e1ae3d5ba5324481a93c9cb63503ed7f8587.tar.gz
Player: add Iterator<Pawn> unitIterator()
Diffstat (limited to 'core')
-rw-r--r--core/src/ch/asynk/tankontank/game/Player.java6
1 files changed, 6 insertions, 0 deletions
diff --git a/core/src/ch/asynk/tankontank/game/Player.java b/core/src/ch/asynk/tankontank/game/Player.java
index 85869f8..d38d44e 100644
--- a/core/src/ch/asynk/tankontank/game/Player.java
+++ b/core/src/ch/asynk/tankontank/game/Player.java
@@ -2,6 +2,7 @@ package ch.asynk.tankontank.game;
import java.util.ArrayList;
import java.util.Random;
+import java.util.Iterator;
import com.badlogic.gdx.utils.Disposable;
@@ -98,6 +99,11 @@ public class Player implements Drawable, Disposable
flag.setPosition(x, y);
}
+ public Iterator<Pawn> unitIterator()
+ {
+ return units.iterator();
+ }
+
@Override
public void draw(Batch batch)
{