Пример #1
0
 static int CaculateDistance(IntPtr L)
 {
     try
     {
         ToLua.CheckArgsCount(L, 5);
         GameSDKInterface obj  = (GameSDKInterface)ToLua.CheckObject <GameSDKInterface>(L, 1);
         double           arg0 = (double)LuaDLL.luaL_checknumber(L, 2);
         double           arg1 = (double)LuaDLL.luaL_checknumber(L, 3);
         double           arg2 = (double)LuaDLL.luaL_checknumber(L, 4);
         double           arg3 = (double)LuaDLL.luaL_checknumber(L, 5);
         double           o    = obj.CaculateDistance(arg0, arg1, arg2, arg3);
         LuaDLL.lua_pushnumber(L, o);
         return(1);
     }
     catch (Exception e)
     {
         return(LuaDLL.toluaL_exception(L, e));
     }
 }