Merge branch 'master' of http://192.168.0.87:10010/r/snxxz_scripts
1个文件已删除
1 文件已重命名
1个文件已添加
16个文件已修改
| New file |
| | |
| | | using UnityEngine; |
| | | using System.Collections; |
| | | |
| | | // A3 08 物品过期 #tagCMItemTimeout |
| | | |
| | | public class CA308_tagCMItemTimeout : GameNetPackBasic |
| | | { |
| | | public byte PackType; //背包类型 |
| | | public byte ItemIndex; //物品在背包中索引 |
| | | |
| | | public CA308_tagCMItemTimeout() |
| | | { |
| | | combineCmd = (ushort)0x03FE; |
| | | _cmd = (ushort)0xA308; |
| | | } |
| | | |
| | | public override void WriteToBytes() |
| | | { |
| | | WriteBytes(PackType, NetDataType.BYTE); |
| | | WriteBytes(ItemIndex, NetDataType.BYTE); |
| | | } |
| | | |
| | | } |
| File was renamed from Core/NetworkPackage/ClientPack/ClientToMapServer/CA3_Item/CA308_tagCMSuiteDecompose.cs.meta |
| | |
| | | fileFormatVersion: 2 |
| | | guid: ea64c080519e66c4ab3a1993ae07145a |
| | | timeCreated: 1520935258 |
| | | guid: fc72c801eb0807248a65b3b6680a6046 |
| | | timeCreated: 1553737813 |
| | | licenseType: Pro |
| | | MonoImporter: |
| | | serializedVersion: 2 |
| | |
| | | }
|
| | | }
|
| | |
|
| | | public bool IsFamilyQuit()//可否退出仙盟
|
| | | public bool IsFamilyQuit(int playerID = 0)//可否退出仙盟
|
| | | {
|
| | | bool isbool = true;
|
| | | int playerId = (int)PlayerDatas.Instance.baseData.PlayerID;
|
| | | if (playerID == 0)
|
| | | {
|
| | | playerID = (int)PlayerDatas.Instance.baseData.PlayerID;
|
| | | }
|
| | | foreach (var key in FamilyAuctionItemDic.Keys)//判断玩家是否有在竞价仙盟拍品(且是最高价)
|
| | | {
|
| | | if (BiddingItemInfoDic.ContainsKey(key) && BiddingItemInfoDic[key].BidderID== playerId)
|
| | | if (BiddingItemInfoDic.ContainsKey(key) && BiddingItemInfoDic[key].BidderID == playerID)
|
| | | {
|
| | | isbool = false;
|
| | | }
|
| | |
| | | {
|
| | | m_HighestPriceImage.SetActive(true);
|
| | | }
|
| | | else
|
| | | {
|
| | | m_BiddingText.text = Language.Get("PMH_06");
|
| | | }
|
| | | }
|
| | | if (familyAuctionItem.BidderPrice != 0)
|
| | | {
|
| | | m_BiddingText.text = Language.Get("PMH_06");
|
| | | }
|
| | | else
|
| | | {
|
| | |
| | | {
|
| | | m_HighestPriceImage.SetActive(true);
|
| | | }
|
| | | else
|
| | | {
|
| | | m_BiddingText.text = Language.Get("PMH_06");
|
| | | }
|
| | | |
| | | }
|
| | | if (fullServiceAuction.BidderPrice != 0)
|
| | | {
|
| | | m_BiddingText.text = Language.Get("PMH_06");
|
| | | }
|
| | | else
|
| | | {
|
| | |
| | | else
|
| | | {
|
| | | m_HighestPriceImage.SetActive(false);
|
| | | m_BiddingText.text = Language.Get("PMH_06");
|
| | | |
| | | }
|
| | | }
|
| | | if (myAuction.BidderPrice != 0)
|
| | | {
|
| | | m_BiddingText.text = Language.Get("PMH_06");
|
| | | }
|
| | | else
|
| | | {
|
| | | m_BiddingText.text = Language.Get("PMH_05");
|
| | |
| | | if (i < MaxCount)
|
| | | {
|
| | | gridCtrl.AddCell(ScrollerDataType.Header, i);
|
| | | } |
| | | }
|
| | | }
|
| | | gridCtrl.Restart();
|
| | | } |
| | |
| | | transactionStatusText.gameObject.SetActive(true);
|
| | | SuccessfulBiddingObj.SetActive(false);
|
| | | AuctionFailedObj.SetActive(false);
|
| | | if (AuctionType == 0)
|
| | | {
|
| | | transactionStatusText.text = Language.Get("PMH_11");
|
| | | }
|
| | | else if (AuctionType == 1)
|
| | | {
|
| | | transactionStatusText.text = Language.Get("PMH_12");
|
| | | }
|
| | | transactionStatusText.text = Language.Get("PMH_11");
|
| | | break;
|
| | | case 1://拍卖成交(竞拍成功)
|
| | | SuccessfulBiddingObj.SetActive(true);
|
| | |
| | | transactionStatusText.gameObject.SetActive(false);
|
| | | JadeMoney_1.text = auctionRecord.BidderPrice.ToString();
|
| | | break;
|
| | | case 5://仙盟流拍到全服
|
| | | transactionStatusText.gameObject.SetActive(true);
|
| | | SuccessfulBiddingObj.SetActive(false);
|
| | | AuctionFailedObj.SetActive(false);
|
| | | transactionStatusText.text = Language.Get("PMH_12");
|
| | | break;
|
| | | }
|
| | |
|
| | | itemCell.Init(cellModel);
|
| | |
| | | |
| | | if (force || this.candidate.trainLevel.dirty) |
| | | { |
| | | m_Description2.text = string.Format("洗练等级:{0}级", this.candidate.trainLevel.Fetch()); |
| | | m_Description2.color = UIHelper.GetUIColor(TextColType.Black, true); |
| | | var trainLevel = this.candidate.trainLevel.Fetch(); |
| | | if (!string.IsNullOrEmpty(this.candidate.equipGuid.value)) |
| | | { |
| | | m_Description2.text = string.Format("洗练等级:{0}级", trainLevel); |
| | | m_Description2.color = UIHelper.GetUIColor(TextColType.Black, true); |
| | | } |
| | | } |
| | | } |
| | | |
| | |
| | | public readonly LogicInt selectedPlace = new LogicInt(); |
| | | public readonly LogicInt equipTrainLevel = new LogicInt(); |
| | | public readonly LogicInt equipTrainMaxLevel = new LogicInt(); |
| | | public readonly LogicInt material = new LogicInt(); |
| | | public readonly LogicInt3 material = new LogicInt3(); |
| | | public readonly LogicInt inevitableMaterialCount = new LogicInt(); |
| | | public readonly LogicEnum<TrainOperateType> operateType = new LogicEnum<TrainOperateType>(TrainOperateType.None); |
| | | public readonly LogicList<EquipTrainCandidate> candidatePlaces = new LogicList<EquipTrainCandidate>(); |
| | |
| | | selectedPlace.value = 0; |
| | | equipTrainLevel.value = 0; |
| | | equipTrainMaxLevel.value = 0; |
| | | material.value = 0; |
| | | material.value = Int3.zero; |
| | | inevitableMaterialCount.value = 0; |
| | | operateType.value = TrainOperateType.None; |
| | | candidatePlaces.Clear(); |
| | |
| | | return; |
| | | } |
| | | |
| | | var need = GetMaterialNeed(equipPosition); |
| | | var itemId = GetTrainMaterial(equipPosition); |
| | | var own = packModel.GetItemCountByID(PackType.Item, itemId); |
| | | if (need > own) |
| | | var material = GetTrainMaterial(equipPosition); |
| | | if (material.z > material.y) |
| | | { |
| | | SysNotifyMgr.Instance.ShowTip("WashStone1"); |
| | | return; |
| | |
| | | |
| | | public int GetTrainLevel(Int2 equipPosition) |
| | | { |
| | | var equip = equipModel.GetEquip(equipPosition); |
| | | if (string.IsNullOrEmpty(equip)) |
| | | { |
| | | return 0; |
| | | } |
| | | |
| | | if (!equipTrains.ContainsKey(equipPosition.x)) |
| | | { |
| | | return 0; |
| | | } |
| | | |
| | | return equipTrains[equipPosition.x].GetTrainLevel(equipPosition.y); |
| | | var maxLevel = GetMaxTrainLevel(equipPosition); |
| | | return Mathf.Min(maxLevel, equipTrains[equipPosition.x].GetTrainLevel(equipPosition.y)); |
| | | } |
| | | |
| | | public int GetTotalLevel(int level) |
| | |
| | | |
| | | public int GetMaterialNeed(Int2 equipPosition) |
| | | { |
| | | var star = starModel.GetEquipStarLevel(equipPosition); |
| | | var level = GetTrainLevel(equipPosition); |
| | | var type = GetTrainType(equipPosition.y); |
| | | var data = EquipWashConfig.Get(type, star + 1); |
| | | var data = EquipWashConfig.Get(type, level); |
| | | |
| | | return data.config.costCount; |
| | | } |
| | |
| | | |
| | | public int GetMaxTrainLevel(Int2 equipPosition) |
| | | { |
| | | var equip = equipModel.GetEquip(equipPosition); |
| | | if (string.IsNullOrEmpty(equip)) |
| | | { |
| | | return 0; |
| | | } |
| | | |
| | | var star = starModel.GetEquipStarLevel(equipPosition); |
| | | var type = GetTrainType(equipPosition.y); |
| | | var config = WashLevelMaxConfig.Get(type, star); |
| | |
| | | |
| | | public Int3 GetTrainedProperties(Int2 equipPosition) |
| | | { |
| | | return equipTrains.ContainsKey(equipPosition.x) ? equipTrains[equipPosition.x].GetTrainedProperties(equipPosition.y) : Int3.zero; |
| | | var equip = equipModel.GetEquip(equipPosition); |
| | | if (string.IsNullOrEmpty(equip)) |
| | | { |
| | | return Int3.zero; |
| | | } |
| | | |
| | | if (!equipTrains.ContainsKey(equipPosition.x)) |
| | | { |
| | | return Int3.zero; |
| | | } |
| | | |
| | | var maxLevel = GetMaxTrainLevel(equipPosition); |
| | | var trainedProperties = equipTrains[equipPosition.x].GetTrainedProperties(equipPosition.y); |
| | | var type = GetTrainType(equipPosition.y); |
| | | var data = EquipWashConfig.Get(type, maxLevel); |
| | | |
| | | var property1 = 0; |
| | | var property2 = 0; |
| | | var property3 = 0; |
| | | if (data != null) |
| | | { |
| | | property1 = Mathf.Min(trainedProperties.x, data.config.attMax1); |
| | | property2 = Mathf.Min(trainedProperties.y, data.config.attMax2); |
| | | property3 = Mathf.Min(trainedProperties.z, data.config.attMax3); |
| | | } |
| | | |
| | | return new Int3(property1, property2, property3); |
| | | } |
| | | |
| | | private List<int> GetTrainablePlaces(int level) |
| | |
| | | inevitableMaterialCount.value = CalculateInevitableMaterialCount(equipPosition); |
| | | } |
| | | |
| | | private int GetTrainMaterial(Int2 equipPosition) |
| | | private Int3 GetTrainMaterial(Int2 equipPosition) |
| | | { |
| | | if (GetEquipPlaceTrainState(equipPosition) == TrainState.Allowable) |
| | | { |
| | | var star = starModel.GetEquipStarLevel(equipPosition); |
| | | var type = GetTrainType(equipPosition.y); |
| | | var data = EquipWashConfig.Get(type, star + 1); |
| | | return data.config.costItem; |
| | | var level = GetTrainLevel(equipPosition); |
| | | var data = EquipWashConfig.Get(type, level); |
| | | var count = packModel.GetItemCountByID(PackType.Item, data.config.costItem); |
| | | var need = GetMaterialNeed(equipPosition); |
| | | return new Int3(data.config.costItem, count, need); |
| | | } |
| | | else |
| | | { |
| | | return 0; |
| | | return Int3.zero; |
| | | } |
| | | } |
| | | |
| | |
| | | |
| | | if (force || model.material.dirty) |
| | | { |
| | | var equipPosition = new Int2(model.selectedLevel.value, model.selectedPlace.value); |
| | | DisplayMaterial(equipPosition, model.material.Fetch()); |
| | | DisplayMaterial(model.material.Fetch()); |
| | | } |
| | | |
| | | if (force || model.inevitableMaterialCount.dirty) |
| | |
| | | |
| | | } |
| | | |
| | | private void DisplayMaterial(Int2 equipPosition, int itemId) |
| | | private void DisplayMaterial(Int3 material) |
| | | { |
| | | var own = 0; |
| | | var need = 0; |
| | | if (itemId > 0) |
| | | { |
| | | need = model.GetMaterialNeed(equipPosition); |
| | | own = packModel.GetItemCountByID(PackType.Item, itemId); |
| | | } |
| | | |
| | | m_MaterialCell.Display(itemId, need, own); |
| | | m_MaterialCell.Display(material.x, material.y, material.z); |
| | | } |
| | | |
| | | private void DisplayInevitableMaterial(Int2 equipPosition, int need) |
| | |
| | | public ItemBehaviour m_Material; |
| | | public Text m_MaterialCount; |
| | | |
| | | public void Display(int itemId, int need, int own) |
| | | public void Display(int itemId, int own, int need) |
| | | { |
| | | if (itemId > 0) |
| | | { |
| | |
| | | m_MaterialCount.gameObject.SetActive(true); |
| | | m_Material.SetItem(itemId, 1); |
| | | var enough = own >= need; |
| | | m_MaterialCount.text = string.Format("{0}/{1}", UIHelper.AppendColor(enough ? TextColType.White : TextColType.Red, own.ToString(), true), need); |
| | | m_MaterialCount.text = string.Format("{0}/{1}", UIHelper.AppendColor(enough ? TextColType.Green : TextColType.Red, own.ToString(), true), need); |
| | | } |
| | | else |
| | | { |
| | |
| | | var enough = own >= need; |
| | | |
| | | m_InevitableMaterialCount.text = string.Format("{0}/{1}", |
| | | UIHelper.AppendColor(enough ? TextColType.White : TextColType.Red, own.ToString(), true), need); |
| | | UIHelper.AppendColor(enough ? TextColType.Green : TextColType.Red, own.ToString(), true), need); |
| | | |
| | | if (diamond > 0) |
| | | { |
| | |
| | | SysNotifyMgr.Instance.ShowTip("FairyGrabBossExitError");
|
| | | return;
|
| | | }
|
| | |
|
| | | var auctionModel = ModelCenter.Instance.GetModel<AuctionInquiryModel>();
|
| | | if (!auctionModel.IsFamilyQuit())
|
| | | {
|
| | | SysNotifyMgr.Instance.ShowTip("Paimai8");
|
| | | return;
|
| | | }
|
| | |
|
| | | PlayerFairyData.FairyData fairy = PlayerDatas.Instance.fairyData.fairy;
|
| | | if (fairy != null)
|
| | | {
|
| | |
| | | #region 发包
|
| | | public void SendKickFairy(uint playerID)
|
| | | {
|
| | | C0F09_tagCDeleteFamilyMember kickPack = new C0F09_tagCDeleteFamilyMember();
|
| | | kickPack.MemberID = playerID;
|
| | | GameNetSystem.Instance.SendInfo(kickPack);
|
| | | var auctionModel = ModelCenter.Instance.GetModel<AuctionInquiryModel>();
|
| | | if (!auctionModel.IsFamilyQuit((int)playerID))
|
| | | {
|
| | | SysNotifyMgr.Instance.ShowTip("Paimai7");
|
| | | return;
|
| | | }
|
| | |
|
| | | var pak = new C0F09_tagCDeleteFamilyMember();
|
| | | pak.MemberID = playerID;
|
| | | GameNetSystem.Instance.SendInfo(pak);
|
| | | }
|
| | |
|
| | | public void SendApplyFairy(uint id)
|
| | | {
|
| | | int limit = FuncOpenLVConfig.Get((int)FuncOpenEnum.Fairy).LimitLV;
|
| | |
| | | namespace Snxxz.UI |
| | | { |
| | | [XLua.LuaCallCSharp] |
| | | public class HeavenBattleInfo : Singleton<HeavenBattleInfo> |
| | | public class HeavenBattleInfo : Singleton<HeavenBattleInfo> |
| | | |
| | | { |
| | | public HeavenBattleInfo() |
| | |
| | | } |
| | | |
| | | #region 仙魔之争的信息 |
| | | public int Score1 { get; private set;} // 仙界阵营积分 |
| | | public int Score1 { get; private set; } // 仙界阵营积分 |
| | | |
| | | public int Score2 { get; private set; } // 魔界阵营积分 |
| | | |
| | |
| | | this.TopName = info.TopName; |
| | | |
| | | JsonData jsonData = JsonMapper.ToObject(info.StageRecord); |
| | | foreach(var key in jsonData.Keys) |
| | | foreach (var key in jsonData.Keys) |
| | | { |
| | | int index = int.Parse(key); |
| | | int result = int.Parse(jsonData[key].ToString()); |
| | | if(!battleResultDict.ContainsKey(index)) |
| | | if (!battleResultDict.ContainsKey(index)) |
| | | { |
| | | battleResultDict.Add(index,result); |
| | | battleResultDict.Add(index, result); |
| | | } |
| | | else |
| | | { |
| | |
| | | DebugEx.Log("阶段胜利:" + index + "结果:" + result); |
| | | } |
| | | |
| | | if(bettingResultAct != null) |
| | | if (bettingResultAct != null) |
| | | { |
| | | bettingResultAct(); |
| | | } |
| | |
| | | public int GetBattleResultByIndex(int index) |
| | | { |
| | | int result = 0; |
| | | battleResultDict.TryGetValue(index,out result); |
| | | battleResultDict.TryGetValue(index, out result); |
| | | return result; |
| | | } |
| | | |
| | |
| | | |
| | | #region 仙魔之争玩家信息 |
| | | public int Faction { get; private set; } // 所属阵营 |
| | | public int PlayerScore { get; private set;} // 积分 |
| | | public int PlayerScore { get; private set; } // 积分 |
| | | public int WinCnt { get; private set; } // 胜场数 |
| | | private Dictionary<int, bool> getAwardDict = new Dictionary<int, bool>(); // 胜场奖励领取记录 |
| | | private Dictionary<int,List<int>> bettingRecordDict = new Dictionary<int,List<int>>(); // 押注记录 1 阵营1 2 阵营2 |
| | | private Dictionary<int, List<int>> bettingRecordDict = new Dictionary<int, List<int>>(); // 押注记录 1 阵营1 2 阵营2 |
| | | public event Action bettingRecordAct; |
| | | public void SetHeavenBattlePlayerInfo(HAC03_tagGCXMZZSelfInfo info) |
| | | { |
| | |
| | | this.WinCnt = (int)info.WinCnt; |
| | | string awardRecord = info.WinCntAwardRecord.ToString(); |
| | | int sumIndex = ModelCenter.Instance.GetModel<HeavenBattleModel>().heavenAwardDict.Count; |
| | | for(int i = 0; i < sumIndex;i++) |
| | | for (int i = 0; i < sumIndex; i++) |
| | | { |
| | | bool isRecord = MathUtility.GetBitValue(info.WinCntAwardRecord,(ushort)i); |
| | | if(isRecord) |
| | | bool isRecord = MathUtility.GetBitValue(info.WinCntAwardRecord, (ushort)i); |
| | | if (isRecord) |
| | | { |
| | | getAwardDict.Add(i, true); |
| | | } |
| | |
| | | } |
| | | |
| | | JsonData jsonData = JsonMapper.ToObject(info.BetRecord); |
| | | foreach(var key in jsonData.Keys) |
| | | foreach (var key in jsonData.Keys) |
| | | { |
| | | int index = int.Parse(key); |
| | | if(jsonData[key].IsArray) |
| | | if (jsonData[key].IsArray) |
| | | { |
| | | int betRecord = int.Parse(jsonData[key][0].ToString()); |
| | | int betMoney = int.Parse(jsonData[key][1].ToString()); |
| | |
| | | List<int> betlist = new List<int>(); |
| | | betlist.Add(betRecord); |
| | | betlist.Add(betMoney); |
| | | bettingRecordDict.Add(index,betlist); |
| | | bettingRecordDict.Add(index, betlist); |
| | | } |
| | | else |
| | | { |
| | |
| | | bettingRecordDict[index][1] = betMoney; |
| | | } |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | | } |
| | | |
| | | if(bettingRecordAct != null) |
| | | if (bettingRecordAct != null) |
| | | { |
| | | bettingRecordAct(); |
| | | } |
| | |
| | | public bool IsGetAwardByIndex(int index) |
| | | { |
| | | bool isGet = false; |
| | | getAwardDict.TryGetValue(index,out isGet); |
| | | getAwardDict.TryGetValue(index, out isGet); |
| | | return isGet; |
| | | } |
| | | |
| | |
| | | { |
| | | int record = 0; |
| | | List<int> betlist = null; |
| | | bettingRecordDict.TryGetValue(index,out betlist); |
| | | if(betlist != null) |
| | | bettingRecordDict.TryGetValue(index, out betlist); |
| | | if (betlist != null) |
| | | { |
| | | record = betlist[0]; |
| | | } |
| | |
| | | |
| | | var equipPosition = new Int2(item.config.LV, item.config.EquipPlace); |
| | | var trainProperty = new TrainProperty(); |
| | | var trainLevel = trainModel.GetTrainLevel(equipPosition); |
| | | |
| | | var star = Mathf.Min(EquipStarModel.GetMaxStarLevel(item.config.ItemColor, item.config.LV), starModel.GetEquipStarLevel(equipPosition)); |
| | | var type = EquipTrainModel.GetTrainType(equipPosition.y); |
| | | var maxConfig = WashLevelMaxConfig.Get(type, star); |
| | | var maxLevel = maxConfig == null ? 1 : maxConfig.levelMax; |
| | | var trainLevel = Mathf.Min(maxLevel, trainModel.GetTrainLevel(equipPosition)); |
| | | trainProperty.level = trainLevel; |
| | | |
| | | var trainConfig = EquipWashConfig.Get(type, trainLevel); |
| | | var trainedProperties = trainModel.GetTrainedProperties(equipPosition); |
| | | var property1 = 0; |
| | | var property2 = 0; |
| | | var property3 = 0; |
| | | |
| | | var type = EquipTrainModel.GetTrainType(item.config.EquipPlace); |
| | | for (int i = 1; i < trainLevel - 1; i++) |
| | | { |
| | | var data = EquipWashConfig.Get(type, i); |
| | | if (data != null) |
| | | { |
| | | property1 += data.config.attMax1; |
| | | property2 += data.config.attMax2; |
| | | property3 += data.config.attMax3; |
| | | } |
| | | } |
| | | |
| | | property1 += trainedProperties.x; |
| | | property2 += trainedProperties.y; |
| | | property3 += trainedProperties.z; |
| | | |
| | | var dataLevel1 = EquipWashConfig.Get(type, 1); |
| | | trainProperty.properties = new List<Int2>(); |
| | | trainProperty.properties.Add(new Int2(dataLevel1.config.attType1, property1)); |
| | | trainProperty.properties.Add(new Int2(dataLevel1.config.attType2, property2)); |
| | | trainProperty.properties.Add(new Int2(dataLevel1.config.attType3, property3)); |
| | | trainProperty.properties.Add(new Int2(trainConfig.config.attType1, Mathf.Min(trainedProperties.x, trainConfig.config.attMax1))); |
| | | trainProperty.properties.Add(new Int2(trainConfig.config.attType2, Mathf.Min(trainedProperties.y, trainConfig.config.attMax2))); |
| | | trainProperty.properties.Add(new Int2(trainConfig.config.attType3, Mathf.Min(trainedProperties.z, trainConfig.config.attMax3))); |
| | | |
| | | return trainProperty; |
| | | } |
| | |
| | | Dictionary<string, DateTime> auctionEndTimes = new Dictionary<string, DateTime>(); |
| | | Dictionary<string, DateTime> useEndTimes = new Dictionary<string, DateTime>(); |
| | | |
| | | PackModel packModel { get { return ModelCenter.Instance.GetModel<PackModel>(); } } |
| | | |
| | | public ItemTimeUtility() |
| | | { |
| | | logicUpdate = new LogicUpdate(1f); |
| | |
| | | } |
| | | } |
| | | |
| | | private void ProcessItemUseOverdue(string guid) |
| | | { |
| | | ItemOperateUtility.Instance.UseItem(guid); |
| | | } |
| | | |
| | | private void ProcessAuctionOverdue(string guid) |
| | | { |
| | | ItemOperateUtility.Instance.UseItem(guid); |
| | | var item = packModel.GetItemByGuid(guid); |
| | | if (item == null) |
| | | { |
| | | return; |
| | | } |
| | | |
| | | var info = new CA308_tagCMItemTimeout(); |
| | | info.PackType = (byte)item.packType; |
| | | info.ItemIndex = (byte)item.gridIndex; |
| | | GameNetSystem.Instance.SendInfo(info); |
| | | } |
| | | |
| | | } |
| | |
| | | |
| | | private void OpenRealmWin() |
| | | { |
| | | WindowCenter.Instance.Close<MainInterfaceWin>(); |
| | | WindowCenter.Instance.Open<RealmWin>(); |
| | | WindowCenter.Instance.Open<RealmTransitionWin>(); |
| | | } |
| | | |
| | | } |
| | |
| | | {
|
| | | return;
|
| | | }
|
| | | if (UI3DTreasureSelectStage.Instance.UnlockShowing
|
| | | && model.IsRequireUnlockAnim(category) == treasureId)
|
| | | {
|
| | | return;
|
| | | }
|
| | | if (!m_TreasureCanvaPool.ContainsKey(category))
|
| | | {
|
| | | var prefab = UILoader.LoadTreasure("Misc", "TreasureCanva_" + category.ToString());
|
| | |
| | | RecycleLockEffect();
|
| | | RecycleCondition();
|
| | | RecycleTreasureLabel();
|
| | | RecycleTreasureCanva();
|
| | | try
|
| | | {
|
| | | var _effect = SFXPlayUtility.Instance.Play(category == TreasureCategory.Demon ? 5157 : 5132, treasureRoot);
|
| | |
| | | return 0;
|
| | | }
|
| | |
|
| | | public int GetTreasureBySkillId(int skillId)
|
| | | {
|
| | | var list = GetTreasureCategory(TreasureCategory.Human);
|
| | | for (int i = 0; i < list.Count; i++)
|
| | | {
|
| | | Treasure treasure;
|
| | | if (TryGetTreasure(list[i], out treasure)
|
| | | && treasure.skillId == skillId)
|
| | | {
|
| | | return list[i];
|
| | | }
|
| | | }
|
| | | return 0;
|
| | | }
|
| | |
|
| | | public List<int> GetFurnacesAchievements()
|
| | | {
|
| | | return eightFurnacesAchievements;
|
| | |
| | | continue;
|
| | | }
|
| | | var config = TreasureConfig.Get(id);
|
| | | if (config.PreTreasure == 0 || treasures[config.PreTreasure].state != TreasureState.Collected)
|
| | | if (config.PreTreasure != 0 && treasures[config.PreTreasure].state != TreasureState.Collected)
|
| | | {
|
| | | continue;
|
| | | }
|
| | |
| | | {
|
| | | demonDungeonChallengeNext();
|
| | | }
|
| | | }
|
| | |
|
| | | public int GetTreasureBySkillId(int skillId)
|
| | | {
|
| | | var list = GetTreasureCategory(TreasureCategory.Human);
|
| | | for (int i = 0; i < list.Count; i++)
|
| | | {
|
| | | Treasure treasure;
|
| | | if (TryGetTreasure(list[i], out treasure)
|
| | | && treasure.skillId == skillId)
|
| | | {
|
| | | return list[i];
|
| | | }
|
| | | }
|
| | | return 0;
|
| | | }
|
| | | }
|
| | |
|