Merge branch 'master' of http://192.168.0.87:10010/r/snxxz_scripts
| | |
| | | }
|
| | | else
|
| | | {
|
| | | var unlockShowTreasure = 0;
|
| | | if (treasureModel.TryGetUnlockShowTreasure(out unlockShowTreasure))
|
| | | {
|
| | | treasureModel.treasureGotoId = gotoTreasureId;
|
| | | var config = Config.Instance.Get<TreasureConfig>(unlockShowTreasure);
|
| | | treasureModel.currentCategory = (TreasureCategory)config.Category;
|
| | | WindowJumpMgr.Instance.WindowJumpTo(JumpUIType.TreasureFunc1);
|
| | | }
|
| | | else
|
| | | {
|
| | | var config = Config.Instance.Get<TreasureConfig>(gotoTreasureId);
|
| | | treasureModel.selectedTreasure = gotoTreasureId;
|
| | | treasureModel.currentCategory = (TreasureCategory)config.Category;
|
| | |
| | | case 110:
|
| | | WindowJumpMgr.Instance.WindowJumpTo(JumpUIType.StfTs);
|
| | | break;
|
| | | }
|
| | |
|
| | | }
|
| | | }
|
| | | }
|
| | |
| | | m_BossIntroduce.gameObject.SetActive(false);
|
| | | m_ContainerMonster.gameObject.SetActive(true);
|
| | | m_BossIntroduce.Dispose();
|
| | | UI3DModelExhibition.Instance.BeginShowNPC(model.selectedBoss, Vector3.zero, m_MonsterPortrait);
|
| | | UI3DModelExhibition.Instance.BeginShowNPC(model.selectedBoss, npcConfig.UIModeLOffset, npcConfig.UIModelRotation, m_MonsterPortrait);
|
| | | m_MonsterLevel.text = Language.Get("Z1024", npcConfig.NPCLV);
|
| | | break;
|
| | | case 2:
|
| | |
| | | m_BossIntroduce.gameObject.SetActive(false);
|
| | | m_ContainerMonster.gameObject.SetActive(true);
|
| | | m_BossIntroduce.Dispose();
|
| | | UI3DModelExhibition.Instance.BeginShowNPC(_bossId, Vector3.zero, m_MonsterPortrait);
|
| | | var npcConfig = Config.Instance.Get<NPCConfig>(_bossId);
|
| | | UI3DModelExhibition.Instance.BeginShowNPC(_bossId, npcConfig.UIModeLOffset, npcConfig.UIModelRotation, m_MonsterPortrait);
|
| | | m_MonsterLevel.text = Language.Get("Z1024", npcConfig.NPCLV);
|
| | | break;
|
| | | case 2:
|
| | |
| | | var config = Config.Instance.Get<NPCConfig>(bossId);
|
| | | m_BossName.text = config.charName;
|
| | | m_BossLevel.text = Language.Get("Z1024", config.NPCLV);
|
| | | UI3DModelExhibition.Instance.BeginShowNPC(bossId, Vector3.zero, m_BossPortrait);
|
| | | UI3DModelExhibition.Instance.BeginShowNPC(bossId, config.UIModeLOffset, config.UIModelRotation, m_BossPortrait);
|
| | | m_BossAbility.Display(bossId);
|
| | | }
|
| | |
|
| | |
| | | public override void Init()
|
| | | {
|
| | | ParseConfig();
|
| | | UpdateRedpoint();
|
| | | playerPack.RefreshItemCountAct += RefreshItemCnt;
|
| | | playerPack.RefreshItemCountAct += RefreshItemCount;
|
| | | PlayerDatas.Instance.PlayerDataRefreshEvent += OnPlayerDataChange;
|
| | | dungeonModel.dungeonRecordChangeEvent += OnDungeonRecordChange;
|
| | |
|
| | | }
|
| | |
|
| | | public override void UnInit()
|
| | | {
|
| | | playerPack.RefreshItemCountAct -= RefreshItemCnt;
|
| | | playerPack.RefreshItemCountAct -= RefreshItemCount;
|
| | | PlayerDatas.Instance.PlayerDataRefreshEvent -= OnPlayerDataChange;
|
| | | dungeonModel.dungeonRecordChangeEvent -= OnDungeonRecordChange;
|
| | | }
|
| | |
|
| | | public void RequestSetDungeonAction()
|
| | |
| | | return sortedBossIds[0];
|
| | | }
|
| | |
|
| | | private void RefreshItemCnt(PackType type, int index, int id)
|
| | |
|
| | | private void OnPlayerDataChange(PlayerDataRefresh _type, int _value)
|
| | | {
|
| | | if (_type == PlayerDataRefresh.VIPLv)
|
| | | {
|
| | | UpdateRedpoint();
|
| | | }
|
| | | }
|
| | |
|
| | | private void RefreshItemCount(PackType type, int index, int id)
|
| | | {
|
| | | if (type == PackType.rptItem && id == dungeonTicket)
|
| | | {
|
| | |
| | | }
|
| | | }
|
| | |
|
| | | private void OnDungeonRecordChange(int _id)
|
| | | {
|
| | | if (_id == PERSONALBOSS_MAPID)
|
| | | {
|
| | | UpdateRedpoint();
|
| | | }
|
| | | }
|
| | |
|
| | |
|
| | | public void UpdateRedpoint()
|
| | | {
|
| | | if (!FuncOpen.Instance.IsFuncOpen(76))
|
| | |
| | |
|
| | | public void OnBeforePlayerDataInitialize()
|
| | | {
|
| | | m_storeModel.RefreshTCBPlayerDataEvent -= RefreshStoreScore;
|
| | | isXBCoolTime = false;
|
| | | XBNotifyParms.Clear();
|
| | | xbTypeInfoDict.Clear();
|
| | |
| | | {
|
| | | HAPPYXBITEMKEY = StringUtility.Contact(PlayerDatas.Instance.baseData.PlayerID, "HappyXBItemTime");
|
| | | XBWarehouseRedPoint();
|
| | | m_storeModel.RefreshTCBPlayerDataEvent -= RefreshStoreScore;
|
| | | m_storeModel.RefreshTCBPlayerDataEvent += RefreshStoreScore;
|
| | | playerPack.RefreshItemCountAct -= RefreshXBTool;
|
| | | playerPack.RefreshItemCountAct += RefreshXBTool;
|
| | |
| | | private void RefreshStoreScore(PlayerDataRefresh type)
|
| | | {
|
| | | if (type != PlayerDataRefresh.CDBPlayerRefresh_TreasureScore) return;
|
| | |
|
| | | XBStoreRedPoint();
|
| | | }
|
| | |
|
| | |
| | | private Redpoint realmRedpoint = new Redpoint(114);
|
| | | private Redpoint redPointVipDot = new Redpoint(RedPoint_VipDot);
|
| | |
|
| | | #region 角色红点
|
| | | public Redpoint roleRedpoint = new Redpoint(RedPoint_key, 101);
|
| | | #endregion
|
| | |
|
| | | #region 邮件红点
|
| | | public const int RedPoint_MainMailKey = 24;
|
| | | public const int RedPoint_MailFuncKey = 2401;
|
| | |
| | |
|
| | | protected override void OnPreClose()
|
| | | {
|
| | | PlayerDatas.Instance.PlayerDataRefreshInfoEvent += PlayerDataRefreshInfoEvent;
|
| | | PlayerDatas.Instance.PlayerDataRefreshInfoEvent -= PlayerDataRefreshInfoEvent;
|
| | | WindowCenter.Instance.windowAfterCloseEvent -= WindowAfterCloseEvent;
|
| | | StopBoss();
|
| | | UI3DModelExhibition.Instance.StopShowPlayer();
|
| | |
| | | taskName = taskInfoConfig == null ? string.Empty : taskInfoConfig.show_writing;
|
| | | }
|
| | | }
|
| | | equipPassSkills[i].skillData.m_SkillNameTxt.text = Language.Get("PassSkillHoleLimitTask", taskName);
|
| | | equipPassSkills[i].skillData.m_SkillNameTxt.text =
|
| | | UIHelper.ReplaceNewLine(Language.Get(StringUtility.Contact("PassSkillHoleLimitTask_", limit.OpenSkillSlots)));
|
| | | continue;
|
| | | }
|
| | | }
|
| | |
| | | taskName = taskInfoConfig == null ? string.Empty : taskInfoConfig.show_writing;
|
| | | }
|
| | | }
|
| | | SysNotifyMgr.Instance.ShowTip("PassEquipLimitTask", taskName);
|
| | | SysNotifyMgr.Instance.ShowTip(StringUtility.Contact("PassSkillHoleLimitTask_", limit.OpenSkillSlots));
|
| | | m_GetWayBtn.gameObject.SetActive(false);
|
| | | }
|
| | | }
|
| | |
| | |
|
| | | public GameFrame GetGameFrame()
|
| | | {
|
| | | return (GameFrame)LocalSave.GetInt(GAMEFRAME_KEY, (int)GameFrame.HalfFrame);
|
| | | return (GameFrame)LocalSave.GetInt(GAMEFRAME_KEY, (int)GameFrame.FullFrame);
|
| | | }
|
| | |
|
| | | public void SetSystemSettingSwitch(SystemSwitch type, bool _value)
|
| | |
| | | {
|
| | | var defaultQuality = GameQuality.High;
|
| | |
|
| | | if (DeviceUtility.cpu >= 4 && DeviceUtility.memory > 3.5f * 1024)
|
| | | {
|
| | | defaultQuality = GameQuality.High;
|
| | | }
|
| | | else if (DeviceUtility.cpu >= 4 && DeviceUtility.memory > 2.5f * 1024)
|
| | | {
|
| | | defaultQuality = GameQuality.Medium; ;
|
| | | }
|
| | | else if (DeviceUtility.cpu > 1 && DeviceUtility.memory > 1.5f * 1024)
|
| | | {
|
| | | defaultQuality = GameQuality.Low;
|
| | | }
|
| | | // if (DeviceUtility.cpu >= 4 && DeviceUtility.memory > 3.5f * 1024)
|
| | | // {
|
| | | // defaultQuality = GameQuality.High;
|
| | | // }
|
| | | // else if (DeviceUtility.cpu >= 4 && DeviceUtility.memory > 2.5f * 1024)
|
| | | // {
|
| | | // defaultQuality = GameQuality.Medium; ;
|
| | | // }
|
| | | // else if (DeviceUtility.cpu > 1 && DeviceUtility.memory > 1.5f * 1024)
|
| | | // {
|
| | | // defaultQuality = GameQuality.Low;
|
| | | // }
|
| | |
|
| | | return (GameQuality)LocalSave.GetInt(QUALITY_LEVEL_KEY, (int)defaultQuality);
|
| | | }
|
| | |
| | | {
|
| | | [SerializeField] Text m_SoulName;
|
| | | [SerializeField] Text m_SoulState;
|
| | | [SerializeField] Image m_Lock;
|
| | | [SerializeField] Image m_SelectImg;
|
| | | [SerializeField] Button m_SelectBtn;
|
| | | [SerializeField] RedpointBehaviour m_Redpoint;
|
| | |
| | | {
|
| | | if (special.active)
|
| | | {
|
| | | m_Lock.gameObject.SetActive(false);
|
| | | m_SoulState.text = Language.Get("TreasureSoul_Awoke");
|
| | | }
|
| | | else
|
| | |
| | | unlock = achievement.completed;
|
| | | }
|
| | | }
|
| | | m_Lock.gameObject.SetActive(!unlock);
|
| | | if (unlock)
|
| | | {
|
| | | m_SoulState.text = Language.Get("TreasureSoul_Awaking");
|
| | |
| | | {
|
| | | treasureSoulEvent((int)_data.PriID);
|
| | | }
|
| | | UpdateAchievementRedpoint((int)_data.PriID);
|
| | | continue;
|
| | | }
|
| | |
|
| | |
| | | var soulId = 0;
|
| | | if (int.TryParse(_tagWinSearchModel.SelectActive, out soulId))
|
| | | {
|
| | | var treasureModel = ModelCenter.Instance.GetModel<TreasureModel>();
|
| | | Treasure treasure;
|
| | | treasureModel.TryGetTreasure(soulId, out treasure);
|
| | | if (treasure == null || treasure.state != TreasureState.Collected)
|
| | | var soulModel = ModelCenter.Instance.GetModel<TreasureSoulModel>();
|
| | | if (!soulModel.IsOpenTreasureSoul(soulId))
|
| | | {
|
| | | return;
|
| | | }
|