public bool IsPath(int dir) { return neighbours[dir] != null && neighbours[dir].Filled && !GetBlock(dir); }
private int test2(Tile tile, int dir1, int dir2, int value) { if (!tile.IsPath(dir1) || !tile.IsPath(dir2)) return value; if (!tile.GetNeighbour(dir1).IsPath(dir2)) return value; if (!tile.GetNeighbour(dir2).IsPath(dir1)) return value; return 0; }