public void OnClick(GameObject obj) { if (buttonindex == (int)enSkillIndex.Player_Skill_Beauty && PlayerData.Instance.BaseAttr.Level < BeautyOpenLevel) { //UITips.ShowTips(string.Format("魔神变身{0}级开放", BeautyOpenLevel)); UITips.ShowUnHeroModelShow(); return; } if (buttonindex == (int)enSkillIndex.Player_Skill_Beauty) { if (m_ImageDisable.gameObject.activeSelf) { // UITips.ShowTips(string.Format("您未获得魔神")); UITips.ShowUnHeroModelShow(); return; } else { if (guidewidget != null) { guidewidget.OnButtonClick(); } if (m_ImageCD.fillAmount < 1) { string strTips = Localization.Get("技能冷却中"); if (strTips.Length > 0) { UITips.ShowTips(strTips); } } } } if (m_ImageDisable.gameObject.activeSelf) { if (buttonindex == (int)enSkillIndex.Player_Skill_WangzheVip) { MainPanelMgr.Instance.ShowDialog("UIBaiYinVIP"); return; } UITips.ShowTips(string.Format("该技能尚未解锁")); return; } if (skillID == 0) { return; } if (CoreEntry.gActorMgr.MainPlayer != null) { if (buttonindex == (int)enSkillIndex.Player_att || buttonindex == (int)enSkillIndex.Beauty_att) { CoreEntry.gActorMgr.MainPlayer.ReleaseCanNotBeControlledByInputFromNormalAttack(); } } LuaTable skill = ConfigManager.Instance.Skill.GetSkillConfig(skillID); if (skill == null) { return; } if (SkillBase.GetSkillVersion(CoreEntry.gActorMgr.MainPlayer, skill) == 2 && CoreEntry.gActorMgr.MainPlayer.curActorState != ACTOR_STATE.AS_AIMING) { return; } SDKMgr.Instance.TrackGameOptLog(1, 500 + buttonindex); m_isDrag = false; //m_isClick = false; // 按住不能放技能 m_sendRatio = 0.05f; if (buttonindex == (int)enSkillIndex.Player_Skill_Beauty) { LogMgr.UnityWarning("Player_Skill_Beauty:" + skillID); } ModuleServer.MS.GSkillCastMgr.CastSkill(skillID); }