diff options
Diffstat (limited to 'server/src/matcher/library.lua')
-rw-r--r-- | server/src/matcher/library.lua | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/server/src/matcher/library.lua b/server/src/matcher/library.lua index dbc96af6..edd3b86e 100644 --- a/server/src/matcher/library.lua +++ b/server/src/matcher/library.lua @@ -139,6 +139,18 @@ local function init() mergeLibs(alllibs, libs) end + function alllibs:get(type, parent, child) + local info = self[type] and self[type][parent] + if not info then + return nil + end + if child then + return info.child[child] + else + return info.lib + end + end + return alllibs end |