| | |
| | | Register(typeof(HA340_tagMCSuccessInfoList), typeof(DTCA340_tagMCSuccessInfoInfoList));
|
| | | Register(typeof(HA341_tagMCSuccessFinish), typeof(DTCA341_tagMCSuccessFinish));
|
| | | Register(typeof(HA342_tagMCSuccessFinishAwardRecordList), typeof(DTCA342_tagMCSuccessFinishAwardRecordList));
|
| | | Register(typeof(HA312_tagMCMagicWeaponData), typeof(DTCA312_tagMCMagicWeaponData));
|
| | | #endregion
|
| | |
|
| | | #region 组队
|
| | |
| | | { |
| | | ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); |
| | | System.Type type = typeof(MountModel); |
| | | Utils.BeginObjectRegister(type, L, translator, 0, 21, 17, 15); |
| | | Utils.BeginObjectRegister(type, L, translator, 0, 22, 17, 15); |
| | | |
| | | Utils.RegisterFunc(L, Utils.METHOD_IDX, "Init", _m_Init); |
| | | Utils.RegisterFunc(L, Utils.METHOD_IDX, "UnInit", _m_UnInit); |
| | |
| | | Utils.RegisterFunc(L, Utils.METHOD_IDX, "IsSkillUnlock", _m_IsSkillUnlock); |
| | | Utils.RegisterFunc(L, Utils.METHOD_IDX, "GetSkillUnlockLevel", _m_GetSkillUnlockLevel); |
| | | Utils.RegisterFunc(L, Utils.METHOD_IDX, "IsHorseMaxLevel", _m_IsHorseMaxLevel); |
| | | Utils.RegisterFunc(L, Utils.METHOD_IDX, "IsHorseUnlock", _m_IsHorseUnlock); |
| | | |
| | | Utils.RegisterFunc(L, Utils.METHOD_IDX, "onHorseInfoUpdate", _e_onHorseInfoUpdate); |
| | | |
| | |
| | | |
| | | } |
| | | |
| | | [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] |
| | | static int _m_IsHorseUnlock(RealStatePtr L) |
| | | { |
| | | try { |
| | | |
| | | ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); |
| | | |
| | | |
| | | MountModel gen_to_be_invoked = (MountModel)translator.FastGetCSObj(L, 1); |
| | | |
| | | |
| | | |
| | | { |
| | | int _horseId = LuaAPI.xlua_tointeger(L, 2); |
| | | |
| | | bool gen_ret = gen_to_be_invoked.IsHorseUnlock( _horseId ); |
| | | LuaAPI.lua_pushboolean(L, gen_ret); |
| | | |
| | | |
| | | |
| | | return 1; |
| | | } |
| | | |
| | | } catch(System.Exception gen_e) { |
| | | return LuaAPI.luaL_error(L, "c# exception:" + gen_e); |
| | | } |
| | | |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | |
| | | { |
| | | ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); |
| | | System.Type type = typeof(Snxxz.UI.PetModel); |
| | | Utils.BeginObjectRegister(type, L, translator, 0, 26, 18, 14); |
| | | Utils.BeginObjectRegister(type, L, translator, 0, 27, 18, 14); |
| | | |
| | | Utils.RegisterFunc(L, Utils.METHOD_IDX, "Init", _m_Init); |
| | | Utils.RegisterFunc(L, Utils.METHOD_IDX, "UnInit", _m_UnInit); |
| | |
| | | Utils.RegisterFunc(L, Utils.METHOD_IDX, "IsSkillUnlock", _m_IsSkillUnlock); |
| | | Utils.RegisterFunc(L, Utils.METHOD_IDX, "GetSkillUnlockLevel", _m_GetSkillUnlockLevel); |
| | | Utils.RegisterFunc(L, Utils.METHOD_IDX, "IsPetMaxLevel", _m_IsPetMaxLevel); |
| | | Utils.RegisterFunc(L, Utils.METHOD_IDX, "IsPetUnlock", _m_IsPetUnlock); |
| | | |
| | | Utils.RegisterFunc(L, Utils.METHOD_IDX, "PlayerLoginOkData", _e_PlayerLoginOkData); |
| | | Utils.RegisterFunc(L, Utils.METHOD_IDX, "onPetInfoUpdate", _e_onPetInfoUpdate); |
| | |
| | | |
| | | } |
| | | |
| | | [MonoPInvokeCallbackAttribute(typeof(LuaCSFunction))] |
| | | static int _m_IsPetUnlock(RealStatePtr L) |
| | | { |
| | | try { |
| | | |
| | | ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L); |
| | | |
| | | |
| | | Snxxz.UI.PetModel gen_to_be_invoked = (Snxxz.UI.PetModel)translator.FastGetCSObj(L, 1); |
| | | |
| | | |
| | | |
| | | { |
| | | int _petId = LuaAPI.xlua_tointeger(L, 2); |
| | | |
| | | bool gen_ret = gen_to_be_invoked.IsPetUnlock( _petId ); |
| | | LuaAPI.lua_pushboolean(L, gen_ret); |
| | | |
| | | |
| | | |
| | | return 1; |
| | | } |
| | | |
| | | } catch(System.Exception gen_e) { |
| | | return LuaAPI.luaL_error(L, "c# exception:" + gen_e); |
| | | } |
| | | |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | |
| | | return false;
|
| | | }
|
| | | } |
| | | |
| | | public bool IsHorseUnlock(int horseId)
|
| | | {
|
| | | return _DicHorse.ContainsKey(horseId);
|
| | | } |
| | | } |
| | |
| | | }
|
| | | return false;
|
| | | } |
| | | |
| | | public bool IsPetUnlock(int petId)
|
| | | {
|
| | | return _DicPetBack.ContainsKey(petId);
|
| | | } |
| | | }
|
| | | } |
| | |
| | | {
|
| | | base.OnPreOpen();
|
| | | DisplayButtons();
|
| | | var petHorseAwaking = LuaUtility.Global.Get<IPetHorseAwaking>("PetHorseAwakingModel");
|
| | | petHorseAwaking.onFuncStateUpdate += OnFuncStateUpdate;
|
| | | }
|
| | |
|
| | | protected override void OnPreClose()
|
| | | {
|
| | | var petHorseAwaking = LuaUtility.Global.Get<IPetHorseAwaking>("PetHorseAwakingModel");
|
| | | petHorseAwaking.onFuncStateUpdate -= OnFuncStateUpdate;
|
| | | base.OnPreClose();
|
| | | }
|
| | |
|
| | | protected override void OnActived()
|
| | |
| | | functionOrder = 2;
|
| | | }
|
| | |
|
| | | private void OnFuncStateUpdate()
|
| | | {
|
| | | DisplayButtons();
|
| | | }
|
| | |
|
| | | }
|
| | | }
|