| | |
| | | RealmConfig _cfg = ConfigManager.Instance.GetTemplate<RealmConfig>(id);
|
| | | if (_cfg != null)
|
| | | {
|
| | | return GetTextColorByItemColor(_cfg.Name, _cfg.Quality, _dict);
|
| | | var text = RichTextMgr.Inst.presentRichText;
|
| | | int colorType = 0;
|
| | | if (text != null)
|
| | | {
|
| | | colorType = text.colorType == RichText.ColorType.Dark ? 0 : 1;
|
| | | }
|
| | | return UIHelper.GetRealmName(id, colorType == 1);
|
| | | }
|
| | | }
|
| | | }
|
| | |
| | |
|
| | | public void Open()
|
| | | {
|
| | | if (!WindowCenter.Instance.CheckOpen<RealmBossShowWin>())
|
| | | {
|
| | | WindowCenter.Instance.Open<RealmBossShowWin>(true);
|
| | | }
|
| | | StartCoroutine(Co_Start());
|
| | | }
|
| | |
|
| | | IEnumerator Co_Start()
|
| | | {
|
| | | yield return WaitingForSecondConst.WaitMS1500;
|
| | | WindowCenter.Instance.CloseImmediately<RealmBossShowWin>();
|
| | | StartBossShow();
|
| | | }
|
| | |
|
| | | void StartBossShow()
|
| | | {
|
| | | if (IsOpen)
|
| | | {
|
| | | return;
|
| | |
| | | StageManager.Instance.onStartStageLoadingEvent -= OnStartStageLoadingEvent;
|
| | | CameraController.Instance.CameraObject.gameObject.SetActive(true);
|
| | | WindowCenter.Instance.uiRoot.uicamera.enabled = true;
|
| | | WindowCenter.Instance.CloseImmediately<RealmBossShowWin>();
|
| | | showCamera.enabled = false;
|
| | | m_Effect.gameObject.SetActive(false);
|
| | | transform.localPosition = new Vector3(0, 4000, 5000);
|
| New file |
| | |
| | | //--------------------------------------------------------
|
| | | // [Author]: 第二世界
|
| | | // [ Date ]: Friday, August 10, 2018
|
| | | //--------------------------------------------------------
|
| | |
|
| | | using System;
|
| | | using System.Collections;
|
| | | using System.Collections.Generic;
|
| | | using UnityEngine;
|
| | | using UnityEngine.UI;
|
| | |
|
| | | namespace Snxxz.UI {
|
| | |
|
| | | public class RealmBossShowWin : Window
|
| | | {
|
| | |
|
| | | #region Built-in
|
| | | protected override void BindController()
|
| | | {
|
| | | }
|
| | |
|
| | | protected override void AddListeners()
|
| | | {
|
| | | }
|
| | |
|
| | | protected override void OnPreOpen()
|
| | | {
|
| | | }
|
| | |
|
| | | protected override void OnAfterOpen()
|
| | | {
|
| | | }
|
| | |
|
| | | protected override void OnPreClose()
|
| | | {
|
| | | }
|
| | |
|
| | | protected override void OnAfterClose()
|
| | | {
|
| | | }
|
| | | #endregion
|
| | | |
| | | }
|
| | |
|
| | | }
|
| | |
|
| | |
|
| | |
|
| | |
|
| New file |
| | |
| | | fileFormatVersion: 2 |
| | | guid: bd3875ace2b548c438ef6672e1653819 |
| | | timeCreated: 1533902258 |
| | | licenseType: Pro |
| | | MonoImporter: |
| | | serializedVersion: 2 |
| | | defaultReferences: [] |
| | | executionOrder: 0 |
| | | icon: {instanceID: 0} |
| | | userData: |
| | | assetBundleName: |
| | | assetBundleVariant: |
| | |
| | | }
|
| | | }
|
| | | m_SpecialProperty.DisplayColon(config.specialProperty, config.AddAttrNum[index]);
|
| | | m_HurtRemind.text = UIHelper.ReplaceNewLine(Language.Get("RealmSuppressHurt", UIHelper.GetTextColorByItemColor(config.Quality, config.Name), (float)model.realmSuppressHurt / 1000));
|
| | | m_HurtRemind.text = UIHelper.ReplaceNewLine(Language.Get("RealmSuppressHurt", UIHelper.GetRealmName(config.Lv), (float)model.realmSuppressHurt / 1000));
|
| | | }
|
| | | }
|
| | |
|
| | |
| | | return msg;
|
| | | }
|
| | |
|
| | | public static string GetRealmName(int realmLv, bool bright = false)
|
| | | {
|
| | | var config = ConfigManager.Instance.GetTemplate<RealmConfig>(realmLv);
|
| | | if (config == null)
|
| | | {
|
| | | return string.Empty;
|
| | | }
|
| | | switch (config.Quality)
|
| | | {
|
| | | case 1:
|
| | | return StringUtility.Contact("<color=#", bright ? "686868" : "f7f7f7", ">", config.Name, "</color>");
|
| | | case 2:
|
| | | return StringUtility.Contact("<color=#", bright ? "08d00a" : "08d00a", ">", config.Name, "</color>");
|
| | | case 3:
|
| | | return StringUtility.Contact("<color=#", bright ? "006be3" : "31cefb", ">", config.Name, "</color>");
|
| | | case 4:
|
| | | return StringUtility.Contact("<color=#", bright ? "da48d5" : "ec4bf6", ">", config.Name, "</color>");
|
| | | case 5:
|
| | | return StringUtility.Contact("<color=#", bright ? "ff6701" : "f8983b", ">", config.Name, "</color>");
|
| | | case 6:
|
| | | return StringUtility.Contact("<color=#", bright ? "ff0303" : "ff0101", ">", config.Name, "</color>");
|
| | | case 7:
|
| | | return StringUtility.Contact("<color=#", bright ? "f6408d" : "ff7c7c", ">", config.Name, "</color>");
|
| | | case 8:
|
| | | return StringUtility.Contact("<color=#", bright ? "bb8800" : "ffde00", ">", config.Name, "</color>");
|
| | | case 9:
|
| | | return StringUtility.Contact("<color=#", bright ? "ff0303" : "ff0101", ">", config.Name, "</color>");
|
| | | default:
|
| | | return config.Name;
|
| | | }
|
| | | }
|
| | |
|
| | | public static string GetTextColorByItemColor(int itemColor, string msg, bool bright = false)
|
| | | {
|
| | | switch (itemColor)
|