| | |
| | | using System;
|
| | | using System.Collections; |
| | | using System.Collections.Generic; |
| | | using System.Text;
|
| | | using TableConfig;
|
| | | using UnityEngine; |
| | | using UnityEngine.UI;
|
| | |
| | | if (m_SkillDescription != null)
|
| | | {
|
| | | m_SkillDescription.text = string.Empty;
|
| | | if (ActivateShow.activateType == ActivateShow.ActivateFunc.GodWeaponEffect)
|
| | | {
|
| | | DisplayGodWeaponEffectProperty(config);
|
| | | }
|
| | | }
|
| | | }
|
| | |
|
| | | void DisplayGodWeaponEffectProperty(GodWeaponEffectConfig config)
|
| | | {
|
| | | var _model = ModelCenter.Instance.GetModel<MagicianModel>();
|
| | | Dictionary<int, int> dict;
|
| | | if (_model.TryGetEffectProperty(config.type, config.level, out dict))
|
| | | {
|
| | | var sb = new StringBuilder();
|
| | | foreach (var property in dict.Keys)
|
| | | {
|
| | | var propertyConfig = Config.Instance.Get<PlayerPropertyConfig>(property);
|
| | | if (propertyConfig != null)
|
| | | {
|
| | | sb.Append(propertyConfig.Name);
|
| | | sb.Append(StringUtility.Contact("+", UIHelper.ReplaceLargeNum(
|
| | | UIHelper.ReplacePercentage(dict[property], propertyConfig.ISPercentage,
|
| | | UIHelper.GetPropertyDecimalCount(property))),
|
| | | propertyConfig.ISPercentage == 1 ? "%" : string.Empty));
|
| | | sb.Append("\n");
|
| | | }
|
| | | }
|
| | | m_SkillDescription.text = sb.ToString();
|
| | | m_SkillDescription.color = UIHelper.GetUIColor(TextColType.DarkGreen);
|
| | | }
|
| | | }
|
| | |
|
| | |
| | | m_SkillIcon.SetSprite(config.IconName);
|
| | | m_SkillName.text = config.SkillName;
|
| | | m_SkillDescription.text = config.Description;
|
| | | m_SkillDescription.color = UIHelper.GetUIColor(TextColType.LightYellow);
|
| | | }
|
| | | }
|
| | |
|