check adjacency of pieses