From 70ac94ea9dc75df09e5ec0f22440944d543dc0c9 Mon Sep 17 00:00:00 2001
From: client_Zxw <826696702@qq.com>
Date: 星期六, 25 八月 2018 17:26:56 +0800
Subject: [PATCH] [1713]切换账号时XP抛出一个异常 加个防范
---
System/MainInterfacePanel/XpSkill.cs | 5 +++++
1 files changed, 5 insertions(+), 0 deletions(-)
diff --git a/System/MainInterfacePanel/XpSkill.cs b/System/MainInterfacePanel/XpSkill.cs
index e356b84..3e6fa0c 100644
--- a/System/MainInterfacePanel/XpSkill.cs
+++ b/System/MainInterfacePanel/XpSkill.cs
@@ -54,6 +54,11 @@
}
_XpSkill = Config.Instance.Get<SkillConfig>(SkillID);
Skill _skill = PlayerDatas.Instance.hero.SkillMgr.Get(_XpSkill.SkillID);
+ if (_skill == null)
+ {
+ XpButton.SetActive(false);
+ return;
+ }
if (_skill.IsValid())
{
XpButton.SetActive(true);
--
Gitblit v1.8.0