Fixed bugs better path finding