aboutsummaryrefslogtreecommitdiff
path: root/src/mg_decoration.cpp
Commit message (Expand)AuthorAge
* Simple deco: Allow setting param2 value on placementAuke Kok2016-12-07
* Decorations: Generalise 'spawn by' to be used by all decoration typesparamat2016-09-14
* Permit usage of std::unordered_map & std::unorderered_set on c++11 compilers ...Ner'zhul2016-08-10
* Decorations: Fix decoration height check errorsparamat2016-08-05
* Decoration API: Allow force_placement of simple decorationsparamat2016-03-04
* Decoration API: Fix missing low density decorationsparamat2015-11-14
* Convert usages of PseudoRandom to PcgRandom for ore and deco placementkwolekr2015-11-09
* Schematics: Add core.place_schematic_on_vmanip APIkwolekr2015-11-05
* Decoration API: Add flag for placement on liquid surfaceparamat2015-10-23
* Decorations: Remove error message 'chunksize not divisable by sidelen'paramat2015-09-26
* Clean up threadingShadowNinja2015-08-23
* Biome API decorations: 'spawnby' searches a 3D neighbourhoodparamat2015-07-08
* Biome API: Enable biome generation to lower world limitparamat2015-06-15
* NodeResolver: Remove NodeResolveMethodkwolekr2015-05-07
* Fix MSVC compatibilitykwolekr2015-04-29
* DecoSchematic: Fix missing trees in rough terrainparamat2015-04-23
* Schematics: Remove referenced schematics from Decorations on clearkwolekr2015-04-17
* Schematics: Refactor NodeResolver and add NodeResolveMethodkwolekr2015-04-16
* GenElementManager: Pass opaque handles to Lua and rename to ObjDefManagerkwolekr2015-03-31
* mg_decoration: Raise highest allowed deco top to max edge of voxelmanipparamat2015-03-15
* Biome API: Enable decorations placed on waterparamat2015-03-06
* Shorten ManualMapVoxelManipulator to MMVManipkwolekr2015-01-05
* Add minetest.generate_ores() and minetest.generate_decorations()kwolekr2015-01-04
* Replace instances of height_min/height_max with y_min/y_max to remove ambiguitykwolekr2014-12-30
* Decoration: Add height_min and height_max parameterskwolekr2014-12-28
* Redefine NodeResolver interface and replace with callback mechanismkwolekr2014-12-27
* Use std::string::empty() instead of size() where applicableAnton2014-12-12
* Add minetest.clear_registered_decorations() and clear_registered_ores()kwolekr2014-12-12
* Remove get_noiseparams function. read_noiseparams should be used from now onkwolekr2014-12-10
* Rewrite generate notification mechanismkwolekr2014-12-06
* Add Generator Element Management frameworkkwolekr2014-11-12
* Split up mapgen.cppkwolekr2014-11-01
ion std::string node_placement_prediction; /* Some helpful methods */ ItemDefinition(); ItemDefinition(const ItemDefinition &def); ItemDefinition& operator=(const ItemDefinition &def); ~ItemDefinition(); void reset(); void serialize(std::ostream &os, u16 protocol_version) const; void deSerialize(std::istream &is); private: void resetInitial(); }; class IItemDefManager { public: IItemDefManager(){} virtual ~IItemDefManager(){} // Get item definition virtual const ItemDefinition& get(const std::string &name) const=0; // Get alias definition virtual std::string getAlias(const std::string &name) const=0; // Get set of all defined item names and aliases virtual std::set<std::string> getAll() const=0; // Check if item is known virtual bool isKnown(const std::string &name) const=0; #ifndef SERVER // Get item inventory texture virtual video::ITexture* getInventoryTexture(const std::string &name, Client *client) const=0; // Get item wield mesh virtual scene::IMesh* getWieldMesh(const std::string &name, Client *client) const=0; #endif virtual void serialize(std::ostream &os, u16 protocol_version)=0; }; class IWritableItemDefManager : public IItemDefManager { public: IWritableItemDefManager(){} virtual ~IWritableItemDefManager(){} // Get item definition virtual const ItemDefinition& get(const std::string &name) const=0; // Get alias definition virtual std::string getAlias(const std::string &name) const=0; // Get set of all defined item names and aliases virtual std::set<std::string> getAll() const=0; // Check if item is known virtual bool isKnown(const std::string &name) const=0; #ifndef SERVER // Get item inventory texture virtual video::ITexture* getInventoryTexture(const std::string &name, Client *client) const=0; // Get item wield mesh virtual scene::IMesh* getWieldMesh(const std::string &name, Client *client) const=0; #endif // Remove all registered item and node definitions and aliases // Then re-add the builtin item definitions virtual void clear()=0; // Register item definition virtual void registerItem(const ItemDefinition &def)=0; virtual void unregisterItem(const std::string &name)=0; // Set an alias so that items named <name> will load as <convert_to>. // Alias is not set if <name> has already been defined. // Alias will be removed if <name> is defined at a later point of time. virtual void registerAlias(const std::string &name, const std::string &convert_to)=0; virtual void serialize(std::ostream &os, u16 protocol_version)=0; virtual void deSerialize(std::istream &is)=0; // Do stuff asked by threads that can only be done in the main thread virtual void processQueue(IGameDef *gamedef)=0; }; IWritableItemDefManager* createItemDefManager(); #endif