Merge branch 'master' of http://192.168.0.87:10010/r/snxxz_scripts
| | |
| | | public int pkState;//是否在pk中 175 1--进入状态 2--退出状态
|
| | | public int bossState;//Boss状态 176 1--进入状态 2--退出状态
|
| | | public int OnlyFinalHurt;
|
| | | public int forbidenTalk;
|
| | | public int NpcHurtAddPer;//对怪物伤害加成 188
|
| | | public int FunalHurtPer;//对怪物伤害加成 189
|
| | | } |
| | |
| | | case PlayerDataRefresh.FunalHurtPer:
|
| | | extersion.FunalHurtPer = (int)value;
|
| | | break;
|
| | | case PlayerDataRefresh.CDBPlayerRefresh_ForbidenTalk:
|
| | | extersion.forbidenTalk = (int)value;
|
| | | break;
|
| | | }
|
| | | }
|
| | |
|
| | |
| | | const string downloadUrl = "http://{0}.voice.2460web.com:53001/voice/download";
|
| | | private void SendSpeech(byte[] encode, long _tick)
|
| | | {
|
| | | if (IsChatBanned)
|
| | | {
|
| | | SaveSpeech((int)PlayerDatas.Instance.PlayerId, _tick, encode);
|
| | | return;
|
| | | }
|
| | | VoiceHttpRequest.Instance.Enqueue(encode, _tick, (int)PlayerDatas.Instance.PlayerId);
|
| | | }
|
| | |
|
| | |
| | | }
|
| | | #endregion
|
| | |
|
| | | #region 聊天黑名单
|
| | |
|
| | | public string SetChatExtra()
|
| | | {
|
| | | var vipLevel = PlayerDatas.Instance.baseData.VIPLv;
|
| | | var job = PlayerDatas.Instance.baseData.Job;
|
| | | return StringUtility.Contact(vipLevel.ToString().PadLeft(2, '0'), 0, job);
|
| | | }
|
| | |
|
| | | public void HandleChatBanned(ChatInfoType channel, string message, int toPlayer)
|
| | | {
|
| | | if (IsChatBanned)
|
| | | {
|
| | | var playerId = PlayerDatas.Instance.baseData.PlayerID;
|
| | | var playerName = UIHelper.ServerStringTrim(PlayerDatas.Instance.baseData.PlayerName);
|
| | | switch (channel)
|
| | | {
|
| | | case ChatInfoType.World:
|
| | | ChatCtrl.Inst.RevChatInfo(new H0201_tagTalkGong()
|
| | | {
|
| | | Content = message,
|
| | | Extras = SetChatExtra(),
|
| | | PlayerID = playerId,
|
| | | Name = playerName,
|
| | | });
|
| | | break;
|
| | | case ChatInfoType.Area:
|
| | | ChatCtrl.Inst.RevChatInfo(new H0207_tagTalkArea()
|
| | | {
|
| | | Content = message,
|
| | | Extras = SetChatExtra(),
|
| | | PlayerID = playerId,
|
| | | SrcName = playerName,
|
| | | });
|
| | | break;
|
| | | case ChatInfoType.Team:
|
| | | ChatCtrl.Inst.RevChatInfo(new H0205_tagTalkDui()
|
| | | {
|
| | | PlayerID = playerId,
|
| | | Name = playerName,
|
| | | Content = message,
|
| | | Extras = SetChatExtra(),
|
| | | });
|
| | | break;
|
| | | case ChatInfoType.Fairy:
|
| | | ChatCtrl.Inst.RevChatInfo(new H0203_tagTalkBang()
|
| | | {
|
| | | PlayerID = playerId,
|
| | | Content = message,
|
| | | Extras = SetChatExtra(),
|
| | | Name = playerName,
|
| | | });
|
| | | break;
|
| | | case ChatInfoType.Friend:
|
| | | ChatCtrl.Inst.RevChatInfo(new H0206_tagTalkMi()
|
| | | {
|
| | | PlayerID = playerId,
|
| | | SrcName = playerName,
|
| | | Content = message,
|
| | | Extras = SetChatExtra(),
|
| | | ToPlayerID = (uint)toPlayer,
|
| | | ToName = string.Empty,
|
| | | TalkType = 1,
|
| | | });
|
| | | break;
|
| | | }
|
| | | }
|
| | | }
|
| | |
|
| | | public bool IsChatBanned
|
| | | {
|
| | | get
|
| | | {
|
| | | var value = PlayerDatas.Instance.extersion.forbidenTalk;
|
| | | var serverBanned = value == 1;
|
| | | return serverBanned;
|
| | | }
|
| | | }
|
| | | #endregion
|
| | |
|
| | | }
|
| | | }
|
| | |
|
| | |
| | | {
|
| | | try
|
| | | {
|
| | | if (chatCenter.IsChatBanned)
|
| | | {
|
| | | return;
|
| | | }
|
| | | var channelName = string.Empty;
|
| | | switch (chatType)
|
| | | {
|
| | |
| | |
|
| | | public void SendChatInfo(ChatInfoType type, string msg, ChatExtraData? info = null)
|
| | | {
|
| | | bool _dirty = false;
|
| | | bool isDirty = false;
|
| | | bool isVoice = ChatCenter.s_VoiceRegex.IsMatch(msg);
|
| | |
|
| | | if (CheckEmptyChat(msg))
|
| | | {
|
| | |
| | |
|
| | | ChatReport(type, msg, PteChatName);
|
| | |
|
| | | if (!ChatCenter.s_VoiceRegex.IsMatch(msg)
|
| | | && !InviteRegex.IsMatch(msg))
|
| | | if (!isVoice && !InviteRegex.IsMatch(msg))
|
| | | {
|
| | | _dirty = DirtyWordConfig.IsDirtWord(msg);
|
| | | isDirty = DirtyWordConfig.IsDirtWord(msg);
|
| | | msg = DirtyWordConfig.IsDirtWord(msg, '*');
|
| | | var length = msg.Length;
|
| | | if (length > CHAT_INFO_CNT)
|
| | |
| | | if (ok)
|
| | | {
|
| | | ChatCenter.RecentlyChat _recentlyChat = null;
|
| | | if (!_dirty)
|
| | | if (!isDirty && !isVoice)
|
| | | {
|
| | | _recentlyChat = chatCenter.SaveRecentlyChat(result);
|
| | | }
|
| | | msg = CheckHasItem(result, _recentlyChat);
|
| | | chatCenter.recentlyChat = null;
|
| | |
|
| | | if (chatCenter.IsChatBanned)
|
| | | {
|
| | | var toPlayer = PteChatID;
|
| | | if (info.HasValue && info.Value.infoint1 == 0)
|
| | | {
|
| | | toPlayer = info.Value.infoint1;
|
| | | }
|
| | | chatCenter.HandleChatBanned(type, msg, toPlayer);
|
| | | return;
|
| | | }
|
| | |
|
| | | switch (type)
|
| | | {
|
| | | case ChatInfoType.World:
|
| | |
| | | _pak.Text = msg;
|
| | | GameNetSystem.Instance.SendInfo(_pak);
|
| | | }
|
| | | }
|
| | | break;
|
| | | case ChatInfoType.Invite:
|
| | | {
|
| | | SendInvite(msg);
|
| | | }
|
| | | break;
|
| | | }
|
| | |
| | | ItemConfig cfg = Config.Instance.Get<ItemConfig>(itemID);
|
| | | if (cfg != null)
|
| | | {
|
| | | string append = string.Format("<a><Word info=item id={1} userdata={5} chatsend=1/>|showitem={1} isbind={2} itemcnt={3} stone={4} userdata={5} suitLv={6} suitCnt={7} place={8} equipwash={9}</a>",
|
| | | cfg.ItemColor, strarray[0], strarray[1], strarray[2], strarray[3], strarray[4], strarray[5], strarray[6], strarray[7], strarray[8]);
|
| | | try
|
| | | {
|
| | | string append = string.Format("<a><Word info=item id={0} userdata={4} chatsend=1/>|showitem={0} isbind={1} itemcnt={2} stone={3} userdata={4} suitLv={5} suitCnt={6} place={7} equipwash={8}</a>",
|
| | | strarray[0], strarray[1], strarray[2], strarray[3], strarray[4], strarray[5], strarray[6], strarray[7], strarray[8]);
|
| | | append = UIHelper.GetTextColorByItemColor(cfg.ItemColor, append);
|
| | | data.richText.Append(append);
|
| | | }
|
| | | catch (Exception e)
|
| | | {
|
| | | data.richText.Append(cfg.ItemName);
|
| | | DebugEx.Log(e.Message);
|
| | | }
|
| | | }
|
| | | }
|
| | | else
|
| | | {
|
| | |
| | | SinglePackModel singlePack = _packModel.GetSinglePackModel(PackType.rptItem);
|
| | | if (ChatCtrl.Inst.presentChatType == ChatInfoType.Trumpet)
|
| | | {
|
| | | if (chatCenter.IsChatBanned)
|
| | | {
|
| | | return;
|
| | | }
|
| | | List<ItemModel> _list = null;
|
| | | var _count = singlePack.GetItemCountByID(chatCenter.bugleItem, out _list);
|
| | | if (_count < 1)
|
| | |
| | | }
|
| | | }
|
| | |
|
| | | public bool CheckIsComposeByType(int firstType,int secondType,int thirdType)
|
| | | {
|
| | | ItemCompoundConfig itemCompound = GetThirdTypeModellist(firstType,secondType,thirdType)[0];
|
| | | if (itemCompound.levelNeed <= PlayerDatas.Instance.baseData.LV)
|
| | | {
|
| | | return true;
|
| | | }
|
| | | else
|
| | | {
|
| | | SysNotifyMgr.Instance.ShowTip("TicketComposeUnlock", itemCompound.levelNeed, itemCompound.secondTypeName);
|
| | | return false;
|
| | | }
|
| | | }
|
| | |
|
| | | public int secondType { get; private set; }
|
| | | public int thirdType { get; private set;}
|
| | | public void SetJumpToModel(ComposeFuncType type,int secondType,int thirdType)
|
| | |
| | | public class DogzCell : ScrollerUI
|
| | | {
|
| | | [SerializeField] Image m_DogzIcon;
|
| | | [SerializeField] RectTransform m_DogzIconRect;
|
| | | [SerializeField] Image m_DogzAssist;
|
| | | [SerializeField] Text m_DogzName;
|
| | | [SerializeField] Text m_DogzGrade;
|
| | |
| | | return m_Model ?? (m_Model = ModelCenter.Instance.GetModel<DogzModel>());
|
| | | }
|
| | | }
|
| | |
|
| | | public override void Refresh(CellView cell)
|
| | | {
|
| | | var _dogzCfg = Config.Instance.Get<DogzConfig>(cell.index);
|
| | | m_DogzIcon.SetSprite(_dogzCfg.HeadIcon);
|
| | | m_DogzIcon.SetNativeSize();
|
| | | m_DogzIconRect.sizeDelta = new Vector2(m_DogzIconRect.sizeDelta.x/2,m_DogzIconRect.sizeDelta.y/2);
|
| | | var _dogzEquips = model.GetDogzEquips(_dogzCfg.ID);
|
| | | bool isActive = (_dogzEquips == null || _dogzEquips.Count < 5) ? false : true;
|
| | | m_DogzName.text = _dogzCfg.Name;
|
| | |
| | | if (isActive)
|
| | | {
|
| | | m_DogzIcon.material = MaterialUtility.GetUIDefaultGraphicMaterial();
|
| | | m_DogzName.material = MaterialUtility.GetUIDefaultGraphicMaterial();
|
| | | m_DogzGrade.material = MaterialUtility.GetUIDefaultGraphicMaterial();
|
| | | m_DogzName.color = UIHelper.s_NavyBrown;
|
| | | m_DogzGrade.color = UIHelper.s_BrightOrangeColor;
|
| | | }
|
| | | else
|
| | | {
|
| | | m_DogzIcon.material = MaterialUtility.GetDefaultSpriteGrayMaterial();
|
| | | m_DogzName.material = MaterialUtility.GetDefaultSpriteGrayMaterial();
|
| | | m_DogzGrade.material = MaterialUtility.GetDefaultSpriteGrayMaterial();
|
| | | m_DogzName.color = UIHelper.s_BrightWhiteColor;
|
| | | m_DogzGrade.color = UIHelper.s_BrightWhiteColor;
|
| | | }
|
| | | m_DogzBtn.image.color = model.presentSelectDogz == _dogzCfg.ID ? Color.blue : Color.white;
|
| | | m_DogzBtn.image.SetSprite(model.presentSelectDogz == _dogzCfg.ID ? "Title_RightWindow" : "Title_PopupWindow");
|
| | | m_DogzAssist.gameObject.SetActive(model.TryGetAssistDogzState(_dogzCfg.ID));
|
| | | m_DogzBtn.onClick.RemoveAllListeners();
|
| | | m_DogzBtn.onClick.AddListener(() =>
|
| | |
| | | public bool IsReachSelectCondi(int itemId)
|
| | | {
|
| | | ItemConfig itemConfig = Config.Instance.Get<ItemConfig>(itemId);
|
| | | if (itemConfig == null) return false;
|
| | | if (itemConfig == null || itemConfig.EquipPlace == 0) return false;
|
| | |
|
| | | if (SelectDogzItemQuality == 0 && SelectDogzItemStart == 0) return true;
|
| | |
|
| | |
| | | private void OnOpenFuncEvent(int order)
|
| | | {
|
| | | funcBtnGroup.TriggerByOrder(order);
|
| | | if(WindowCenter.Instance.CheckOpen<DogzPackWin>())
|
| | | {
|
| | | WindowCenter.Instance.CloseImmediately<DogzPackWin>();
|
| | | }
|
| | | }
|
| | |
|
| | | private void OnDogzStrengthen()
|
| | |
| | |
|
| | | ItemModel model = dogzModel.selectEquipPlacelist[cell.index];
|
| | | nameTex.text = model.chinItemModel.ItemName;
|
| | | nameTex.color = UIHelper.GetUIColor(model.chinItemModel.ItemColor);
|
| | | nameTex.color = UIHelper.GetUIColor(model.chinItemModel.ItemColor,true);
|
| | | itemBaisc.Init(model);
|
| | | int strenLv = 0;
|
| | | if (model.GetUseDataModel((int)ItemUseDataKey.Def_IudetDogzEquipPlus) != null)
|
| | |
| | | [SerializeField] Toggle _Togle_13;//十三阶
|
| | | [SerializeField] Toggle _Togle_14;//十四阶
|
| | | [SerializeField] Toggle _Togle_15;//十五阶
|
| | | [SerializeField] Toggle m_Toggle_Start;
|
| | |
|
| | | [SerializeField] Text _CountText;//获取当前的积分值
|
| | | [SerializeField] GameObject _Dropdown2;//阶数界面
|
| | |
| | | QueryFamilyAction();//家族行为信息查询
|
| | | _Dropdown.SetActive(false);
|
| | | _Dropdown2.SetActive(false);
|
| | | m_Toggle_Start.gameObject.SetActive(false);
|
| | | _ExitBtn.gameObject.SetActive(false);
|
| | | _DeleteBtn.gameObject.SetActive(false);
|
| | | _DonateBtn.gameObject.SetActive(true);
|
| | |
| | | _Togle_13.onValueChanged.AddListener(delegate (bool _bool) { Togle_13(_bool); });
|
| | | _Togle_14.onValueChanged.AddListener(delegate (bool _bool) { Togle_14(_bool); });
|
| | | _Togle_15.onValueChanged.AddListener(delegate (bool _bool) { Togle_15(_bool); });
|
| | | m_Toggle_Start.onValueChanged.AddListener(ToggleStar);
|
| | | }
|
| | |
|
| | | void CloseButton()//关闭按钮
|
| | |
| | | {
|
| | | ScrollViewFirst.SetActive(false);
|
| | | ScrollViewSecond.SetActive(false);
|
| | | m_Toggle_Start.gameObject.SetActive(true);
|
| | | _ExitBtn.gameObject.SetActive(false);
|
| | | _CleanBtn.gameObject.SetActive(false);
|
| | | _Dropdown.SetActive(true);
|
| | |
| | | _WarehouseCountBG.SetActive(true);
|
| | | _Dropdown.SetActive(false);
|
| | | _Dropdown2.SetActive(false);
|
| | | m_Toggle_Start.gameObject.SetActive(false);
|
| | | _ExitBtn.gameObject.SetActive(false);
|
| | | _DeleteBtn.gameObject.SetActive(false);
|
| | | _bool = false;
|
| | |
| | | }
|
| | |
|
| | | }
|
| | |
|
| | | private void ToggleStar(bool isBool)
|
| | | {
|
| | | SelectiveCleaningEquipment();//选择销毁
|
| | | }
|
| | |
|
| | | #endregion
|
| | |
|
| | |
| | | Item_lv = type_B;
|
| | | Item_Color = type_A;
|
| | | _EquipmentArray.Clear();
|
| | | if (m_Toggle_Start.isOn)
|
| | | {
|
| | | foreach (int key in playerFairyAuTreasureData._DicfamilyStoreItem.Keys)
|
| | | {
|
| | | var itemConfig = Config.Instance.Get<ItemConfig>(playerFairyAuTreasureData._DicfamilyStoreItem[key].ItemID);
|
| | | if ((Item_lv >= itemConfig.LV && Item_Color >= itemConfig.ItemColor && playerFairyAuTreasureData._DicfamilyStoreItem[key].Index != 0))
|
| | | if ((Item_lv >= itemConfig.LV && Item_Color >= itemConfig.ItemColor && playerFairyAuTreasureData._DicfamilyStoreItem[key].Index != 0 && itemConfig.StarLevel <= 1))
|
| | | {
|
| | | _EquipmentArray.Add(playerFairyAuTreasureData._DicfamilyStoreItem[key].Index, true);
|
| | | }
|
| | | }
|
| | | }
|
| | | else
|
| | | {
|
| | | foreach (int key in playerFairyAuTreasureData._DicfamilyStoreItem.Keys)
|
| | | {
|
| | | var itemConfig = Config.Instance.Get<ItemConfig>(playerFairyAuTreasureData._DicfamilyStoreItem[key].ItemID);
|
| | | if ((Item_lv >= itemConfig.LV && Item_Color >= itemConfig.ItemColor && playerFairyAuTreasureData._DicfamilyStoreItem[key].Index != 0 && itemConfig.StarLevel<=0))
|
| | | {
|
| | | _EquipmentArray.Add(playerFairyAuTreasureData._DicfamilyStoreItem[key].Index, true);
|
| | | }
|
| | | }
|
| | | }
|
| | | |
| | | _GridlineCtrl.m_Scorller.RefreshActiveCellViews();//刷新当前可见
|
| | | }
|
| | | int Color_T()//返回值1
|
| | |
| | | public event Action showItemRefreshEvent;
|
| | | public OverdueItem currentShowItem { get; private set; }
|
| | | DungeonModel dungeonModel { get { return ModelCenter.Instance.GetModel<DungeonModel>(); } }
|
| | |
|
| | | bool isdelay = true;
|
| | | public readonly int VipExperirnceID = 985;
|
| | | public readonly int VipCardID = 978;
|
| | | Dictionary<int, Dictionary<int, List<ItemModel>>> allGuardDict = new Dictionary<int, Dictionary<int, List<ItemModel>>>(); //守护类型,守护ID
|
| | |
| | |
|
| | | public void OnBeforePlayerDataInitialize()
|
| | | {
|
| | | isdelay = true;
|
| | | GlobalTimeEvent.Instance.secondEvent -= UpdateSecond;
|
| | | guardOverdueIndex = -1;
|
| | | itemStack.Clear();
|
| | | itemGuids.Clear();
|
| | |
| | |
|
| | | }
|
| | |
|
| | | void IPlayerLoginOk.OnPlayerLoginOk()
|
| | | public void OnPlayerLoginOk()
|
| | | {
|
| | | GlobalTimeEvent.Instance.secondEvent += UpdateSecond;
|
| | | time = 0;
|
| | | }
|
| | | float time = 0;
|
| | | private void UpdateSecond()
|
| | | {
|
| | | if(isdelay)
|
| | | {
|
| | | time += 1;
|
| | | if(time >= 5)
|
| | | {
|
| | | GetOverdueGuard();
|
| | | isdelay = false;
|
| | | time = 0;
|
| | | }
|
| | | }
|
| | | }
|
| | |
|
| | | public bool TryGetItem(string _guid, out OverdueItem _itemModel)
|
| | |
| | | case "Guardian_Timeout":
|
| | | if (list.Count > 1)
|
| | | {
|
| | | SetAllGuardIdlist();
|
| | | guardOverdueIndex = int.Parse(list[1].ToString());
|
| | | ItemModel itemModel = playerPack.GetItemModelByIndex(PackType.rptItem, guardOverdueIndex);
|
| | | if (itemModel != null)
|
| | |
| | | PlayerTaskDatas.Event_TaskToDelete += OnTaskToDelete;//任务的删除
|
| | | PlayerTaskDatas.Event_TaskInformation += TaskInformation;//任务字典信息
|
| | | PlayerTaskDatas.MainCardLevelChange += MainCardLevelChange;//卡级任务修改
|
| | | PlayerTaskDatas.CardLevelChange += CardLevelChangeEvent;//卡级任务状态改变
|
| | | model.collectingTreasureChangeEvent += OnCollectingTreasureChangeEvent;
|
| | | FuncOpen.Instance.OnFuncStateChangeEvent += OnFuncStateChangeEvent;
|
| | | TreasureNewGotWin.CloseTreasureNewGotWinEvent += CloseTreasureNewGotWinEvent;
|
| | |
| | | FuncOpen.Instance.OnFuncStateChangeEvent -= OnFuncStateChangeEvent;
|
| | | TreasureNewGotWin.CloseTreasureNewGotWinEvent -= CloseTreasureNewGotWinEvent;
|
| | | PlayerTaskDatas.MainCardLevelChange -= MainCardLevelChange;//卡级任务修改
|
| | | PlayerTaskDatas.CardLevelChange -= CardLevelChangeEvent;//卡级任务状态改变
|
| | | PlayerDatas.Instance.PlayerDataRefreshInfoEvent -= Updatefighting;//数据的刷新(h0418)
|
| | | }
|
| | |
|
| | |
| | | }
|
| | | }
|
| | |
|
| | | private void CardLevelChangeEvent(int taskID)
|
| | | {
|
| | | if (taskmodel.allMissionDict.ContainsKey(taskID) && taskmodel.allMissionDict[taskID].Type == 3)
|
| | | {
|
| | | TaskScheduling();
|
| | | TheTaskToGenerate();
|
| | | TaskJump(taskID);
|
| | | }
|
| | | }
|
| | | private void MainCardLevelChange(int _id)
|
| | | {
|
| | | TaskScheduling();
|
| | |
| | | foreach (var key in taskmodel.MainTaskDic.Keys)
|
| | | {
|
| | | var State = taskmodel.GetTaskStatus(key);
|
| | | if (State == PlayerTaskDatas.TaskStatus.CardLevel)
|
| | | if (State == PlayerTaskDatas.TaskStatus.TreasureCardLevel)
|
| | | {
|
| | | IsDefault = false;
|
| | | }
|
| | |
| | | {
|
| | | return _index0.CompareTo(_index1);
|
| | | }
|
| | | if (xPack.LV.CompareTo(yPack.LV) != 0)
|
| | | {
|
| | | return -xPack.LV.CompareTo(yPack.LV);
|
| | | }
|
| | | return 1;
|
| | | }
|
| | |
|
| | |
| | | {
|
| | | return _index0.CompareTo(_index1);
|
| | | }
|
| | | if (xPack.LV.CompareTo(yPack.LV) != 0)
|
| | | {
|
| | | return -xPack.LV.CompareTo(yPack.LV);
|
| | | }
|
| | | |
| | | return 1;
|
| | | }
|
| | |
|
| | |
| | | {
|
| | | OperationFlashSale operation = operationBase as OperationFlashSale;
|
| | | m_OpreationTime.text = StringUtility.Contact(Language.Get("ExpActivity_Text1"), operation.ToDisplayTime());
|
| | | m_RefreshGiftTime.gameObject.SetActive(operation.allDay);
|
| | | m_RefreshGiftTime.gameObject.SetActive(operation.allDay && operation.dayReset);
|
| | | OperationFlashSale.FlashSale flashSale;
|
| | | if (operation.TryGetFlashSale(TimeUtility.ServerNow, out flashSale))
|
| | | {
|
| | |
| | |
|
| | | if (!isMax)
|
| | | {
|
| | | AutoSelectPotentialBook();
|
| | | DisplayUpgradeCost();
|
| | | DisplayGetSkill();
|
| | | DisplaySuccessRatio();
|
| | |
| | | var isMax = level >= config.SkillMaxLV;
|
| | | if (!isMax)
|
| | | {
|
| | | DisplayPotentialBook(0);
|
| | | AutoSelectPotentialBook();
|
| | | DisplayPotentialBook(model.selectedPotentialBook);
|
| | | }
|
| | |
|
| | | model.onPotentialLevelUpResultEvent -= OnPotentialLevelUp;
|
| | |
| | | }
|
| | | }
|
| | |
|
| | | void AutoSelectPotentialBook()
|
| | | {
|
| | | var potential = m_Treasure.GetPotential(model.selectedPotential);
|
| | | if (potential == null)
|
| | | {
|
| | | return;
|
| | | }
|
| | | var levelUpType = model.GetSkillLevelUpType(potential.id);
|
| | | var levelupId = TreasureModel.GetSkillLevelUpId(levelUpType, potential.level + 1);
|
| | | var config = Config.Instance.Get<TreasureSkillConfig>(levelupId);
|
| | | if (config == null)
|
| | | {
|
| | | return;
|
| | | }
|
| | | var itemId = config.Meterial2ID.Length > 0 ? config.Meterial2ID[0] : 0;
|
| | | if (itemId != 0)
|
| | | {
|
| | | var own = playerPack.GetItemCountByID(PackType.rptItem, itemId);
|
| | | var need = config.MeterialNum2[0];
|
| | | var rate = config.Rate[0];
|
| | | if (rate >= 60 && own >= need)
|
| | | {
|
| | | model.selectedPotentialBook = itemId;
|
| | | }
|
| | | }
|
| | | }
|
| | |
|
| | | private void DisplayUpgradeCost()
|
| | | {
|
| | | var potential = m_Treasure.GetPotential(selectedPotential);
|
| | |
| | | {
|
| | | if (OperationTimeHepler.Instance.SatisfyAdvanceCondition(Operation.GiftPackage))
|
| | | {
|
| | | SysNotifyMgr.Instance.ShowTip("LimitGilt1");
|
| | | var seconds = 0;
|
| | | if (operationBase != null)
|
| | | {
|
| | | if (operationBase.InAdvanceTime(TimeUtility.ServerNow))
|
| | | {
|
| | | seconds = operationBase.GetSecondsBeforeStart(TimeUtility.ServerNow);
|
| | | }
|
| | | }
|
| | | SysNotifyMgr.Instance.ShowTip("LimitGilt1", TimeUtility.SecondsToDHMSCHS(seconds));
|
| | | return;
|
| | | }
|
| | | else
|
| | |
| | | private void VipInvestRedPoint()//Vip 投资红点
|
| | | {
|
| | | JumpIndex = 0;
|
| | | redPointStre1.state = RedPointState.None;
|
| | | InvestInfo = GetInvestInfoByType((int)InvestType.Vip);
|
| | | cycle = GetInvestCycle(InvestInfo.curDay);
|
| | | if (InvestInfo.investGold <= 0)
|
| | |
| | | }
|
| | | else
|
| | | {
|
| | | m_RemainingDays.text = string.Format(Language.Get("TheRemainingNumberDays_Z"), UIHelper.GetTextColorByItemColor(TextColType.Green, (7 - InvestInfo.curDay).ToString(), true));
|
| | | int Day = 0;
|
| | | if (7 - InvestInfo.curDay > 0)
|
| | | {
|
| | | Day = 7 - InvestInfo.curDay;
|
| | | }
|
| | | m_RemainingDays.text = string.Format(Language.Get("TheRemainingNumberDays_Z"), UIHelper.GetTextColorByItemColor(TextColType.Green, Day.ToString(), true));
|
| | | }
|
| | |
|
| | | if (InvestInfo.investGold <= 0)
|
| | |
| | | }
|
| | | else
|
| | | {
|
| | | m_RemainingDays.text = string.Format(Language.Get("TheRemainingNumberDays_Z"), UIHelper.GetTextColorByItemColor(TextColType.Green, (7 - InvestInfo.curDay).ToString(), true));
|
| | | int Day = 0;
|
| | | if (7 - InvestInfo.curDay > 0)
|
| | | {
|
| | | Day = 7 - InvestInfo.curDay;
|
| | | }
|
| | | m_RemainingDays.text = string.Format(Language.Get("TheRemainingNumberDays_Z"), UIHelper.GetTextColorByItemColor(TextColType.Green, Day.ToString(), true));
|
| | | }
|
| | | }
|
| | | }
|
| | |
| | | DailyQuestModel dailyQuestModel { get { return ModelCenter.Instance.GetModel<DailyQuestModel>(); } }
|
| | | TrialDungeonModel trialDungeonModel { get { return ModelCenter.Instance.GetModel<TrialDungeonModel>(); } }
|
| | | ImpactRankModel rankModel { get { return ModelCenter.Instance.GetModel<ImpactRankModel>(); } }
|
| | | ComposeWinModel composeModel { get { return ModelCenter.Instance.GetModel<ComposeWinModel>(); } }
|
| | |
|
| | | public bool IsJumpState { get; private set; }
|
| | | private int jumpPhase = 0;
|
| | |
| | | break;
|
| | | case JumpUIType.OpenServerGift:
|
| | | return;
|
| | | case JumpUIType.EquipCompose1:
|
| | | case JumpUIType.EquipCompose2:
|
| | | case JumpUIType.EquipCompose3:
|
| | | case JumpUIType.EquipCompose4:
|
| | | case JumpUIType.ComposeTicketFairy:
|
| | | case JumpUIType.ComposeTicketGod:
|
| | | case JumpUIType.ComposeTicketIce:
|
| | | int[] types = ConfigParse.GetMultipleStr<int>(_tagWinSearchModel.SelectActive);
|
| | | if (types.Length > 0)
|
| | | {
|
| | | if (!composeModel.CheckIsComposeByType(_tagWinSearchModel.TABID+1,types[0],types[1]))
|
| | | {
|
| | | return;
|
| | | }
|
| | | }
|
| | | break;
|
| | | }
|
| | |
|
| | | DebugEx.Log("WindowJumpTo" + jumpType);
|
| | |
| | | case JumpUIType.StrengthFunc3:
|
| | | case JumpUIType.StrengthFunc4:
|
| | | case JumpUIType.StrengthFunc5:
|
| | | case JumpUIType.EquipWashType2:
|
| | | case JumpUIType.StrengthFunc1Type2:
|
| | | case JumpUIType.EquipSuitType2:
|
| | | SetJumpLogic<EquipReinforceWin>(_tagWinSearchModel.TABID);
|
| | | break;
|
| | | case JumpUIType.ComposeFunc1:
|
| | |
| | | case JumpUIType.TicketCompose1:
|
| | | case JumpUIType.TicketCompose2:
|
| | | SetJumpLogic<ComposeWin>(_tagWinSearchModel.TABID);
|
| | | break;
|
| | | case JumpUIType.EquipCompose1:
|
| | | case JumpUIType.EquipCompose2:
|
| | | case JumpUIType.EquipCompose3:
|
| | | case JumpUIType.EquipCompose4:
|
| | | int[] types = ConfigParse.GetMultipleStr<int>(_tagWinSearchModel.SelectActive);
|
| | | if(types.Length > 0)
|
| | | {
|
| | | composeModel.SetJumpToModel((ComposeFuncType)_tagWinSearchModel.TABID + 1,types[0],types[1]);
|
| | | SetJumpLogic<ComposeWin>(_tagWinSearchModel.TABID);
|
| | | }
|
| | | break;
|
| | | case JumpUIType.RuneFunc1:
|
| | | case JumpUIType.RuneFunc2:
|
| | |
| | | break;
|
| | | case JumpUIType.PetFunc1:
|
| | | case JumpUIType.PetFunc2:
|
| | | case JumpUIType.MountType2:
|
| | | case JumpUIType.FairyGrabBoss:
|
| | | SetJumpLogic<PetWin>(_tagWinSearchModel.TABID);
|
| | | break;
|
| | |
| | | case JumpUIType.ComposeTicketFairy:
|
| | | case JumpUIType.ComposeTicketGod:
|
| | | case JumpUIType.ComposeTicketIce:
|
| | | var composeModel = ModelCenter.Instance.GetModel<ComposeWinModel>();
|
| | | int[] composeTypelist = ConfigParse.GetMultipleStr<int>(_tagWinSearchModel.SelectActive);
|
| | | composeModel.SetJumpToModel((ComposeFuncType)_tagWinSearchModel.TABID + 1, composeTypelist[0], composeTypelist[1]);
|
| | | SetJumpLogic<ComposeWin>(_tagWinSearchModel.TABID);
|
| | |
| | | StrengthFunc2 = 13,
|
| | | StrengthFunc3 = 14,
|
| | | StrengthFunc4 = 15,
|
| | | EquipSuitType2 = 241, //套装界面
|
| | | StrengthFunc5 = 16,
|
| | | EquipWashType2 = 239, //装备洗练界面
|
| | | ComposeFunc1 = 17,
|
| | | ComposeFunc2 = 18,
|
| | | ComposeFunc3 = 19,
|
| | |
| | | UnionFunc5 = 31,
|
| | | PetFunc1 = 32,
|
| | | PetFunc2 = 33,
|
| | | MountType2 = 240,//坐骑界面
|
| | | PetStone = 34,
|
| | | Treasure = 35,
|
| | | WorldChat = 38,
|
| | |
| | | Kylin5= 232,//麒麟之府的5层
|
| | | Kylin6 = 233,//麒麟之府的6层
|
| | | PrayforDrug = 234, //炼丹祈福(太上老君的馈赠)
|
| | | EquipCompose1 = 235, //装备合成-龙魂红二
|
| | | EquipCompose2 = 236, //装备合成-龙魂红三
|
| | | EquipCompose3 = 237, //装备合成-灵瑶红二
|
| | | EquipCompose4 = 238, //装备合成-灵瑶红三
|
| | | DhszTs = 1001,//定海神针功法提升界面
|
| | | HyqTs = 1002,//皓月枪功法提升界面
|
| | | GyzTs = 1003,//鬼牙刃功法提升界面
|
| | |
| | | BasicsScoreAHit = 181,//基础命中
|
| | | BasicsDodge = 182,//基础闪避
|
| | | OnlyFinalHurt = 183,// 额外伤害附加
|
| | | CDBPlayerRefresh_ForbidenTalk = 184,//禁言
|
| | | CDBPlayerRefresh_FuncDef = 185, // 功能层防御 185
|
| | | CDBPlayerRefresh_TreasureScore = 186, //寻宝商店积分
|
| | | CDBPlayerRefresh_Danjing = 187, // 丹精 187
|
| | |
| | | public void VerifyChat(string content, ChatInfoType channelType, Action<bool, string> callback)
|
| | | {
|
| | | int channel = 0;
|
| | | var chatCenter = ModelCenter.Instance.GetModel<ChatCenter>();
|
| | | if (!requireVerify || !GetChannel(channelType, out channel) || PlayerDatas.Instance.baseData.VIPLv >= 4
|
| | | || IsFairyFeast(channelType))
|
| | | || IsFairyFeast(channelType) || chatCenter.IsChatBanned)
|
| | | {
|
| | | if (callback != null)
|
| | | {
|
| | |
| | | public static readonly Color32 s_BrightRedColor = new Color32(255, 3, 3, 255);
|
| | | public static readonly Color32 s_BrightPurpleColor = new Color32(218, 72, 213, 255);
|
| | | public static readonly Color32 s_BrightBlueColor = new Color32(0, 107, 227, 255);
|
| | | public static readonly Color32 s_BrightOrangeColor = new Color32(255, 103, 1, 255);
|
| | | public static readonly Color32 s_BrightWhiteColor = new Color32(104, 104, 104, 255);
|
| | | public static readonly Color32 s_BrightOrangeColor = new Color32(255, 103, 1, 255); //FF6701FF
|
| | | public static readonly Color32 s_BrightWhiteColor = new Color32(104, 104, 104, 255); //686868
|
| | | public static readonly Color32 s_BrightGreenColor = new Color32(16, 157, 6, 255);
|
| | |
|
| | | public static readonly Color32 s_DarkPinkColor = new Color32(255, 124, 124, 255);
|