summaryrefslogtreecommitdiff
path: root/src/map.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/map.h')
-rw-r--r--src/map.h19
1 files changed, 19 insertions, 0 deletions
diff --git a/src/map.h b/src/map.h
index d3bf20b1..02bea4a2 100644
--- a/src/map.h
+++ b/src/map.h
@@ -159,11 +159,30 @@ class Map
std::list<PATH_NODE> findPath(
int startX, int startY, int destX, int destY);
+ /**
+ * Get a map property.
+ *
+ * @return the value of the given property or an empty string when it
+ * doesn't exist.
+ */
+ std::string getProperty(const std::string &name);
+
+ /**
+ * Returns whether a certain property is available.
+ */
+ bool hasProperty(const std::string &name);
+
+ /**
+ * Set a map property.
+ */
+ void setProperty(const std::string &name, const std::string &value);
+
private:
int width, height;
int tileWidth, tileHeight;
MetaTile *metaTiles;
Image **tiles;
+ std::map<std::string,std::string> properties;
// Pathfinding members
int onClosedList, onOpenList;