path detection in flood scenario