summaryrefslogtreecommitdiff
path: root/src/newgrf_industrytiles.h
diff options
context:
space:
mode:
authorfrosch <frosch@openttd.org>2018-03-11 13:19:41 +0000
committerfrosch <frosch@openttd.org>2018-03-11 13:19:41 +0000
commitd9d669dcf855e444a77141b4b96e5df1f13c7203 (patch)
treea90dc37970fd26211382b50c25b5680be5963955 /src/newgrf_industrytiles.h
parent7c406f0d9dc365960f07e20e690cc0bdf8682fd6 (diff)
downloadopenttd-d9d669dcf855e444a77141b4b96e5df1f13c7203.tar.xz
(svn r27984) -Codechange: Make ScopeResolver constructors/destructors inlineable. Speedup sprite resolving by about 8 percent.
Diffstat (limited to 'src/newgrf_industrytiles.h')
-rw-r--r--src/newgrf_industrytiles.h11
1 files changed, 10 insertions, 1 deletions
diff --git a/src/newgrf_industrytiles.h b/src/newgrf_industrytiles.h
index 2af064054..6051c1062 100644
--- a/src/newgrf_industrytiles.h
+++ b/src/newgrf_industrytiles.h
@@ -21,7 +21,16 @@ struct IndustryTileScopeResolver : public ScopeResolver {
Industry *industry; ///< Industry owning the tiles.
TileIndex tile; ///< %Tile being resolved.
- IndustryTileScopeResolver(ResolverObject &ro, Industry *industry, TileIndex tile);
+ /**
+ * Constructor of the scope resolver for the industry tile.
+ * @param ro Surrounding resolver.
+ * @param industry %Industry owning the tile.
+ * @param tile %Tile of the industry.
+ */
+ IndustryTileScopeResolver(ResolverObject &ro, Industry *industry, TileIndex tile)
+ : ScopeResolver(ro), industry(industry), tile(tile)
+ {
+ }
/* virtual */ uint32 GetRandomBits() const;
/* virtual */ uint32 GetVariable(byte variable, uint32 parameter, bool *available) const;