Plane: allow changing of loiter direction while loitering

useful for causing path capture failures in the sim
This commit is contained in:
Andrew Tridgell 2013-11-07 11:51:36 +11:00
parent 42aeead047
commit 53c3dff334

View File

@ -1309,6 +1309,12 @@ static void update_navigation()
case LOITER:
case RTL:
case GUIDED:
// allow loiter direction to be changed in flight
if (g.loiter_radius < 0) {
loiter.direction = -1;
} else {
loiter.direction = 1;
}
update_loiter();
break;