public static Coords[] intervening(Coords a, Coords b) { IdealHex aHex = new IdealHex(a); IdealHex bHex = new IdealHex(b);
public static Coords[] intervening(Coords src, Coords dest) { IdealHex iSrc = new IdealHex(src); IdealHex iDest = new IdealHex(dest);
    public static Coords[] intervening(Coords a, Coords b) {        IdealHex aHex = new IdealHex(a);        IdealHex bHex = new IdealHex(b);                // test any hexes that we think might be in the way        int minumumX = Math.min(a.x, b.x);        int minumumY = Math.min(a.y, b.y);        int rangeWidth = Math.abs(a.x - b.x) + 1;        int rangeHeight = Math.abs(a.y - b.y) + 1;                // adjust if we're along the x line        if (a.y == b.y && (a.x & 1) == (b.x & 1)) {            rangeHeight += 2;            minumumY--;        }                int rangeArea = rangeWidth * rangeHeight; // hexes to test        Vector trueCoords = new Vector();                for (int i = 0; i < rangeArea; i++) {            Coords c = new Coords(i % rangeWidth + minumumX, i / rangeWidth + minumumY);            IdealHex cHex = new IdealHex(c);            // test the polygon            if (cHex.isIntersectedBy(aHex.cx, aHex.cy, bHex.cx, bHex.cy)) {                trueCoords.addElement(c);            }        }                // make a nice array to return        Coords[] trueArray = new Coords[trueCoords.size()];        trueCoords.copyInto(trueArray);        //        System.out.print("compute: intervening from " + a.getBoardNum() + " to " + b.getBoardNum() + " [ ");//        for (Enumeration i = trueCoords.elements(); i.hasMoreElements();) {//            final Coords coords = (Coords)i.nextElement();//            System.out.print(coords.getBoardNum() + " ");//        }//        System.out.print("]\n");                return trueArray;    }