18#include <unordered_map>
20#define LUA_USE_APICHECK
21#define LUABRIDGE_HAS_EXCEPTIONS 0
23#include <LuaBridge/LuaBridge.h>
44 void SetPathRoot(std::string_view str) { _pathRoot = std::string{ str }; }
48 bool DoFile(std::string_view path_name);
52 luabridge::LuaRef v = luabridge::getGlobal(L, name.data());
53 luabridge::LuaResult ret = v();
62 template <
typename T,
typename ...Args>
65 luabridge::LuaRef v = luabridge::getGlobal(L, name.data());
66 luabridge::LuaResult ret = v(args...);
77 lua_State*
GetL() {
return L; }
84 std::string _pathRoot;
bool DoFile(std::string_view path_name)
void SetPathRoot(std::string_view str)
设置加载根路径
bool ExcuteFunction(std::string_view name, Args &&... args)
bool DoString(std::string_view str)
bool ExcuteFunction(std::string_view name)