diff options
author | Loic Blot <loic.blot@unix-experience.fr> | 2017-01-21 15:02:08 +0100 |
---|---|---|
committer | Loïc Blot <nerzhul@users.noreply.github.com> | 2017-03-13 23:56:05 +0100 |
commit | 2efae3ffd720095222c800e016286a45c9fe1e5c (patch) | |
tree | 3a8b19daa071cf742fee52d70a0e0adf94d56c0c /src/unittest/test.cpp | |
parent | c9492b4d37c11f35cfdc1558f771eef87fc5c972 (diff) | |
download | minetest-2efae3ffd720095222c800e016286a45c9fe1e5c.tar.gz minetest-2efae3ffd720095222c800e016286a45c9fe1e5c.tar.bz2 minetest-2efae3ffd720095222c800e016286a45c9fe1e5c.zip |
[CSM] Client side modding
* rename GameScripting to ServerScripting
* Make getBuiltinLuaPath static serverside
* Add on_shutdown callback
* Add on_receiving_chat_message & on_sending_chat_message callbacks
* ScriptApiBase: use IGameDef instead of Server
This permits to share common attribute between client & server
* Enable mod security in client side modding without conditions
Diffstat (limited to 'src/unittest/test.cpp')
-rw-r--r-- | src/unittest/test.cpp | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/unittest/test.cpp b/src/unittest/test.cpp index 41ccf0d2d..9beb0afa6 100644 --- a/src/unittest/test.cpp +++ b/src/unittest/test.cpp @@ -19,10 +19,10 @@ with this program; if not, write to the Free Software Foundation, Inc., #include "test.h" -#include "log.h" #include "nodedef.h" #include "itemdef.h" #include "gamedef.h" +#include "mods.h" content_t t_CONTENT_STONE; content_t t_CONTENT_GRASS; @@ -59,6 +59,13 @@ public: void defineSomeNodes(); + virtual const std::vector<ModSpec> &getMods() const + { + static std::vector<ModSpec> testmodspec; + return testmodspec; + } + virtual const ModSpec* getModSpec(const std::string &modname) const { return NULL; } + private: IItemDefManager *m_itemdef; INodeDefManager *m_nodedef; |