#if USE_UNI_LUA using LuaAPI = UniLua.Lua; using RealStatePtr = UniLua.ILuaState; using LuaCSFunction = UniLua.CSharpFunctionDelegate; #else using LuaAPI = XLua.LuaDLL.Lua; using RealStatePtr = System.IntPtr; using LuaCSFunction = XLua.LuaDLL.lua_CSFunction; #endif using XLua; using System.Collections.Generic; namespace XLua.CSObjectWrap { using Utils = XLua.Utils; public class SnxxzUIHeavenBattleInfoWrap { public static void __Register(RealStatePtr L) { ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); System.Type type = typeof(Snxxz.UI.HeavenBattleInfo); Utils.BeginObjectRegister(type, L, translator, 0, 9, 7, 0); Utils.RegisterFunc(L, Utils.METHOD_IDX, "ResetModel", _m_ResetModel); Utils.RegisterFunc(L, Utils.METHOD_IDX, "SetHeavenBattleInfo", _m_SetHeavenBattleInfo); Utils.RegisterFunc(L, Utils.METHOD_IDX, "GetBattleResultByIndex", _m_GetBattleResultByIndex); Utils.RegisterFunc(L, Utils.METHOD_IDX, "SetHeavenBattlePlayerInfo", _m_SetHeavenBattlePlayerInfo); Utils.RegisterFunc(L, Utils.METHOD_IDX, "IsGetAwardByIndex", _m_IsGetAwardByIndex); Utils.RegisterFunc(L, Utils.METHOD_IDX, "GetBetRecordByIndex", _m_GetBetRecordByIndex); Utils.RegisterFunc(L, Utils.METHOD_IDX, "GetBetMoneyByIndex", _m_GetBetMoneyByIndex); Utils.RegisterFunc(L, Utils.METHOD_IDX, "bettingResultAct", _e_bettingResultAct); Utils.RegisterFunc(L, Utils.METHOD_IDX, "bettingRecordAct", _e_bettingRecordAct); Utils.RegisterFunc(L, Utils.GETTER_IDX, "Score1", _g_get_Score1); Utils.RegisterFunc(L, Utils.GETTER_IDX, "Score2", _g_get_Score2); Utils.RegisterFunc(L, Utils.GETTER_IDX, "TopScore", _g_get_TopScore); Utils.RegisterFunc(L, Utils.GETTER_IDX, "TopName", _g_get_TopName); Utils.RegisterFunc(L, Utils.GETTER_IDX, "Faction", _g_get_Faction); Utils.RegisterFunc(L, Utils.GETTER_IDX, "PlayerScore", _g_get_PlayerScore); Utils.RegisterFunc(L, Utils.GETTER_IDX, "WinCnt", _g_get_WinCnt); Utils.EndObjectRegister(type, L, translator, null, null, null, null, null); Utils.BeginClassRegister(type, L, __CreateInstance, 1, 0, 0); Utils.EndClassRegister(type, L, translator); } [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] static int __CreateInstance(RealStatePtr L) { try { ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); if(LuaAPI.lua_gettop(L) == 1) { Snxxz.UI.HeavenBattleInfo gen_ret = new Snxxz.UI.HeavenBattleInfo(); translator.Push(L, 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 Snxxz.UI.HeavenBattleInfo constructor!"); } [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] static int _m_ResetModel(RealStatePtr L) { try { ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); Snxxz.UI.HeavenBattleInfo gen_to_be_invoked = (Snxxz.UI.HeavenBattleInfo)translator.FastGetCSObj(L, 1); { gen_to_be_invoked.ResetModel( ); return 0; } } catch(System.Exception gen_e) { return LuaAPI.luaL_error(L, "c# exception:" + gen_e); } } [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] static int _m_SetHeavenBattleInfo(RealStatePtr L) { try { ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); Snxxz.UI.HeavenBattleInfo gen_to_be_invoked = (Snxxz.UI.HeavenBattleInfo)translator.FastGetCSObj(L, 1); { HAC02_tagGCXMZZInfo _info = (HAC02_tagGCXMZZInfo)translator.GetObject(L, 2, typeof(HAC02_tagGCXMZZInfo)); gen_to_be_invoked.SetHeavenBattleInfo( _info ); return 0; } } catch(System.Exception gen_e) { return LuaAPI.luaL_error(L, "c# exception:" + gen_e); } } [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] static int _m_GetBattleResultByIndex(RealStatePtr L) { try { ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); Snxxz.UI.HeavenBattleInfo gen_to_be_invoked = (Snxxz.UI.HeavenBattleInfo)translator.FastGetCSObj(L, 1); { int _index = LuaAPI.xlua_tointeger(L, 2); int gen_ret = gen_to_be_invoked.GetBattleResultByIndex( _index ); LuaAPI.xlua_pushinteger(L, gen_ret); return 1; } } catch(System.Exception gen_e) { return LuaAPI.luaL_error(L, "c# exception:" + gen_e); } } [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] static int _m_SetHeavenBattlePlayerInfo(RealStatePtr L) { try { ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); Snxxz.UI.HeavenBattleInfo gen_to_be_invoked = (Snxxz.UI.HeavenBattleInfo)translator.FastGetCSObj(L, 1); { HAC03_tagGCXMZZSelfInfo _info = (HAC03_tagGCXMZZSelfInfo)translator.GetObject(L, 2, typeof(HAC03_tagGCXMZZSelfInfo)); gen_to_be_invoked.SetHeavenBattlePlayerInfo( _info ); return 0; } } catch(System.Exception gen_e) { return LuaAPI.luaL_error(L, "c# exception:" + gen_e); } } [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] static int _m_IsGetAwardByIndex(RealStatePtr L) { try { ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); Snxxz.UI.HeavenBattleInfo gen_to_be_invoked = (Snxxz.UI.HeavenBattleInfo)translator.FastGetCSObj(L, 1); { int _index = LuaAPI.xlua_tointeger(L, 2); bool gen_ret = gen_to_be_invoked.IsGetAwardByIndex( _index ); LuaAPI.lua_pushboolean(L, gen_ret); return 1; } } catch(System.Exception gen_e) { return LuaAPI.luaL_error(L, "c# exception:" + gen_e); } } [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] static int _m_GetBetRecordByIndex(RealStatePtr L) { try { ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); Snxxz.UI.HeavenBattleInfo gen_to_be_invoked = (Snxxz.UI.HeavenBattleInfo)translator.FastGetCSObj(L, 1); { int _index = LuaAPI.xlua_tointeger(L, 2); int gen_ret = gen_to_be_invoked.GetBetRecordByIndex( _index ); LuaAPI.xlua_pushinteger(L, gen_ret); return 1; } } catch(System.Exception gen_e) { return LuaAPI.luaL_error(L, "c# exception:" + gen_e); } } [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] static int _m_GetBetMoneyByIndex(RealStatePtr L) { try { ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); Snxxz.UI.HeavenBattleInfo gen_to_be_invoked = (Snxxz.UI.HeavenBattleInfo)translator.FastGetCSObj(L, 1); { int _index = LuaAPI.xlua_tointeger(L, 2); int gen_ret = gen_to_be_invoked.GetBetMoneyByIndex( _index ); LuaAPI.xlua_pushinteger(L, gen_ret); return 1; } } catch(System.Exception gen_e) { return LuaAPI.luaL_error(L, "c# exception:" + gen_e); } } [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] static int _g_get_Score1(RealStatePtr L) { try { ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); Snxxz.UI.HeavenBattleInfo gen_to_be_invoked = (Snxxz.UI.HeavenBattleInfo)translator.FastGetCSObj(L, 1); LuaAPI.xlua_pushinteger(L, gen_to_be_invoked.Score1); } catch(System.Exception gen_e) { return LuaAPI.luaL_error(L, "c# exception:" + gen_e); } return 1; } [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] static int _g_get_Score2(RealStatePtr L) { try { ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); Snxxz.UI.HeavenBattleInfo gen_to_be_invoked = (Snxxz.UI.HeavenBattleInfo)translator.FastGetCSObj(L, 1); LuaAPI.xlua_pushinteger(L, gen_to_be_invoked.Score2); } catch(System.Exception gen_e) { return LuaAPI.luaL_error(L, "c# exception:" + gen_e); } return 1; } [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] static int _g_get_TopScore(RealStatePtr L) { try { ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); Snxxz.UI.HeavenBattleInfo gen_to_be_invoked = (Snxxz.UI.HeavenBattleInfo)translator.FastGetCSObj(L, 1); LuaAPI.xlua_pushinteger(L, gen_to_be_invoked.TopScore); } catch(System.Exception gen_e) { return LuaAPI.luaL_error(L, "c# exception:" + gen_e); } return 1; } [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] static int _g_get_TopName(RealStatePtr L) { try { ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); Snxxz.UI.HeavenBattleInfo gen_to_be_invoked = (Snxxz.UI.HeavenBattleInfo)translator.FastGetCSObj(L, 1); LuaAPI.lua_pushstring(L, gen_to_be_invoked.TopName); } catch(System.Exception gen_e) { return LuaAPI.luaL_error(L, "c# exception:" + gen_e); } return 1; } [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] static int _g_get_Faction(RealStatePtr L) { try { ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); Snxxz.UI.HeavenBattleInfo gen_to_be_invoked = (Snxxz.UI.HeavenBattleInfo)translator.FastGetCSObj(L, 1); LuaAPI.xlua_pushinteger(L, gen_to_be_invoked.Faction); } catch(System.Exception gen_e) { return LuaAPI.luaL_error(L, "c# exception:" + gen_e); } return 1; } [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] static int _g_get_PlayerScore(RealStatePtr L) { try { ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); Snxxz.UI.HeavenBattleInfo gen_to_be_invoked = (Snxxz.UI.HeavenBattleInfo)translator.FastGetCSObj(L, 1); LuaAPI.xlua_pushinteger(L, gen_to_be_invoked.PlayerScore); } catch(System.Exception gen_e) { return LuaAPI.luaL_error(L, "c# exception:" + gen_e); } return 1; } [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] static int _g_get_WinCnt(RealStatePtr L) { try { ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); Snxxz.UI.HeavenBattleInfo gen_to_be_invoked = (Snxxz.UI.HeavenBattleInfo)translator.FastGetCSObj(L, 1); LuaAPI.xlua_pushinteger(L, gen_to_be_invoked.WinCnt); } catch(System.Exception gen_e) { return LuaAPI.luaL_error(L, "c# exception:" + gen_e); } return 1; } [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] static int _e_bettingResultAct(RealStatePtr L) { try { ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); int gen_param_count = LuaAPI.lua_gettop(L); Snxxz.UI.HeavenBattleInfo gen_to_be_invoked = (Snxxz.UI.HeavenBattleInfo)translator.FastGetCSObj(L, 1); System.Action gen_delegate = translator.GetDelegate(L, 3); if (gen_delegate == null) { return LuaAPI.luaL_error(L, "#3 need System.Action!"); } if (gen_param_count == 3) { if (LuaAPI.xlua_is_eq_str(L, 2, "+")) { gen_to_be_invoked.bettingResultAct += gen_delegate; return 0; } if (LuaAPI.xlua_is_eq_str(L, 2, "-")) { gen_to_be_invoked.bettingResultAct -= gen_delegate; return 0; } } } catch(System.Exception gen_e) { return LuaAPI.luaL_error(L, "c# exception:" + gen_e); } LuaAPI.luaL_error(L, "invalid arguments to Snxxz.UI.HeavenBattleInfo.bettingResultAct!"); return 0; } [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] static int _e_bettingRecordAct(RealStatePtr L) { try { ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); int gen_param_count = LuaAPI.lua_gettop(L); Snxxz.UI.HeavenBattleInfo gen_to_be_invoked = (Snxxz.UI.HeavenBattleInfo)translator.FastGetCSObj(L, 1); System.Action gen_delegate = translator.GetDelegate(L, 3); if (gen_delegate == null) { return LuaAPI.luaL_error(L, "#3 need System.Action!"); } if (gen_param_count == 3) { if (LuaAPI.xlua_is_eq_str(L, 2, "+")) { gen_to_be_invoked.bettingRecordAct += gen_delegate; return 0; } if (LuaAPI.xlua_is_eq_str(L, 2, "-")) { gen_to_be_invoked.bettingRecordAct -= gen_delegate; return 0; } } } catch(System.Exception gen_e) { return LuaAPI.luaL_error(L, "c# exception:" + gen_e); } LuaAPI.luaL_error(L, "invalid arguments to Snxxz.UI.HeavenBattleInfo.bettingRecordAct!"); return 0; } } }