summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2014-09-21 07:57:45 +0000
committerrubidium <rubidium@openttd.org>2014-09-21 07:57:45 +0000
commit2361aaf601e4355986e607e525a75377bf754de8 (patch)
tree433dcadb2ba1a947ad4170a096f361015ef7d7a0
parent9caf6b4537c3fe3f3f516a49f983defab277e05e (diff)
downloadopenttd-2361aaf601e4355986e607e525a75377bf754de8.tar.xz
(svn r26869) -Add: support for an all black palette to prevent the need of having a black tile of all different slopes (ic111)
-rw-r--r--bin/baseset/openttd.grfbin825565 -> 825852 bytes
-rw-r--r--bin/baseset/orig_dos.obg2
-rw-r--r--bin/baseset/orig_dos_de.obg2
-rw-r--r--bin/baseset/orig_win.obg2
-rw-r--r--config.lib12
-rw-r--r--media/extra_grf/openttd.nfo1
-rw-r--r--media/extra_grf/palette.nfo20
-rw-r--r--src/newgrf.cpp1
-rw-r--r--src/table/sprites.h8
9 files changed, 38 insertions, 10 deletions
diff --git a/bin/baseset/openttd.grf b/bin/baseset/openttd.grf
index 5ee311580..efe35ffd3 100644
--- a/bin/baseset/openttd.grf
+++ b/bin/baseset/openttd.grf
Binary files differ
diff --git a/bin/baseset/orig_dos.obg b/bin/baseset/orig_dos.obg
index d5f20332b..51e857158 100644
--- a/bin/baseset/orig_dos.obg
+++ b/bin/baseset/orig_dos.obg
@@ -70,7 +70,7 @@ TRGI.GRF = da6a6c9dcc451eec88d79211437b76a8
TRGC.GRF = ed446637e034104c5559b32c18afe78d
TRGH.GRF = ee6616fb0e6ef6b24892c58c93d86fc9
TRGT.GRF = e30e8a398ae86c03dc534a8ac7dfb3b6
-OPENTTD.GRF = 75a93cea2ed455c2fd5dcbda39e53538
+OPENTTD.GRF = 505d96061556d3bb5cec6234096ec5bc
[origin]
default = You can find it on your Transport Tycoon Deluxe CD-ROM.
diff --git a/bin/baseset/orig_dos_de.obg b/bin/baseset/orig_dos_de.obg
index 4cc59f48c..6e446dccd 100644
--- a/bin/baseset/orig_dos_de.obg
+++ b/bin/baseset/orig_dos_de.obg
@@ -70,7 +70,7 @@ TRGI.GRF = da6a6c9dcc451eec88d79211437b76a8
TRGC.GRF = ed446637e034104c5559b32c18afe78d
TRGH.GRF = ee6616fb0e6ef6b24892c58c93d86fc9
TRGT.GRF = fcde1d7e8a74197d72a62695884b909e
-OPENTTD.GRF = 75a93cea2ed455c2fd5dcbda39e53538
+OPENTTD.GRF = 505d96061556d3bb5cec6234096ec5bc
[origin]
default = You can find it on your Transport Tycoon Deluxe CD-ROM.
diff --git a/bin/baseset/orig_win.obg b/bin/baseset/orig_win.obg
index ac1165bb4..ce51077e7 100644
--- a/bin/baseset/orig_win.obg
+++ b/bin/baseset/orig_win.obg
@@ -70,7 +70,7 @@ TRGIR.GRF = 0c2484ff6be49fc63a83be6ab5c38f32
TRGCR.GRF = 3668f410c761a050b5e7095a2b14879b
TRGHR.GRF = 06bf2b7a31766f048baac2ebe43457b1
TRGTR.GRF = de53650517fe661ceaa3138c6edb0eb8
-OPENTTD.GRF = 75a93cea2ed455c2fd5dcbda39e53538
+OPENTTD.GRF = 505d96061556d3bb5cec6234096ec5bc
[origin]
default = You can find it on your Transport Tycoon Deluxe CD-ROM.
diff --git a/config.lib b/config.lib
index c58b39663..9698a052a 100644
--- a/config.lib
+++ b/config.lib
@@ -3183,9 +3183,9 @@ detect_grfcodec() {
log 2 " returned $version"
log 2 " exit code $ret"
- if [ -z "$version" ] || [ "$ret" != "0" ] || [ "$version" -lt "949" ]; then
- if [ -n "$version" ] && [ "$version" -lt "949" ]; then
- log 1 "checking grfcodec... needs at least version 6.0.2 (r949), disabled"
+ if [ -z "$version" ] || [ "$ret" != "0" ] || [ "$version" -lt "985" ]; then
+ if [ -n "$version" ] && [ "$version" -lt "985" ]; then
+ log 1 "checking grfcodec... needs at least version 6.0.5 (r985), disabled"
else
log 1 "checking grfcodec... not found"
fi
@@ -3225,9 +3225,9 @@ detect_nforenum() {
log 2 " returned $version"
log 2 " exit code $ret"
- if [ -z "$version" ] || [ "$ret" != "0" ] || [ "$version" -lt "949" ]; then
- if [ -n "$version" ] && [ "$version" -lt "949" ]; then
- log 1 "checking nforenum... needs at least version 6.0.2 (r949), disabled"
+ if [ -z "$version" ] || [ "$ret" != "0" ] || [ "$version" -lt "985" ]; then
+ if [ -n "$version" ] && [ "$version" -lt "985" ]; then
+ log 1 "checking nforenum... needs at least version 6.0.5 (r985), disabled"
else
log 1 "checking nforenum... not found"
fi
diff --git a/media/extra_grf/openttd.nfo b/media/extra_grf/openttd.nfo
index e93b2066f..66149a37e 100644
--- a/media/extra_grf/openttd.nfo
+++ b/media/extra_grf/openttd.nfo
@@ -104,3 +104,4 @@
#include "rivers/tropic.nfo"
#include "rivers/toyland.nfo"
#include "tunnel_portals.nfo"
+#include "palette.nfo"
diff --git a/media/extra_grf/palette.nfo b/media/extra_grf/palette.nfo
new file mode 100644
index 000000000..4a6ae6950
--- /dev/null
+++ b/media/extra_grf/palette.nfo
@@ -0,0 +1,20 @@
+//
+// $Id$
+//
+// This file is part of OpenTTD.
+// OpenTTD is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, version 2.
+// OpenTTD is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+// See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with OpenTTD. If not, see <http://www.gnu.org/licenses/>.
+//
+
+ -1 * 0 0C "All black palette"
+ -1 * 0 05 18 01
+ -1 * 0 00 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01
+ 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01
+ 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01
+ 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01
+ 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01
+ 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01
+ 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01
+ 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01
+ 01
diff --git a/src/newgrf.cpp b/src/newgrf.cpp
index b1b6f5ff1..88b3b25a4 100644
--- a/src/newgrf.cpp
+++ b/src/newgrf.cpp
@@ -5594,6 +5594,7 @@ static const Action5Type _action5_types[] = {
/* 0x15 */ { A5BLOCK_ALLOW_OFFSET, SPR_OPENTTD_BASE, 1, OPENTTD_SPRITE_COUNT, "OpenTTD GUI graphics" },
/* 0x16 */ { A5BLOCK_ALLOW_OFFSET, SPR_AIRPORT_PREVIEW_BASE, 1, SPR_AIRPORT_PREVIEW_COUNT, "Airport preview graphics" },
/* 0x17 */ { A5BLOCK_ALLOW_OFFSET, SPR_RAILTYPE_TUNNEL_BASE, 1, RAILTYPE_TUNNEL_BASE_COUNT, "Railtype tunnel base" },
+ /* 0x18 */ { A5BLOCK_ALLOW_OFFSET, SPR_PALETTE_BASE, 1, PALETTE_SPRITE_COUNT, "Palette" },
};
/* Action 0x05 */
diff --git a/src/table/sprites.h b/src/table/sprites.h
index 5d42caccb..b5b3321b0 100644
--- a/src/table/sprites.h
+++ b/src/table/sprites.h
@@ -290,8 +290,12 @@ static const uint16 RAILTYPE_TUNNEL_BASE_COUNT = 16;
static const SpriteID SPR_EMPTY_BOUNDING_BOX = SPR_RAILTYPE_TUNNEL_BASE + RAILTYPE_TUNNEL_BASE_COUNT;
static const uint16 EMPTY_BOUNDING_BOX_SPRITE_COUNT = 1;
+/* Black palette sprite, needed for painting (fictive) tiles outside map */
+static const SpriteID SPR_PALETTE_BASE = SPR_EMPTY_BOUNDING_BOX + EMPTY_BOUNDING_BOX_SPRITE_COUNT;
+static const uint16 PALETTE_SPRITE_COUNT = 1;
+
/* From where can we start putting NewGRFs? */
-static const SpriteID SPR_NEWGRFS_BASE = SPR_EMPTY_BOUNDING_BOX + EMPTY_BOUNDING_BOX_SPRITE_COUNT;
+static const SpriteID SPR_NEWGRFS_BASE = SPR_PALETTE_BASE + PALETTE_SPRITE_COUNT;
/* Manager face sprites */
static const SpriteID SPR_GRADIENT = 874; // background gradient behind manager face
@@ -1562,4 +1566,6 @@ static const PaletteID PALETTE_CRASH = 804; ///< Recolour sprite
static const PaletteID PALETTE_CHURCH_RED = 1438; ///< Recolour sprite for reddish churches
static const PaletteID PALETTE_CHURCH_CREAM = 1439; ///< Recolour sprite for white churches
+static const PaletteID PALETTE_ALL_BLACK = SPR_PALETTE_BASE; ///< Exchange any color by black, needed for painting fictive tiles outside map
+
#endif /* SPRITES_H */