diff options
author | Jérémy Zurcher <jeremy@asynk.ch> | 2016-01-09 18:55:44 +0100 |
---|---|---|
committer | Jérémy Zurcher <jeremy@asynk.ch> | 2016-01-09 18:55:44 +0100 |
commit | 39bcc7375c7d9c17922ec76be6f7834ae8211b82 (patch) | |
tree | 3d1da847a9da887cb9130b03869765af0a598df6 /core/src/ch/asynk/rustanddust/engine | |
parent | 9154d76c30f106e4811a99b34f35c8923967195f (diff) | |
download | RustAndDust-39bcc7375c7d9c17922ec76be6f7834ae8211b82.zip RustAndDust-39bcc7375c7d9c17922ec76be6f7834ae8211b82.tar.gz |
Tile: add constructor param int capacity (of the stack)
Diffstat (limited to 'core/src/ch/asynk/rustanddust/engine')
-rw-r--r-- | core/src/ch/asynk/rustanddust/engine/Tile.java | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/core/src/ch/asynk/rustanddust/engine/Tile.java b/core/src/ch/asynk/rustanddust/engine/Tile.java index 3c931cd..7bb2fe7 100644 --- a/core/src/ch/asynk/rustanddust/engine/Tile.java +++ b/core/src/ch/asynk/rustanddust/engine/Tile.java @@ -47,19 +47,19 @@ public abstract class Tile implements Drawable, Disposable, Iterable<Pawn> public abstract boolean atLeastOneMove(Pawn pawn); public abstract boolean blockLineOfSight(Tile from, Tile to); - protected Tile(int col, int row, Faction defaultFaction) + protected Tile(int col, int row, int capacity, Faction defaultFaction) { this.col = col; this.row = row; - this.stack = new ArrayListIt<Pawn>(); + this.stack = new ArrayListIt<Pawn>(capacity); this.curFaction = defaultFaction; this.prevFaction = defaultFaction; this.objective = Objective.NONE; } - public Tile(float x, float y, int col, int row, TextureAtlas atlas, Faction defaultFaction) + public Tile(float x, float y, int col, int row, int capacity, Faction defaultFaction, TextureAtlas atlas) { - this(col, row, defaultFaction); + this(col, row, capacity, defaultFaction); this.x = x; this.y = y; this.overlays = new StackedImages(atlas); |