1
0
Fork 0

(svn r25247) [1.3] -Backport from trunk:

- Fix: 'No station' error was given, even when there was a station that way occupied or not yours [FS#5546] (r25243)
- Language updates
release/1.3
rubidium 2013-05-17 18:56:51 +00:00
parent b604bbfb3d
commit 9cb01a519b
3 changed files with 259 additions and 253 deletions

View File

@ -25,7 +25,7 @@ description.es_ES = Gráficos originales de Transport Tycoon Deluxe versión DOS
description.et_EE = Algse Transport Tycoon Deluxe DOSi (Saksa) versiooni graafika.
description.fi_FI = Alkuperäiset Saksassa julkaistun Transport Tycoon Deluxen DOS-version grafiikat.
description.fr_FR = Graphiques originaux de Transport Tycoon Deluxe (version DOS allemande).
description.gd_GB = Grafaigeachd aig an deasachadh DOS (Germailteach) tùsail aig Transport Tycoon Deluxe.
description.gd_GB = Grafaigeachd aig an deasachadh DOS (Gearmailteach) tùsail aig Transport Tycoon Deluxe.
description.gl_ES = Graficos da edición orixinal (alemá) de Transport Tycoon Deluxe para DOS.
description.hr_HR = Originalna grafika za Transport Tycoon Deluxe DOS (Njemački) izdanje.
description.hu_HU = Az eredeti Transport Tycoon Deluxe DOS (német) verziójának grafikája.

File diff suppressed because it is too large Load Diff

View File

@ -1422,6 +1422,10 @@ CommandCost RemoveFromRailBaseStation(TileArea ta, SmallVector<T *, 4> &affected
/* Count of the number of tiles removed */
int quantity = 0;
CommandCost total_cost(EXPENSES_CONSTRUCTION);
/* Accumulator for the errors seen during clearing. If no errors happen,
* and the quantity is 0 there is no station. Otherwise it will be one
* of the other error that got accumulated. */
CommandCost error;
/* Do the action for every tile into the area */
TILE_AREA_LOOP(tile, ta) {
@ -1430,6 +1434,7 @@ CommandCost RemoveFromRailBaseStation(TileArea ta, SmallVector<T *, 4> &affected
/* If there is a vehicle on ground, do not allow to remove (flood) the tile */
CommandCost ret = EnsureNoVehicleOnGround(tile);
error.AddCost(ret);
if (ret.Failed()) continue;
/* Check ownership of station */
@ -1438,6 +1443,7 @@ CommandCost RemoveFromRailBaseStation(TileArea ta, SmallVector<T *, 4> &affected
if (_current_company != OWNER_WATER) {
CommandCost ret = CheckOwnership(st->owner);
error.AddCost(ret);
if (ret.Failed()) continue;
}
@ -1497,7 +1503,7 @@ CommandCost RemoveFromRailBaseStation(TileArea ta, SmallVector<T *, 4> &affected
}
}
if (quantity == 0) return_cmd_error(STR_ERROR_THERE_IS_NO_STATION);
if (quantity == 0) return error.Failed() ? error : CommandCost(STR_ERROR_THERE_IS_NO_STATION);
for (T **stp = affected_stations.Begin(); stp != affected_stations.End(); stp++) {
T *st = *stp;