]> git.localhorst.tv Git - blobs.git/blobdiff - src/world/Set.hpp
read (basic) tile information from file
[blobs.git] / src / world / Set.hpp
index c4aa6e9f37b6691b38385884e258810913e2dadc..af4d8a242959c166b95af639c6413bf8a81ff908 100644 (file)
@@ -22,6 +22,8 @@ public:
                types.back().id = id;
                return id;
        }
+       bool Has(int id) const noexcept { return id < types.size(); }
+       bool Has(const std::string &name) const noexcept { return names.find(name) != names.end(); }
 
        Type &operator [](int id) noexcept { return types[id]; }
        const Type &operator [](int id) const noexcept { return types[id]; }