public List<DijkstraNode> getNeighbors() {
        // TODO
        // Check if on edge of map - breaks if we're on the pixel right next
        // to the edge.
        List<DijkstraNode> neighborNodeList = new ArrayList<DijkstraNode>();
        Coordinate currentCoordinate = this.getPosition();
        int currentX = currentCoordinate.getX();
        int currentY = currentCoordinate.getY();
        // since we're on a grid, treat our graph as such and determine neighbors like that
        Coordinate coordinateLeft = new Coordinate(currentX - 1, currentY);
        Coordinate coordinateUpLeft = new Coordinate(currentX - 1, currentY + 1);
        Coordinate coordinateUp = new Coordinate(currentX, currentY + 1);
        Coordinate coordinateUpRight = new Coordinate(currentX + 1, currentY + 1);
        Coordinate coordinateRight = new Coordinate(currentX + 1, currentY);
        Coordinate coordinateDownRight = new Coordinate(currentX + 1, currentY - 1);
        Coordinate coordinateDown = new Coordinate(currentX, currentY - 1);
        Coordinate coordinateDownLeft = new Coordinate(currentX - 1, currentY - 1);
        DijkstraNode nodeLeft = new DijkstraNode(coordinateLeft);
        DijkstraNode nodeUpLeft = new DijkstraNode(coordinateUpLeft);
        DijkstraNode nodeUp = new DijkstraNode(coordinateUp);
        DijkstraNode nodeUpRight = new DijkstraNode(coordinateUpRight);
        DijkstraNode nodeRight = new DijkstraNode(coordinateRight);
        DijkstraNode nodeDownRight = new DijkstraNode(coordinateDownRight);
        DijkstraNode nodeDown = new DijkstraNode(coordinateDown);
        DijkstraNode nodeDownLeft = new DijkstraNode(coordinateDownLeft);
        neighborNodeList.add(nodeLeft);
        neighborNodeList.add(nodeUpLeft);
        neighborNodeList.add(nodeUp);
        neighborNodeList.add(nodeUpRight);
        neighborNodeList.add(nodeRight);
        neighborNodeList.add(nodeDownRight);
        neighborNodeList.add(nodeDown);
        neighborNodeList.add(nodeDownLeft);
        return neighborNodeList;
    }
public List<DijkstraNode> getNeighbors() {
       
       
       
        List<DijkstraNode> neighborNodeList = new ArrayList<DijkstraNode>();
        Coordinate currentCoordinate = this.getPosition();
        int currentX = currentCoordinate.getX();
        int currentY = currentCoordinate.getY();
       
        Coordinate coordinateLeft = new Coordinate(currentX - 1, currentY);
        Coordinate coordinateUpLeft = new Coordinate(currentX - 1, currentY + 1);
        Coordinate coordinateUp = new Coordinate(currentX, currentY + 1);
        Coordinate coordinateUpRight = new Coordinate(currentX + 1, currentY + 1);
        Coordinate coordinateRight = new Coordinate(currentX + 1, currentY);
        Coordinate coordinateDownRight = new Coordinate(currentX + 1, currentY - 1);
        Coordinate coordinateDown = new Coordinate(currentX, currentY - 1);
        Coordinate coordinateDownLeft = new Coordinate(currentX - 1, currentY - 1);
        DijkstraNode nodeLeft = new DijkstraNode(coordinateLeft);
        DijkstraNode nodeUpLeft = new DijkstraNode(coordinateUpLeft);
        DijkstraNode nodeUp = new DijkstraNode(coordinateUp);
        DijkstraNode nodeUpRight = new DijkstraNode(coordinateUpRight);
        DijkstraNode nodeRight = new DijkstraNode(coordinateRight);
        DijkstraNode nodeDownRight = new DijkstraNode(coordinateDownRight);
        DijkstraNode nodeDown = new DijkstraNode(coordinateDown);
        DijkstraNode nodeDownLeft = new DijkstraNode(coordinateDownLeft);
        neighborNodeList.add(nodeLeft);
        neighborNodeList.add(nodeUpLeft);
        neighborNodeList.add(nodeUp);
        neighborNodeList.add(nodeUpRight);
        neighborNodeList.add(nodeRight);
        neighborNodeList.add(nodeDownRight);
        neighborNodeList.add(nodeDown);
        neighborNodeList.add(nodeDownLeft);
        return neighborNodeList;
    }
public list<dijkstranode> getneighbors() { list<dijkstranode> neighbornodelist = new arraylist<dijkstranode>(); coordinate currentcoordinate = this.getposition(); int currentx = currentcoordinate.getx(); int currenty = currentcoordinate.gety(); coordinate coordinateleft = new coordinate(currentx - 1, currenty); coordinate coordinateupleft = new coordinate(currentx - 1, currenty + 1); coordinate coordinateup = new coordinate(currentx, currenty + 1); coordinate coordinateupright = new coordinate(currentx + 1, currenty + 1); coordinate coordinateright = new coordinate(currentx + 1, currenty); coordinate coordinatedownright = new coordinate(currentx + 1, currenty - 1); coordinate coordinatedown = new coordinate(currentx, currenty - 1); coordinate coordinatedownleft = new coordinate(currentx - 1, currenty - 1); dijkstranode nodeleft = new dijkstranode(coordinateleft); dijkstranode nodeupleft = new dijkstranode(coordinateupleft); dijkstranode nodeup = new dijkstranode(coordinateup); dijkstranode nodeupright = new dijkstranode(coordinateupright); dijkstranode noderight = new dijkstranode(coordinateright); dijkstranode nodedownright = new dijkstranode(coordinatedownright); dijkstranode nodedown = new dijkstranode(coordinatedown); dijkstranode nodedownleft = new dijkstranode(coordinatedownleft); neighbornodelist.add(nodeleft); neighbornodelist.add(nodeupleft); neighbornodelist.add(nodeup); neighbornodelist.add(nodeupright); neighbornodelist.add(noderight); neighbornodelist.add(nodedownright); neighbornodelist.add(nodedown); neighbornodelist.add(nodedownleft); return neighbornodelist; }