summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorErich Eckner <git@eckner.net>2019-04-14 09:54:50 +0200
committerErich Eckner <git@eckner.net>2019-04-14 09:55:18 +0200
commit1476eb987537b886aa52d080ddfd812a5e21bbc7 (patch)
tree0074563439c93d9215ed1d38324decb190703643
parent77fbd6d5dccf5ea4d58be40c1afa05a901135de2 (diff)
downloadarchlinuxewe-1476eb987537b886aa52d080ddfd812a5e21bbc7.tar.xz
openttd-git 28845.5bd2b15e8-1 -> 28854.4f052fc2a-1
-rw-r--r--openttd-git/PKGBUILD8
-rw-r--r--openttd-git/signaltunnel.patch2
-rw-r--r--openttd-git/sloped-stations.patch20
-rw-r--r--openttd-git/underground.patch48
4 files changed, 38 insertions, 40 deletions
diff --git a/openttd-git/PKGBUILD b/openttd-git/PKGBUILD
index e967851a4..7f172989e 100644
--- a/openttd-git/PKGBUILD
+++ b/openttd-git/PKGBUILD
@@ -1,6 +1,6 @@
# Maintainer: Erich Eckner <arch at eckner dot net>
pkgname=openttd-git
-pkgver=28845.5bd2b15e8
+pkgver=28854.4f052fc2a
_commit=${pkgver#*.}
pkgrel=1
pkgdesc="A FOSS clone of Transport Tycoon Deluxe."
@@ -39,9 +39,9 @@ source=(
"underground.patch"
)
sha512sums=('SKIP'
- '68954ed3cdabc1e1db2381108468e0639e6c476cb724e92af682de90a5ac94f886a86457e7eafa4730d3fb09d70dff99328da2f492bb357f06c05aec852ebb67'
- '4e082b130bb6bb5b62bd52e5508c5ef2fe28a2ed427506d7c6e3b4c187477ae6cd011648437a59a06466035d784ce79638b1b014b43ad99430a1f2a63040c4b5'
- 'f31003954359745f49c3ac29dacc740a9dc71178b470589a77f5496c7429203b33d5035df22dd4e2b14cdc69154125a674b75bde9de9cadbf5d6a49bc8575fcf')
+ 'a7ffb1fb62976e690b6fcc021f7acdf8418dc40cedd102e3e05b047a78172e0cabf2a16f905e2ee1f2ab40b82616fd6bb6247e6bc390886e532cef3f27f20d88'
+ '17c40a66ad0ab15e3828fb8689ecdafddf9f4bca61ef85bec62d7f37731e26ddaeba85334ae86df59d0f599f18e7e4dfa371061ff38fe61810b9f83ab499763b'
+ '78012d9cee7703e81bbe2c54088319a98c562cb97f71999d427b209c7a3105f0ccf2021b6e13344ba1bc77b503e1c2bde0abc618b018e67ba30621e252871971')
pkgver() {
printf '%s.%s\n' \
diff --git a/openttd-git/signaltunnel.patch b/openttd-git/signaltunnel.patch
index fa2561fd1..e9c8c33d2 100644
--- a/openttd-git/signaltunnel.patch
+++ b/openttd-git/signaltunnel.patch
@@ -366,7 +366,7 @@ index 8952000a51..137e435fb3 100644
case MP_RAILWAY:
diff --git a/src/table/settings.ini b/src/table/settings.ini
-index 78ed234ce2..92fb11e426 100644
+index 1aacb76349..834a61d122 100644
--- a/src/table/settings.ini
+++ b/src/table/settings.ini
@@ -541,6 +541,20 @@ str = STR_CONFIG_SETTING_MAX_TUNNEL_LENGTH
diff --git a/openttd-git/sloped-stations.patch b/openttd-git/sloped-stations.patch
index efd536a14..1f47de969 100644
--- a/openttd-git/sloped-stations.patch
+++ b/openttd-git/sloped-stations.patch
@@ -107,7 +107,7 @@ index 7086d151d0..3252327972 100644
}
}
diff --git a/src/station_cmd.cpp b/src/station_cmd.cpp
-index acffe113dd..675385d777 100644
+index 4aa6401279..7230ee2198 100644
--- a/src/station_cmd.cpp
+++ b/src/station_cmd.cpp
@@ -55,6 +55,7 @@
@@ -118,7 +118,7 @@ index acffe113dd..675385d777 100644
#include "table/strings.h"
-@@ -800,7 +801,7 @@ CommandCost ClearTile_Station(TileIndex tile, DoCommandFlag flags);
+@@ -764,7 +765,7 @@ CommandCost ClearTile_Station(TileIndex tile, DoCommandFlag flags);
* Checks if the given tile is buildable, flat and has a certain height.
* @param tile TileIndex to check.
* @param invalid_dirs Prohibited directions for slopes (set of #DiagDirection).
@@ -127,7 +127,7 @@ index acffe113dd..675385d777 100644
* @param allow_steep Whether steep slopes are allowed.
* @param check_bridge Check for the existence of a bridge.
* @return The cost in case of success, or an error code if it failed.
-@@ -839,10 +840,10 @@ CommandCost CheckBuildableTile(TileIndex tile, uint invalid_dirs, int &allowed_z
+@@ -803,10 +804,10 @@ CommandCost CheckBuildableTile(TileIndex tile, uint invalid_dirs, int &allowed_z
}
/* The level of this tile must be equal to allowed_z. */
@@ -140,7 +140,7 @@ index acffe113dd..675385d777 100644
return_cmd_error(STR_ERROR_FLAT_LAND_REQUIRED);
}
-@@ -890,14 +891,14 @@ static CommandCost CheckFlatLandAirport(AirportTileTableIterator tile_iter, DoCo
+@@ -854,14 +855,14 @@ static CommandCost CheckFlatLandAirport(AirportTileTableIterator tile_iter, DoCo
static CommandCost CheckFlatLandRailStation(TileArea tile_area, DoCommandFlag flags, Axis axis, StationID *station, RailType rt, std::vector<Train *> &affected_vehicles, StationClassID spec_class, byte spec_index, byte plat_len, byte numtracks)
{
CommandCost cost(EXPENSES_CONSTRUCTION);
@@ -157,7 +157,7 @@ index acffe113dd..675385d777 100644
if (ret.Failed()) return ret;
cost.AddCost(ret);
-@@ -976,10 +977,10 @@ static CommandCost CheckFlatLandRailStation(TileArea tile_area, DoCommandFlag fl
+@@ -940,10 +941,10 @@ static CommandCost CheckFlatLandRailStation(TileArea tile_area, DoCommandFlag fl
static CommandCost CheckFlatLandRoadStop(TileArea tile_area, DoCommandFlag flags, uint invalid_dirs, bool is_drive_through, bool is_truck_stop, Axis axis, StationID *station, RoadTypes rts)
{
CommandCost cost(EXPENSES_CONSTRUCTION);
@@ -170,7 +170,7 @@ index acffe113dd..675385d777 100644
if (ret.Failed()) return ret;
cost.AddCost(ret);
-@@ -1874,7 +1875,7 @@ CommandCost CmdBuildRoadStop(TileIndex tile, DoCommandFlag flags, uint32 p1, uin
+@@ -1838,7 +1839,7 @@ CommandCost CmdBuildRoadStop(TileIndex tile, DoCommandFlag flags, uint32 p1, uin
/* Total road stop cost. */
CommandCost cost(EXPENSES_CONSTRUCTION, roadstop_area.w * roadstop_area.h * _price[type ? PR_BUILD_STATION_TRUCK : PR_BUILD_STATION_BUS]);
StationID est = INVALID_STATION;
@@ -179,7 +179,7 @@ index acffe113dd..675385d777 100644
if (ret.Failed()) return ret;
cost.AddCost(ret);
-@@ -2821,6 +2822,32 @@ static void DrawTile_Station(TileInfo *ti)
+@@ -2785,6 +2786,32 @@ static void DrawTile_Station(TileInfo *ti)
palette = PALETTE_TO_GREY;
}
@@ -212,7 +212,7 @@ index acffe113dd..675385d777 100644
if (layout == nullptr && (t == nullptr || t->seq == nullptr)) t = GetStationTileLayout(GetStationType(ti->tile), gfx);
/* don't show foundation for docks */
-@@ -2887,10 +2914,10 @@ static void DrawTile_Station(TileInfo *ti)
+@@ -2851,10 +2878,10 @@ static void DrawTile_Station(TileInfo *ti)
}
OffsetGroundSprite(31, 1);
@@ -225,7 +225,7 @@ index acffe113dd..675385d777 100644
}
}
-@@ -2946,14 +2973,64 @@ draw_default_foundation:
+@@ -2910,14 +2937,64 @@ draw_default_foundation:
DrawGroundSprite(overlay + overlay_offset, PALETTE_CRASH);
}
} else {
@@ -293,7 +293,7 @@ index acffe113dd..675385d777 100644
}
}
}
-@@ -3006,6 +3083,16 @@ void StationPickerDrawSprite(int x, int y, StationType st, RailType railtype, Ro
+@@ -2970,6 +3047,16 @@ void StationPickerDrawSprite(int x, int y, StationType st, RailType railtype, Ro
static int GetSlopePixelZ_Station(TileIndex tile, uint x, uint y)
{
diff --git a/openttd-git/underground.patch b/openttd-git/underground.patch
index fc3810759..bb3c71dd8 100644
--- a/openttd-git/underground.patch
+++ b/openttd-git/underground.patch
@@ -366,7 +366,7 @@ index 4609dceeb9..86ee14cc56 100644
for (row = 0; (uint)row < height; row++) {
for (col = 0; (uint)col < width; col++) {
diff --git a/src/industry_cmd.cpp b/src/industry_cmd.cpp
-index df9286308e..48b2f4dc10 100644
+index 9978145fac..fbee8dcc65 100644
--- a/src/industry_cmd.cpp
+++ b/src/industry_cmd.cpp
@@ -14,6 +14,7 @@
@@ -377,7 +377,7 @@ index df9286308e..48b2f4dc10 100644
#include "viewport_func.h"
#include "command_func.h"
#include "town.h"
-@@ -1400,7 +1401,7 @@ static CommandCost CheckIfIndustryTilesAreFree(TileIndex tile, const IndustryTil
+@@ -1399,7 +1400,7 @@ static CommandCost CheckIfIndustryTilesAreFree(TileIndex tile, const IndustryTil
IndustryGfx gfx = GetTranslatedIndustryTileID(it->gfx);
TileIndex cur_tile = TileAddWrap(tile, it->ti.x, it->ti.y);
@@ -1937,7 +1937,7 @@ index e9edbf2549..b3270e7004 100644
}
diff --git a/src/saveload/map_sl.cpp b/src/saveload/map_sl.cpp
-index 18c1351176..f72855041f 100644
+index 17a793a09f..f9d15cc137 100644
--- a/src/saveload/map_sl.cpp
+++ b/src/saveload/map_sl.cpp
@@ -11,6 +11,7 @@
@@ -2031,7 +2031,7 @@ index 2459058979..923861f8c6 100644
byte oil_refinery_limit; ///< distance oil refineries allowed from map edge
byte snow_line_height; ///< the configured snow line height
diff --git a/src/station.cpp b/src/station.cpp
-index b211c6422e..a3560f2fd4 100644
+index 85603a38c8..903528a767 100644
--- a/src/station.cpp
+++ b/src/station.cpp
@@ -13,6 +13,7 @@
@@ -2127,7 +2127,7 @@ index b211c6422e..a3560f2fd4 100644
bool empty = this->AfterRemoveTile(st, ta.tile);
if (ta.w != 1 || ta.h != 1) empty = empty || this->AfterRemoveTile(st, TILE_ADDXY(ta.tile, ta.w - 1, ta.h - 1));
diff --git a/src/station_cmd.cpp b/src/station_cmd.cpp
-index acffe113dd..566bd84fb2 100644
+index 4aa6401279..510bc30724 100644
--- a/src/station_cmd.cpp
+++ b/src/station_cmd.cpp
@@ -13,6 +13,7 @@
@@ -2138,16 +2138,14 @@ index acffe113dd..566bd84fb2 100644
#include "viewport_func.h"
#include "viewport_kdtree.h"
#include "command_func.h"
-@@ -99,23 +100,26 @@ bool IsHangar(TileIndex t)
+@@ -99,21 +100,24 @@ bool IsHangar(TileIndex t)
* @return Succeeded command (if zero or one station found) or failed command (for two or more stations found).
*/
template <class T>
-CommandCost GetStationAround(TileArea ta, StationID closest_station, CompanyID company, T **st)
+CommandCost GetStationAround(TileArea ta, StationID closest_station, CompanyID company, T **st, bool layers=false)
{
- ta.tile -= TileDiffXY(1, 1);
- ta.w += 2;
- ta.h += 2;
+ ta.Expand(1);
/* check around to see if there are any stations there owned by the company */
- TILE_AREA_LOOP(tile_cur, ta) {
@@ -2174,7 +2172,7 @@ index acffe113dd..566bd84fb2 100644
}
*st = (closest_station == INVALID_STATION) ? nullptr : T::Get(closest_station);
return CommandCost();
-@@ -835,7 +839,7 @@ CommandCost CheckBuildableTile(TileIndex tile, uint invalid_dirs, int &allowed_z
+@@ -799,7 +803,7 @@ CommandCost CheckBuildableTile(TileIndex tile, uint invalid_dirs, int &allowed_z
return_cmd_error(STR_ERROR_FLAT_LAND_REQUIRED);
}
}
@@ -2183,7 +2181,7 @@ index acffe113dd..566bd84fb2 100644
}
/* The level of this tile must be equal to allowed_z. */
-@@ -1064,7 +1068,7 @@ static CommandCost CheckFlatLandRoadStop(TileArea tile_area, DoCommandFlag flags
+@@ -1028,7 +1032,7 @@ static CommandCost CheckFlatLandRoadStop(TileArea tile_area, DoCommandFlag flags
}
uint roadbits_to_build = CountBits(rts) * 2 - num_roadbits;
@@ -2192,7 +2190,7 @@ index acffe113dd..566bd84fb2 100644
}
}
-@@ -1083,11 +1087,13 @@ CommandCost CanExpandRailStation(const BaseStation *st, TileArea &new_ta, Axis a
+@@ -1047,11 +1051,13 @@ CommandCost CanExpandRailStation(const BaseStation *st, TileArea &new_ta, Axis a
TileArea cur_ta = st->train_station;
/* determine new size of train station region.. */
@@ -2211,7 +2209,7 @@ index acffe113dd..566bd84fb2 100644
/* make sure the final size is not too big. */
if (new_ta.w > _settings_game.station.station_spread || new_ta.h > _settings_game.station.station_spread) {
-@@ -1159,7 +1165,7 @@ void GetStationLayout(byte *layout, int numtracks, int plat_len, const StationSp
+@@ -1123,7 +1129,7 @@ void GetStationLayout(byte *layout, int numtracks, int plat_len, const StationSp
* @return command cost with the error or 'okay'
*/
template <class T, StringID error_message>
@@ -2220,7 +2218,7 @@ index acffe113dd..566bd84fb2 100644
{
assert(*st == nullptr);
bool check_surrounding = true;
-@@ -1185,7 +1191,7 @@ CommandCost FindJoiningBaseStation(StationID existing_station, StationID station
+@@ -1149,7 +1155,7 @@ CommandCost FindJoiningBaseStation(StationID existing_station, StationID station
if (check_surrounding) {
/* Make sure there is no more than one other station around us that is owned by us. */
@@ -2229,7 +2227,7 @@ index acffe113dd..566bd84fb2 100644
if (ret.Failed()) return ret;
}
-@@ -1204,9 +1210,9 @@ CommandCost FindJoiningBaseStation(StationID existing_station, StationID station
+@@ -1168,9 +1174,9 @@ CommandCost FindJoiningBaseStation(StationID existing_station, StationID station
* @param st 'return' pointer for the found station
* @return command cost with the error or 'okay'
*/
@@ -2241,7 +2239,7 @@ index acffe113dd..566bd84fb2 100644
}
/**
-@@ -1315,8 +1321,8 @@ CommandCost CmdBuildRailStation(TileIndex tile_org, DoCommandFlag flags, uint32
+@@ -1279,8 +1285,8 @@ CommandCost CmdBuildRailStation(TileIndex tile_org, DoCommandFlag flags, uint32
CommandCost cost = CheckFlatLandRailStation(new_location, flags, axis, &est, rt, affected_vehicles, spec_class, spec_index, plat_len, numtracks);
if (cost.Failed()) return cost;
/* Add construction expenses. */
@@ -2252,7 +2250,7 @@ index acffe113dd..566bd84fb2 100644
Station *st = nullptr;
ret = FindJoiningStation(est, station_to_join, adjacent, new_location, &st);
-@@ -1356,8 +1362,10 @@ CommandCost CmdBuildRailStation(TileIndex tile_org, DoCommandFlag flags, uint32
+@@ -1320,8 +1326,10 @@ CommandCost CmdBuildRailStation(TileIndex tile_org, DoCommandFlag flags, uint32
byte numtracks_orig;
Track track;
@@ -2264,7 +2262,7 @@ index acffe113dd..566bd84fb2 100644
st->rect.BeforeAddRect(tile_org, w_org, h_org, StationRect::ADD_TRY);
-@@ -1578,7 +1586,7 @@ CommandCost RemoveFromRailBaseStation(TileArea ta, std::vector<T *> &affected_st
+@@ -1542,7 +1550,7 @@ CommandCost RemoveFromRailBaseStation(TileArea ta, std::vector<T *> &affected_st
}
/* If we reached here, the tile is valid so increase the quantity of tiles we will remove */
@@ -2273,7 +2271,7 @@ index acffe113dd..566bd84fb2 100644
if (keep_rail || IsStationTileBlocked(tile)) {
/* Don't refund the 'steel' of the track when we keep the
-@@ -1657,7 +1665,7 @@ CommandCost RemoveFromRailBaseStation(TileArea ta, std::vector<T *> &affected_st
+@@ -1621,7 +1629,7 @@ CommandCost RemoveFromRailBaseStation(TileArea ta, std::vector<T *> &affected_st
CommandCost CmdRemoveFromRailStation(TileIndex start, DoCommandFlag flags, uint32 p1, uint32 p2, const char *text)
{
TileIndex end = p1 == 0 ? start : p1;
@@ -2282,7 +2280,7 @@ index acffe113dd..566bd84fb2 100644
TileArea ta(start, end);
std::vector<Station *> affected_stations;
-@@ -1720,11 +1728,16 @@ CommandCost RemoveRailStation(T *st, DoCommandFlag flags, Money removal_cost)
+@@ -1684,11 +1692,16 @@ CommandCost RemoveRailStation(T *st, DoCommandFlag flags, Money removal_cost)
/* determine width and height of platforms */
TileArea ta = st->train_station;
@@ -2301,7 +2299,7 @@ index acffe113dd..566bd84fb2 100644
/* only remove tiles that are actually train station tiles */
if (st->TileBelongsToRailStation(tile)) {
std::vector<T*> affected_stations; // dummy
-@@ -2089,13 +2102,21 @@ CommandCost CmdRemoveRoadStop(TileIndex tile, DoCommandFlag flags, uint32 p1, ui
+@@ -2053,13 +2066,21 @@ CommandCost CmdRemoveRoadStop(TileIndex tile, DoCommandFlag flags, uint32 p1, ui
/* Bankrupting company is not supposed to remove roads, there may be road vehicles. */
if (!keep_drive_through_roads && (flags & DC_BANKRUPT)) return CMD_ERROR;
@@ -2325,7 +2323,7 @@ index acffe113dd..566bd84fb2 100644
/* Make sure the specified tile is a road stop of the correct type */
if (!IsTileType(cur_tile, MP_STATION) || !IsRoadStop(cur_tile) || (uint32)GetRoadStopType(cur_tile) != GB(p2, 0, 1)) continue;
-@@ -2279,6 +2300,10 @@ CommandCost CmdBuildAirport(TileIndex tile, DoCommandFlag flags, uint32 p1, uint
+@@ -2243,6 +2264,10 @@ CommandCost CmdBuildAirport(TileIndex tile, DoCommandFlag flags, uint32 p1, uint
if (w > _settings_game.station.station_spread || h > _settings_game.station.station_spread) {
return_cmd_error(STR_ERROR_STATION_TOO_SPREAD_OUT);
}
@@ -2337,7 +2335,7 @@ index acffe113dd..566bd84fb2 100644
AirportTileTableIterator iter(as->table[layout], tile);
CommandCost cost = CheckFlatLandAirport(iter, flags);
diff --git a/src/station_gui.cpp b/src/station_gui.cpp
-index a3013c847f..6c8a6e6253 100644
+index 4e6b94caf6..9d4046fa57 100644
--- a/src/station_gui.cpp
+++ b/src/station_gui.cpp
@@ -21,6 +21,7 @@
@@ -2397,7 +2395,7 @@ index a3013c847f..6c8a6e6253 100644
return nullptr;
}
diff --git a/src/table/settings.ini b/src/table/settings.ini
-index 78ed234ce2..745b62ba76 100644
+index 1aacb76349..726036977a 100644
--- a/src/table/settings.ini
+++ b/src/table/settings.ini
@@ -1861,6 +1861,15 @@ min = 500
@@ -2537,7 +2535,7 @@ index 0cb28122d8..c6f62dac0f 100644
}
diff --git a/src/tilearea_type.h b/src/tilearea_type.h
-index 45bfb3d4c0..164781814b 100644
+index c599753498..869ff3e09a 100644
--- a/src/tilearea_type.h
+++ b/src/tilearea_type.h
@@ -44,6 +44,16 @@ struct OrthogonalTileArea {