summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2009-03-15 21:16:07 +0000
committerrubidium <rubidium@openttd.org>2009-03-15 21:16:07 +0000
commit6487883084634183582a76c8635008848156bd6c (patch)
tree892d532fbe27a5bababd7aa5603a92a4b4489982
parentea36f23d534651fa09f8843e53cf1aac4a4eec29 (diff)
downloadopenttd-6487883084634183582a76c8635008848156bd6c.tar.xz
(svn r15729) -Fix: silence MSVC warning
-rw-r--r--src/town_cmd.cpp13
1 files changed, 7 insertions, 6 deletions
diff --git a/src/town_cmd.cpp b/src/town_cmd.cpp
index d3ef72889..d84f40597 100644
--- a/src/town_cmd.cpp
+++ b/src/town_cmd.cpp
@@ -1374,15 +1374,16 @@ extern int _nb_orig_names;
* Speeds things up a bit because these values are computed only once per name generation.
*/
struct TownNameParams {
- bool grf; ///< true iff a newgrf is used to generate town name
uint32 grfid; ///< newgrf ID
uint16 townnametype; ///< town name style
+ bool grf; ///< true iff a newgrf is used to generate town name
- TownNameParams(byte town_name) :
- grf(town_name >= _nb_orig_names),
- grfid(this->grf ? GetGRFTownNameId(town_name - _nb_orig_names) : 0),
- townnametype(this->grf ? GetGRFTownNameType(town_name - _nb_orig_names) : SPECSTR_TOWNNAME_START + town_name)
- { }
+ TownNameParams(byte town_name)
+ {
+ this->grf = town_name >= _nb_orig_names;
+ this->grfid = this->grf ? GetGRFTownNameId(town_name - _nb_orig_names) : 0;
+ this->townnametype = this->grf ? GetGRFTownNameType(town_name - _nb_orig_names) : SPECSTR_TOWNNAME_START + town_name;
+ }
};
/**