diff options
Diffstat (limited to 'core')
-rw-r--r-- | core/src/ch/asynk/rustanddust/engine/SearchBoard.java | 6 | ||||
-rw-r--r-- | core/test/ch/asynk/rustanddust/LineOfSightTest.java | 2 |
2 files changed, 7 insertions, 1 deletions
diff --git a/core/src/ch/asynk/rustanddust/engine/SearchBoard.java b/core/src/ch/asynk/rustanddust/engine/SearchBoard.java index f869e32..6a1e6bb 100644 --- a/core/src/ch/asynk/rustanddust/engine/SearchBoard.java +++ b/core/src/ch/asynk/rustanddust/engine/SearchBoard.java @@ -260,6 +260,12 @@ public class SearchBoard a[5] = null; } + public List<Node> buildLineOfSight(int x0, int y0, int x1, int y1, boolean clearVisibility) + { + lineOfSight(x0, y0, x1, y1, clearVisibility); + return los; + } + public int possibleTargetsFrom(Pawn shooter, Collection<Pawn> targets) { targets.clear(); diff --git a/core/test/ch/asynk/rustanddust/LineOfSightTest.java b/core/test/ch/asynk/rustanddust/LineOfSightTest.java index 86a85df..2722c45 100644 --- a/core/test/ch/asynk/rustanddust/LineOfSightTest.java +++ b/core/test/ch/asynk/rustanddust/LineOfSightTest.java @@ -37,7 +37,7 @@ public class LineOfSightTest private List<Node> lineOfSight(int x0, int y0, int x1, int y1) { - return sb.lineOfSight(x0, y0, x1, y1, true); + return sb.buildLineOfSight(x0, y0, x1, y1, true); } // from bottom left |