diff options
author | Pacien TRAN-GIRARD | 2016-02-22 16:22:09 +0100 |
---|---|---|
committer | Pacien TRAN-GIRARD | 2016-02-22 16:22:09 +0100 |
commit | 3897f5b7172a48ca3f878262205a7300de8055a6 (patch) | |
tree | 98572699640323b06fe925537f25870771577dfa | |
parent | 0d82e2c08f643aa0ff1410248ac0e31bdf15a257 (diff) | |
download | xblast-3897f5b7172a48ca3f878262205a7300de8055a6.tar.gz |
Fix neighbor coordinates calculation
-rw-r--r-- | src/ch/epfl/xblast/Cell.java | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/ch/epfl/xblast/Cell.java b/src/ch/epfl/xblast/Cell.java index 7673f4f..813bd5f 100644 --- a/src/ch/epfl/xblast/Cell.java +++ b/src/ch/epfl/xblast/Cell.java | |||
@@ -162,9 +162,9 @@ public final class Cell { | |||
162 | case S: | 162 | case S: |
163 | return new Cell(this.x, this.y + 1); | 163 | return new Cell(this.x, this.y + 1); |
164 | case E: | 164 | case E: |
165 | return new Cell(this.x - 1, this.y); | ||
166 | case W: | ||
167 | return new Cell(this.x + 1, this.y); | 165 | return new Cell(this.x + 1, this.y); |
166 | case W: | ||
167 | return new Cell(this.x - 1, this.y); | ||
168 | default: | 168 | default: |
169 | return null; | 169 | return null; |
170 | } | 170 | } |