equal
deleted
inserted
replaced
302 |
302 |
303 static void HandleShipLoading(Vehicle *v) |
303 static void HandleShipLoading(Vehicle *v) |
304 { |
304 { |
305 switch (v->current_order.type) { |
305 switch (v->current_order.type) { |
306 case OT_LOADING: { |
306 case OT_LOADING: { |
307 if (--v->load_unload_time_rem) return; |
307 if (--v->load_unload_time_rem != 0) return; |
308 |
308 |
309 if (CanFillVehicle(v) && ( |
309 if (CanFillVehicle(v) && ( |
310 v->current_order.flags & OF_FULL_LOAD || |
310 v->current_order.flags & OF_FULL_LOAD || |
311 (_patches.gradual_loading && !HASBIT(v->vehicle_flags, VF_LOADING_FINISHED)) |
311 (_patches.gradual_loading && !HASBIT(v->vehicle_flags, VF_LOADING_FINISHED)) |
312 )) { |
312 )) { |
734 |
734 |
735 /* Process station in the orderlist. */ |
735 /* Process station in the orderlist. */ |
736 st = GetStation(v->current_order.dest); |
736 st = GetStation(v->current_order.dest); |
737 if (st->facilities & FACIL_DOCK) { // ugly, ugly workaround for problem with ships able to drop off cargo at wrong stations |
737 if (st->facilities & FACIL_DOCK) { // ugly, ugly workaround for problem with ships able to drop off cargo at wrong stations |
738 v->BeginLoading(); |
738 v->BeginLoading(); |
739 v->current_order.flags &= OF_FULL_LOAD | OF_UNLOAD | OF_TRANSFER; |
|
740 v->current_order.flags |= OF_NON_STOP; |
|
741 ShipArrivesAt(v, st); |
739 ShipArrivesAt(v, st); |
742 |
740 |
743 SET_EXPENSES_TYPE(EXPENSES_SHIP_INC); |
741 SET_EXPENSES_TYPE(EXPENSES_SHIP_INC); |
744 if (LoadUnloadVehicle(v, true)) { |
742 if (LoadUnloadVehicle(v, true)) { |
745 InvalidateWindow(WC_SHIPS_LIST, v->owner); |
743 InvalidateWindow(WC_SHIPS_LIST, v->owner); |