mirror of https://github.com/OpenTTD/OpenTTD
(svn r10812) -Fix (r10097) [FS#1093]: Make RoadVehicle::MarkDirty() mark all parts of articulated vehicles as dirty, not just the front.
parent
8c4a4baac1
commit
e0e361c890
|
@ -556,8 +556,10 @@ CommandCost CmdTurnRoadVeh(TileIndex tile, uint32 flags, uint32 p1, uint32 p2)
|
||||||
|
|
||||||
void RoadVehicle::MarkDirty()
|
void RoadVehicle::MarkDirty()
|
||||||
{
|
{
|
||||||
this->cur_image = this->GetImage(this->direction);
|
for (Vehicle *v = this; v != NULL; v = v->next) {
|
||||||
MarkAllViewportsDirty(this->left_coord, this->top_coord, this->right_coord + 1, this->bottom_coord + 1);
|
v->cur_image = v->GetImage(v->direction);
|
||||||
|
MarkAllViewportsDirty(v->left_coord, v->top_coord, v->right_coord + 1, v->bottom_coord + 1);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void RoadVehicle::UpdateDeltaXY(Direction direction)
|
void RoadVehicle::UpdateDeltaXY(Direction direction)
|
||||||
|
|
Loading…
Reference in New Issue