diff options
author | Mattes D <github@xoft.cz> | 2016-03-02 10:05:10 +0100 |
---|---|---|
committer | Mattes D <github@xoft.cz> | 2016-06-27 20:51:48 +0200 |
commit | af8c96026d458481543ead176bd15651857826bd (patch) | |
tree | 1635300b69ceed70abe1195cf7e23c51b2546b73 /src/Bindings/PluginManager.cpp | |
parent | Added cLuaState::cCallback for representing (resettable) Lua callbacks. (diff) | |
download | cuberite-af8c96026d458481543ead176bd15651857826bd.tar cuberite-af8c96026d458481543ead176bd15651857826bd.tar.gz cuberite-af8c96026d458481543ead176bd15651857826bd.tar.bz2 cuberite-af8c96026d458481543ead176bd15651857826bd.tar.lz cuberite-af8c96026d458481543ead176bd15651857826bd.tar.xz cuberite-af8c96026d458481543ead176bd15651857826bd.tar.zst cuberite-af8c96026d458481543ead176bd15651857826bd.zip |
Diffstat (limited to 'src/Bindings/PluginManager.cpp')
-rw-r--r-- | src/Bindings/PluginManager.cpp | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/Bindings/PluginManager.cpp b/src/Bindings/PluginManager.cpp index 5b3ef7803..203450505 100644 --- a/src/Bindings/PluginManager.cpp +++ b/src/Bindings/PluginManager.cpp @@ -1965,6 +1965,23 @@ bool cPluginManager::ForEachPlugin(cPluginCallback & a_Callback) +AString cPluginManager::GetPluginFolderName(const AString & a_PluginName) +{ + // TODO: Implement locking for plugins + for (auto & plugin: m_Plugins) + { + if (plugin->GetName() == a_PluginName) + { + return plugin->GetFolderName(); + } + } + return AString(); +} + + + + + void cPluginManager::AddHook(cPlugin * a_Plugin, int a_Hook) { if (a_Plugin == nullptr) |