(svn r22713) -Feature: [NewGRF] Per vehicle custom cargo ageing period.

This commit is contained in:
michi_cc
2011-08-03 20:55:08 +00:00
parent 442b92ff33
commit 08b7981f37
17 changed files with 74 additions and 16 deletions

View File

@@ -30,6 +30,7 @@
#include "autoreplace_gui.h"
#include "company_base.h"
#include "order_backup.h"
#include "ship.h"
#include "table/strings.h"
@@ -373,9 +374,15 @@ CommandCost CmdRefitVehicle(TileIndex tile, DoCommandFlag flags, uint32 p1, uint
break;
case VEH_SHIP:
v->InvalidateNewGRFCacheOfChain();
v->colourmap = PAL_NONE; // invalidate vehicle colour map
Ship::From(v)->UpdateCache();
break;
case VEH_AIRCRAFT:
v->InvalidateNewGRFCacheOfChain();
v->colourmap = PAL_NONE; // invalidate vehicle colour map
UpdateAircraftCache(Aircraft::From(v));
break;
default: NOT_REACHED();