aboutsummaryrefslogtreecommitdiff
path: root/src/lua/common
diff options
context:
space:
mode:
Diffstat (limited to 'src/lua/common')
-rw-r--r--src/lua/common/je_lua.cpp5
-rw-r--r--src/lua/common/je_lua.h5
2 files changed, 10 insertions, 0 deletions
diff --git a/src/lua/common/je_lua.cpp b/src/lua/common/je_lua.cpp
index 0b6c498..73f671c 100644
--- a/src/lua/common/je_lua.cpp
+++ b/src/lua/common/je_lua.cpp
@@ -33,6 +33,11 @@ namespace JinEngine
return obj;
}
+ LuaObject* luax_checkobject(lua_State* L, int idx, const char* type)
+ {
+ return (LuaObject*)luax_checktype(L, idx, type);
+ }
+
LuaObject* luax_copyinstance(lua_State* to, LuaObject* src)
{
if (to == src->state)
diff --git a/src/lua/common/je_lua.h b/src/lua/common/je_lua.h
index 24f89fe..b390e4c 100644
--- a/src/lua/common/je_lua.h
+++ b/src/lua/common/je_lua.h
@@ -28,6 +28,11 @@ namespace JinEngine
LuaObject* luax_copyinstance(lua_State* to, LuaObject* src);
///
+ ///
+ ///
+ LuaObject* luax_checkobject(lua_State* L, int idx, const char* type);
+
+ ///
/// Access lua object by object pointer.
///
int luax_getobject(lua_State* L, SharedBase* shared);