1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-01-12 02:28:11 +02:00

Do not allow U-turns while flying. Works fine, but poor representation in

UI
This commit is contained in:
Ivan Savenko 2023-11-27 23:18:48 +02:00
parent a7c45d8ec8
commit faead7739a

View File

@ -136,6 +136,9 @@ void CPathfinder::calculatePaths()
if(neighbour->locked)
continue;
if (source.node->theNodeBefore && source.node->theNodeBefore->coord == neighbour->coord )
continue; // block U-turns
if(!hlp->isLayerAvailable(neighbour->layer))
continue;