From a7cc12cff89ec38bc3e1902f83bbd6efcf4121e4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=A9my=20Zurcher?= Date: Mon, 13 Oct 2014 00:29:48 +0200 Subject: Board: add GridPoint2 getHexAt(Vector3, GridPoint2) --- core/src/ch/asynk/tankontank/engine/Board.java | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/core/src/ch/asynk/tankontank/engine/Board.java b/core/src/ch/asynk/tankontank/engine/Board.java index 17632ff..7493059 100644 --- a/core/src/ch/asynk/tankontank/engine/Board.java +++ b/core/src/ch/asynk/tankontank/engine/Board.java @@ -570,6 +570,12 @@ public abstract class Board implements Disposable return getHexAt(null, v.x, v.y); } + public GridPoint2 getHexAt(Vector3 v, GridPoint2 hex) + { + if (v == null) return null; + return getHexAt(hex, v.x, v.y); + } + public GridPoint2 getHexAt(GridPoint2 hex, float mx, float my) { if (hex == null) hex = new GridPoint2(); -- cgit v1.1-2-g2b99