| | |
| | |
|
| | | public class WorldMapUnLockTip : MonoBehaviour
|
| | | {
|
| | | [SerializeField] Image m_LevelConditionSign;
|
| | | [SerializeField] Image m_TreasureConditionSign;
|
| | | [SerializeField] Text m_LevelCondtion;
|
| | | [SerializeField] Text m_TreasureCondition;
|
| | |
|
| | | TreasureModel treasureModel { get { return ModelCenter.Instance.GetModel<TreasureModel>(); } }
|
| | | [SerializeField] Image m_ConditionSign1;
|
| | | [SerializeField] Image m_ConditionSign2;
|
| | | [SerializeField] Text m_Condtion1;
|
| | | [SerializeField] Text m_Condition2;
|
| | |
|
| | | public void Display(int _mapId)
|
| | | {
|
| | | var config = MapConfig.Get(_mapId);
|
| | | m_LevelCondtion.text = Language.Get("WorldMap_LV", config.LV);
|
| | | m_LevelCondtion.color = PlayerDatas.Instance.baseData.LV >= config.LV ? UIHelper.GetUIColor(TextColType.Green) : UIHelper.GetUIColor(TextColType.Red);
|
| | |
|
| | | if (string.IsNullOrEmpty(config.MapTaskText))
|
| | | if (config.realmLevel > 0)
|
| | | {
|
| | | m_TreasureConditionSign.gameObject.SetActive(false);
|
| | | m_TreasureCondition.text = "";
|
| | | var realmConfig = RealmConfig.Get(config.realmLevel);
|
| | | m_Condtion1.text = Language.Get("WorldMap_Realm", realmConfig.Name);
|
| | | m_Condtion1.color = UIHelper.GetUIColor(PlayerDatas.Instance.baseData.realmLevel >= config.realmLevel ? TextColType.Green : TextColType.Red);
|
| | | }
|
| | | else
|
| | | {
|
| | | m_TreasureConditionSign.gameObject.SetActive(true);
|
| | | m_TreasureCondition.text = config.MapTaskText;
|
| | | m_Condtion1.text = Language.Get("WorldMap_LV", config.LV);
|
| | | m_Condtion1.color = UIHelper.GetUIColor(PlayerDatas.Instance.baseData.LV >= config.LV ? TextColType.Green : TextColType.Red);
|
| | | }
|
| | |
|
| | | if (string.IsNullOrEmpty(config.MapTaskText))
|
| | | {
|
| | | m_ConditionSign2.gameObject.SetActive(false);
|
| | | m_Condition2.text = "";
|
| | | }
|
| | | else
|
| | | {
|
| | | m_ConditionSign2.gameObject.SetActive(true);
|
| | | m_Condition2.text = config.MapTaskText;
|
| | | }
|
| | | }
|
| | |
|