diff options
| author | Pedro J. Estébanez | 2017-08-16 13:46:10 +0200 |
|---|---|---|
| committer | Pedro J. Estébanez | 2017-08-16 13:46:10 +0200 |
| commit | 71a496803c6c8cd840a88644529f12d93f2603fc (patch) | |
| tree | 3992432bd4806f3c5e06872ed1d81b8d2138cd8f /scene/2d/navigation2d.cpp | |
| parent | 603b262d9bfe757e4a009a80f1c80230d35512ba (diff) | |
| download | godot-71a496803c6c8cd840a88644529f12d93f2603fc.tar.gz godot-71a496803c6c8cd840a88644529f12d93f2603fc.tar.zst godot-71a496803c6c8cd840a88644529f12d93f2603fc.zip | |
Diffstat (limited to 'scene/2d/navigation2d.cpp')
| -rw-r--r-- | scene/2d/navigation2d.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/scene/2d/navigation2d.cpp b/scene/2d/navigation2d.cpp index e57983890..383236b4c 100644 --- a/scene/2d/navigation2d.cpp +++ b/scene/2d/navigation2d.cpp @@ -646,7 +646,8 @@ debug path break; } - path.push_back(begin_point); + if (path[path.size() - 1].distance_to(begin_point) > CMP_EPSILON) + path.push_back(begin_point); path.invert(); } |
