| System/Role/ReikiRootModel.cs | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
| System/Role/ReikiRootPointBehaviour.cs | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
| System/Role/ReikiRootRuleWin.cs | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
| System/Role/ReikiRootRuleWin.cs.meta | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
| System/Role/ReikiRootWin.cs | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
| System/Strengthening/HowToPlayWin.cs | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 |
System/Role/ReikiRootModel.cs
@@ -294,6 +294,27 @@ return value; } public static string GetQualityLabel(int quality) { switch (quality) { case 1: return "【下品】"; case 2: return "【中品】"; case 3: return "【良品】"; case 4: return "【上品】"; case 5: return "【极品】"; case 6: return "【完美】"; default: return "【下品】"; } } public void ReceivePackage(HB107_tagMCRolePointInfo package) { for (int i = 0; i < package.PointAttrIDCount; i++) System/Role/ReikiRootPointBehaviour.cs
@@ -8,7 +8,6 @@ public class ReikiRootPointBehaviour : MonoBehaviour { [SerializeField] Text m_PropertyName; [SerializeField] Text m_PropertyValue; [SerializeField] Text m_Point; [SerializeField] Button m_Add; [SerializeField] Button m_Sub; @@ -42,6 +41,8 @@ bool isPointAdd = false; bool isPointSub = false; int cacheQuality = 0; int coroutineCount = 0; static WaitForSeconds waitSpeedFaster = new WaitForSeconds(0.05f); @@ -62,24 +63,36 @@ { parent = win; this.id = id; DisplayBase(); cacheQuality = 0; DisplayPoint(); model.onReikiRootPointRefresh += OnReikiRootPointRefresh; } void DisplayBase() { var propertyConfig = PlayerPropertyConfig.Get(id); m_PropertyName.text = propertyConfig.Name; var qualiaty = model.GetReikiRootQuality(id); m_PropertyName.color = UIHelper.GetUIColor(qualiaty, true); m_PropertyValue.text = UIHelper.GetPropertyMapPlayerData((PropertyType)id).ToString(); } void DisplayPoint() { m_Point.text = point.ToString(); var original = model.GetReikiRootPoint(id); var addLabel = point == 0 ? string.Empty : UIHelper.AppendColor(TextColType.Green, "+" + point, true); var quality = model.GetReikiRootQuality(id, original + point); var areaPoint = model.GetQualityPoint(id, quality + 1); if (areaPoint == 0) { m_Point.text = StringUtility.Contact(original, addLabel); } else { m_Point.text = StringUtility.Contact(original, addLabel, "/", areaPoint); } if (cacheQuality != quality) { var propertyConfig = PlayerPropertyConfig.Get(id); m_PropertyName.text = StringUtility.Contact(propertyConfig.Name, ReikiRootModel.GetQualityLabel(quality)); m_PropertyName.color = UIHelper.GetUIColor(quality, true); cacheQuality = quality; } } private void OnAddDown(GameObject go) @@ -142,7 +155,14 @@ private void OnReikiRootPointRefresh() { DisplayBase(); if (point == 0) { DisplayPoint(); } else { point = 0; } } private void OpenKeyboard() System/Role/ReikiRootRuleWin.cs
New file @@ -0,0 +1,23 @@ //-------------------------------------------------------- // [Author]: 第二世界 // [ Date ]: Thursday, March 28, 2019 //-------------------------------------------------------- using System; using System.Collections; using System.Collections.Generic; using UnityEngine; using UnityEngine.UI; namespace Snxxz.UI { public class ReikiRootRuleWin : HowToPlayWin { } } System/Role/ReikiRootRuleWin.cs.meta
New file @@ -0,0 +1,12 @@ fileFormatVersion: 2 guid: 70cc833dda7ed2e40a98ba014ab16b95 timeCreated: 1553762754 licenseType: Pro MonoImporter: serializedVersion: 2 defaultReferences: [] executionOrder: 0 icon: {instanceID: 0} userData: assetBundleName: assetBundleVariant: System/Role/ReikiRootWin.cs
@@ -21,6 +21,7 @@ [SerializeField] Text m_FreePoint; [SerializeField] Button m_Recommend; [SerializeField] Button m_Confirm; [SerializeField] Button m_Rule; Dictionary<int, int> currentPropertyDict = new Dictionary<int, int>(); Dictionary<int, int> upPropertyDict = new Dictionary<int, int>(); @@ -43,6 +44,7 @@ { m_Recommend.AddListener(OnRecommend); m_Confirm.AddListener(Confirm); m_Rule.AddListener(OnRule); m_NumKeyboard.onValueChange.AddListener(OnPointValChange); m_NumKeyboard.onConfirm.AddListener((bool isOk) => @@ -227,6 +229,12 @@ } } private void OnRule() { ModelCenter.Instance.GetModel<HowToPlayModel>().ruleId = 44; WindowCenter.Instance.Open<ReikiRootRuleWin>(); } private void OnCacheFreePointRefresh() { DisplayFreePoint(); @@ -237,10 +245,6 @@ { if (dataType == PlayerDataType.FreePoint) { foreach (var reikiRootPoint in m_ReikiRootPoints) { reikiRootPoint.point = 0; } if (model.cacheFreePoint == model.freePoint) { OnCacheFreePointRefresh(); System/Strengthening/HowToPlayWin.cs
@@ -9,7 +9,7 @@ { [SerializeField] Text m_Title; [SerializeField] Text m_Description; [SerializeField] RectTransform desRect; [SerializeField] ScrollRect m_Scroller; [SerializeField] Button m_CloseBtn; [SerializeField] Button m_SureBtn; @@ -44,7 +44,7 @@ protected override void OnPreOpen() { desRect.anchoredPosition3D = new Vector3(desRect.anchoredPosition3D.x,140,0); m_Scroller.verticalNormalizedPosition = 1f; var config = RuleConfig.Get(model.ruleId); if (!string.IsNullOrEmpty(config.Title)) {