(svn r25648) -Change [FS#5669]: [NewGRF] Invalidate vehicle recolour palette during (un)loading.
This commit is contained in:
@@ -165,9 +165,6 @@ void Train::ConsistChanged(bool same_length)
|
||||
/* Cache wagon override sprite group. NULL is returned if there is none */
|
||||
u->tcache.cached_override = GetWagonOverrideSpriteSet(u->engine_type, u->cargo_type, u->gcache.first_engine);
|
||||
|
||||
/* Reset colour map */
|
||||
u->colourmap = PAL_NONE;
|
||||
|
||||
/* Update powered-wagon-status and visual effect */
|
||||
u->UpdateVisualEffect(true);
|
||||
|
||||
@@ -2762,7 +2759,8 @@ void Train::MarkDirty()
|
||||
{
|
||||
Train *v = this;
|
||||
do {
|
||||
v->UpdateViewport(false, false);
|
||||
v->colourmap = PAL_NONE;
|
||||
v->UpdateViewport(true, false);
|
||||
} while ((v = v->Next()) != NULL);
|
||||
|
||||
/* need to update acceleration and cached values since the goods on the train changed. */
|
||||
|
Reference in New Issue
Block a user