diff options
author | Perttu Ahola <celeron55@gmail.com> | 2011-12-04 02:12:45 +0200 |
---|---|---|
committer | Perttu Ahola <celeron55@gmail.com> | 2011-12-04 02:12:45 +0200 |
commit | 6145a135bd71425c69d31e6c65112238e08349a5 (patch) | |
tree | dc1b839ebd4b35cb84a14b95d339843c11e75bf1 /src/nodedef.h | |
parent | 97c3bc408be0636b5821b7792957d18272e8f7bb (diff) | |
download | minetest-6145a135bd71425c69d31e6c65112238e08349a5.tar.gz minetest-6145a135bd71425c69d31e6c65112238e08349a5.tar.bz2 minetest-6145a135bd71425c69d31e6c65112238e08349a5.zip |
Make ToolItem and MaterialItem to convert names by aliases at creation time too (necessary for eg. crafting)
Diffstat (limited to 'src/nodedef.h')
-rw-r--r-- | src/nodedef.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/nodedef.h b/src/nodedef.h index f69b66c9f..fdf2f8c45 100644 --- a/src/nodedef.h +++ b/src/nodedef.h @@ -253,6 +253,7 @@ public: virtual bool getId(const std::string &name, content_t &result) const=0; virtual content_t getId(const std::string &name) const=0; virtual const ContentFeatures& get(const std::string &name) const=0; + virtual std::string getAlias(const std::string &name) const =0; virtual void serialize(std::ostream &os)=0; }; @@ -270,6 +271,7 @@ public: virtual content_t getId(const std::string &name) const=0; // If not found, returns the features of CONTENT_IGNORE virtual const ContentFeatures& get(const std::string &name) const=0; + virtual std::string getAlias(const std::string &name) const =0; // Register node definition virtual void set(content_t c, const ContentFeatures &def)=0; |