summaryrefslogtreecommitdiff
path: root/src/unmovable.h
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2010-08-02 20:57:32 +0000
committerrubidium <rubidium@openttd.org>2010-08-02 20:57:32 +0000
commitf2edc728e6c8d8b74226058ab5842ef60bf34592 (patch)
tree049fe68fdfb81847b2d844f7b4847a7ef8fbf366 /src/unmovable.h
parent0e900039f3531f0f64e93e216eb44e45b463d5b7 (diff)
downloadopenttd-f2edc728e6c8d8b74226058ab5842ef60bf34592.tar.xz
(svn r20321) -Codechange: rename GetUnmovableSpec to UnmovableSpec::Get and add+use a ::GetByTile
Diffstat (limited to 'src/unmovable.h')
-rw-r--r--src/unmovable.h14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/unmovable.h b/src/unmovable.h
index dae1c269b..2838d1879 100644
--- a/src/unmovable.h
+++ b/src/unmovable.h
@@ -34,6 +34,20 @@ struct UnmovableSpec {
* @return The cost for clearing.
*/
Money GetClearCost() const { return (_price[PR_CLEAR_UNMOVABLE] * this->clear_cost_multiplier); }
+
+ /**
+ * Get the specification associated with a specific UnmovableType.
+ * @param index The unmovable type to fetch.
+ * @return The specification.
+ */
+ static const UnmovableSpec *Get(int index);
+
+ /**
+ * Get the specification associated with a tile.
+ * @param tile The tile to fetch the data for.
+ * @return The specification.
+ */
+ static const UnmovableSpec *GetByTile(TileIndex tile);
};