mirror of https://github.com/OpenTTD/OpenTTD.git
(svn r21989) -Fix (r21954): Vehicle status bar glitches on speed changes.
This commit is contained in:
parent
d82475cf88
commit
9aa185572b
|
@ -340,9 +340,7 @@ struct GroundVehicle : public SpecializedVehicle<T, Type> {
|
|||
FORCEINLINE void SetLastSpeed()
|
||||
{
|
||||
if (this->cur_speed != this->gcache.last_speed) {
|
||||
if ((this->gcache.last_speed == 0) != (this->cur_speed == 0)) {
|
||||
SetWindowWidgetDirty(WC_VEHICLE_VIEW, this->index, VVW_WIDGET_START_STOP_VEH);
|
||||
}
|
||||
SetWindowWidgetDirty(WC_VEHICLE_VIEW, this->index, VVW_WIDGET_START_STOP_VEH);
|
||||
this->gcache.last_speed = this->cur_speed;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue