Add LuaSecureRandom
[oweals/minetest.git] / src / mods.h
index e10d49324bbf8a603af9f54f4d29f4576466c5ac..12576516dc0edc5a6ea8171e02e663d788dccc7e 100644 (file)
@@ -21,40 +21,16 @@ with this program; if not, write to the Free Software Foundation, Inc.,
 #define MODS_HEADER
 
 #include "irrlichttypes.h"
-#include <irrList.h>
 #include <list>
 #include <set>
 #include <vector>
 #include <string>
 #include <map>
-#include <exception>
-#include <list>
 #include "json/json.h"
 #include "config.h"
 
-#if USE_CURL
-#include <curl/curl.h>
-#endif
-
 #define MODNAME_ALLOWED_CHARS "abcdefghijklmnopqrstuvwxyz0123456789_"
 
-class ModError : public std::exception
-{
-public:
-       ModError(const std::string &s)
-       {
-               m_s = "ModError: ";
-               m_s += s;
-       }
-       virtual ~ModError() throw()
-       {}
-       virtual const char * what() const throw()
-       {
-               return m_s.c_str();
-       }
-       std::string m_s;
-};
-
 struct ModSpec
 {
        std::string name;
@@ -68,7 +44,7 @@ struct ModSpec
        bool is_modpack;
        // if modpack:
        std::map<std::string,ModSpec> modpack_content;
-       ModSpec(const std::string name_="", const std::string path_=""):
+       ModSpec(const std::string &name_="", const std::string &path_=""):
                name(name_),
                path(path_),
                depends(),
@@ -106,7 +82,7 @@ public:
                m_name_conflicts()
        {}
 
-               
+
        ModConfiguration(std::string worldpath);
 
        // checks if all dependencies are fullfilled.
@@ -152,10 +128,9 @@ private:
        // exists. A name conflict happens when two or more mods
        // at the same level have the same name but different paths.
        // Levels (mods in higher levels override mods in lower levels):
-       // 1. common mod in modpack; 2. common mod;
-       // 3. game mod in modpack; 4. game mod;
-       // 5. world mod in modpack; 6. world mod;
-       // 7. addon mod in modpack; 8. addon mod.
+       // 1. game mod in modpack; 2. game mod;
+       // 3. world mod in modpack; 4. world mod;
+       // 5. addon mod in modpack; 6. addon mod.
        std::set<std::string> m_name_conflicts;
 
 };