1
0
Fork 0

Fix #13908: Require double click on order to change stop location. (#13913)

pull/13917/head
Peter Nelson 2025-03-28 20:23:18 +00:00 committed by GitHub
parent e49150f9ca
commit 0829604b4f
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 1 deletions

View File

@ -1228,7 +1228,7 @@ public:
/* Deselect clicked order */
this->selected_order = -1;
} else if (sel == this->selected_order) {
if (this->vehicle->type == VEH_TRAIN && sel < this->vehicle->GetNumOrders()) {
if (click_count > 1 && this->vehicle->type == VEH_TRAIN && sel < this->vehicle->GetNumOrders()) {
Command<CMD_MODIFY_ORDER>::Post(STR_ERROR_CAN_T_MODIFY_THIS_ORDER,
this->vehicle->tile, this->vehicle->index, sel,
MOF_STOP_LOCATION, (this->vehicle->GetOrder(sel)->GetStopLocation() + 1) % OSL_END);