// jumpNoDiags is the same as jump, except that it uses the same concept but
// for paths that cannot be diagonal: in practice, this means that diagonal
// jumps and diagonal forced neighbors are only processed if they are doable
// using two cardinal movements.
jumpNoDiags is the same as jump, except that it uses the same concept but
for paths that cannot be diagonal: in practice, this means that diagonal
jumps and diagonal forced neighbors are only processed if they are doable
using two cardinal movements.
// jumpNoDiags is the same as jump except that it uses the same concept but // for paths that cannot be diagonal : in practice this means that diagonal // jumps and diagonal forced neighbors are only processed if they are doable // using two cardinal movements .
func (pr *PathRange) jumpNoDiags(p, dir, to gruid.Point, cost int) (gruid.Point, int) {
	switch {
	case dir.X == 0 || dir.Y == 0:
		return pr.jumpStraightNoDiags(p, dir, to)
	default:
		return pr.jumpDiagonalNoDiags(p, dir, to, cost)
	}
}
func ( pr * PathRange ) jumpNoDiags ( p , dir , to gruid . Point , cost int ) ( gruid . Point , int ) { switch { case dir . X == 0 || dir . Y == 0 : return pr . jumpStraightNoDiags ( p , dir , to ) default : return pr . jumpDiagonalNoDiags ( p , dir , to , cost ) } }
jumpNoDiags is the same as jump, except that it uses the same concept but
for paths that cannot be diagonal: in practice, this means that diagonal
jumps and diagonal forced neighbors are only processed if they are doable
using two cardinal movements.
jumpNoDiags is the same as jump except that it uses the same concept but for paths that cannot be diagonal : in practice this means that diagonal jumps and diagonal forced neighbors are only processed if they are doable using two cardinal movements .