[z2127] Improve pathfinding for swimming mobs, also consider dynamic flying as flying

(based on commit [12193] - 9b00e80)

(based on commit [s1753] - bfe4e75)