summaryrefslogtreecommitdiff
path: root/src/cargotype.h
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2008-01-15 13:19:49 +0000
committerrubidium <rubidium@openttd.org>2008-01-15 13:19:49 +0000
commit26c621945d36e18cce2e86e0edbac9e525ba77db (patch)
tree674e51d7f086d490a4dcb2fded3e60d9f94042d3 /src/cargotype.h
parent0078fd1699fc594b46827d3680b31fd79f0d9bd2 (diff)
downloadopenttd-26c621945d36e18cce2e86e0edbac9e525ba77db.tar.xz
(svn r11862) -Fix [FS#1559]: when two NewGRFs 'fight' to define the same cargo it could happen that the strings are defined by one cargo and the 'action2' by another and when one assumes that both come from the same NewGRF... So store the GRF ID with the strings. To be extra sure add the same protection mechanism to industries and towns too.
Diffstat (limited to 'src/cargotype.h')
-rw-r--r--src/cargotype.h12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/cargotype.h b/src/cargotype.h
index 8f00ef4cd..67b63e3dd 100644
--- a/src/cargotype.h
+++ b/src/cargotype.h
@@ -7,7 +7,7 @@
#include "cargo_type.h"
#include "gfx_type.h"
-#include "strings_type.h"
+#include "newgrf_string_type.h"
typedef uint32 CargoLabel;
@@ -36,11 +36,11 @@ struct CargoSpec {
uint16 multipliertowngrowth;
uint8 callback_mask;
- StringID name;
- StringID name_single;
- StringID units_volume;
- StringID quantifier;
- StringID abbrev;
+ GRFMappedStringID name;
+ GRFMappedStringID name_single;
+ GRFMappedStringID units_volume;
+ GRFMappedStringID quantifier;
+ GRFMappedStringID abbrev;
SpriteID sprite;