1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-11-29 23:07:48 +02:00

Add specific objects and configure their frequency / value

This commit is contained in:
Tomasz Zieliński
2024-09-12 21:04:27 +02:00
parent bfe75a6a02
commit 4b263b6d41
6 changed files with 177 additions and 101 deletions

View File

@@ -32,6 +32,7 @@ struct DLL_LINKAGE ObjectInfo
std::function<CGObjectInstance *()> generateObject;
std::function<void(CGObjectInstance *)> destroyObject;
void setAllTemplates(MapObjectID type, MapObjectSubID subtype);
void setTemplates(MapObjectID type, MapObjectSubID subtype, TerrainId terrain);
//bool matchesId(const CompoundMapObjectID & id) const;
@@ -61,7 +62,7 @@ public:
};
void addBannedObject(const CompoundMapObjectID & objid);
void addCustomObject(const ObjectInfo & object);
void addCustomObject(const ObjectInfo & object, const CompoundMapObjectID & objid);
void clearBannedObjects();
void clearCustomObjects();
const std::vector<CompoundMapObjectID> & getBannedObjects() const;