Exemplo n.º 1
0
        static int _g_get_score(RealStatePtr L)
        {
            ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

            try {
                xc.DungeonDeadSpaceScore __cl_gen_to_be_invoked = (xc.DungeonDeadSpaceScore)translator.FastGetCSObj(L, 1);
                LuaAPI.xlua_pushuint(L, __cl_gen_to_be_invoked.score);
            } catch (System.Exception __gen_e) {
                return(LuaAPI.luaL_error(L, "c# exception:" + __gen_e));
            }
            return(1);
        }
Exemplo n.º 2
0
        static int _s_set_exp(RealStatePtr L)
        {
            ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

            try {
                xc.DungeonDeadSpaceScore __cl_gen_to_be_invoked = (xc.DungeonDeadSpaceScore)translator.FastGetCSObj(L, 1);
                __cl_gen_to_be_invoked.exp = LuaAPI.lua_touint64(L, 2);
            } catch (System.Exception __gen_e) {
                return(LuaAPI.luaL_error(L, "c# exception:" + __gen_e));
            }
            return(0);
        }
Exemplo n.º 3
0
        static int __CreateInstance(RealStatePtr L)
        {
            ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

            try {
                if (LuaAPI.lua_gettop(L) == 4 && LuaTypes.LUA_TNUMBER == LuaAPI.lua_type(L, 2) && LuaTypes.LUA_TNUMBER == LuaAPI.lua_type(L, 3) && (LuaTypes.LUA_TNUMBER == LuaAPI.lua_type(L, 4) || LuaAPI.lua_isuint64(L, 4)))
                {
                    uint  lv    = LuaAPI.xlua_touint(L, 2);
                    uint  score = LuaAPI.xlua_touint(L, 3);
                    ulong exp   = LuaAPI.lua_touint64(L, 4);

                    xc.DungeonDeadSpaceScore __cl_gen_ret = new xc.DungeonDeadSpaceScore(lv, score, exp);
                    translator.Push(L, __cl_gen_ret);
                    return(1);
                }
            }
            catch (System.Exception __gen_e) {
                return(LuaAPI.luaL_error(L, "c# exception:" + __gen_e));
            }
            return(LuaAPI.luaL_error(L, "invalid arguments to xc.DungeonDeadSpaceScore constructor!"));
        }