Skip to content

Commit 4da4956

Browse files
committed
Fix waypoint drag and drop.
The fix for #3037 wasn't complete. It seems this `- 1` was here to work around the UI wrongly having two takeoff points... Now that we fixed that, this also needs to go. Fixes #3059. (cherry picked from commit 02c9fe9)
1 parent 618159c commit 4da4956

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

game/server/waypoints/routes.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ def set_position(
5050
if waypoint_idx == 0:
5151
raise HTTPException(status_code=status.HTTP_403_FORBIDDEN)
5252

53-
waypoint = flight.flight_plan.waypoints[waypoint_idx - 1]
53+
waypoint = flight.flight_plan.waypoints[waypoint_idx]
5454
waypoint.position = Point.from_latlng(
5555
LatLng(position.lat, position.lng), game.theater.terrain
5656
)

0 commit comments

Comments
 (0)