Merge branch 'master' of http://192.168.0.87:10010/r/snxxz_scripts
| | |
| | | public static void Init()
|
| | | {
|
| | | // 登记相应的数据体及对应的数据转逻辑类
|
| | | Register(typeof(HAA1D_tagMCActTotalRechargeInfo), typeof(DTCAA1D_tagMCActTotalRechargeInfo));
|
| | | Register(typeof(HAA1C_tagMCTotalRechargePlayerInfo), typeof(DTCAA1C_tagMCTotalRechargePlayerInfo));
|
| | | Register(typeof(HA717_tagMCChatBubbleBoxState), typeof(DTCA717_tagMCChatBubbleBoxState));
|
| | | Register(typeof(HB913_tagGCEnterTeamFBFailReason), typeof(DTCB913_tagGCEnterTeamFBFailReason));
|
| | | Register(typeof(H0311_tagDeleteSkill), typeof(DTC0311_tagDeleteSkill));
|
| | | Register(typeof(HB106_tagMCNotifyPlayerMove), typeof(DTCB106_tagMCNotifyPlayerMove));
|
| | | Register(typeof(HAA1D_tagMCActTotalRechargeInfo), typeof(DTCAA1D_tagMCActTotalRechargeInfo));
|
| | | Register(typeof(HAA1C_tagMCTotalRechargePlayerInfo), typeof(DTCAA1C_tagMCTotalRechargePlayerInfo));
|
| | | Register(typeof(HA717_tagMCChatBubbleBoxState), typeof(DTCA717_tagMCChatBubbleBoxState));
|
| | | Register(typeof(HB913_tagGCEnterTeamFBFailReason), typeof(DTCB913_tagGCEnterTeamFBFailReason));
|
| | | Register(typeof(H0311_tagDeleteSkill), typeof(DTC0311_tagDeleteSkill));
|
| | | Register(typeof(HB106_tagMCNotifyPlayerMove), typeof(DTCB106_tagMCNotifyPlayerMove));
|
| | | Register(typeof(H0132_tagCreateRoleSucess), typeof(DTC0132_tagCreateRoleSucess));
|
| | | Register(typeof(HA326_tagMCNPCIDCollectionCntInfo), typeof(DTCA326_tagMCNPCIDCollectionCntInfo));
|
| | | Register(typeof(HA904_tagGCDogzNPCRefreshTime), typeof(DTCA904_tagGCDogzNPCRefreshTime));
|
| | | Register(typeof(HA714_tagMCNPCCntList), typeof(DTCA714_tagMCNPCCntList));
|
| | | Register(typeof(HA326_tagMCNPCIDCollectionCntInfo), typeof(DTCA326_tagMCNPCIDCollectionCntInfo));
|
| | | Register(typeof(HA904_tagGCDogzNPCRefreshTime), typeof(DTCA904_tagGCDogzNPCRefreshTime));
|
| | | Register(typeof(HA714_tagMCNPCCntList), typeof(DTCA714_tagMCNPCCntList));
|
| | | Register(typeof(HAA16_tagMCSuperGiftInfo), typeof(DTCAA16_tagMCSuperGiftInfo));
|
| | | Register(typeof(HAC10_tagGCAllFamilyBossHurtInfoList), typeof(DTCAC10_tagGCAllFamilyBossHurtInfoList));
|
| | | Register(typeof(HA715_tagMCFamilyBossHurtList), typeof(DTCA715_tagMCFamilyBossHurtList));
|
| | |
| | | Register(typeof(HA3C0_tagMCDogzInfo), typeof(DTCA3C0_tagMCDogzInfo));
|
| | | Register(typeof(HA3C1_tagMCDogzHelpbattleState), typeof(DTCA3C1_tagMCDogzHelpbattleState));
|
| | | #endregion
|
| | | Register(typeof(HA324_tagMCBindJadeWheelResult),typeof(DTCA324_tagMCBindJadeWheelResult));
|
| | | Register(typeof(HA324_tagMCBindJadeWheelResult), typeof(DTCA324_tagMCBindJadeWheelResult));
|
| | |
|
| | | Register(typeof(HAA19_tagMCActWishingWellInfo), typeof(DTCAA19_tagMCActWishingWellInfo));
|
| | | Register(typeof(HAA1A_tagMCActWishingWellPlayerInfo), typeof(DTCAA1A_tagMCActWishingWellPlayerInfo));
|
| | |
| | | /// </summary>
|
| | | /// <param name="vBytes"></param>
|
| | | /// <returns></returns>
|
| | | public static GameNetPackBasic TransPack( ushort cmd, byte[] vBytes)
|
| | | public static GameNetPackBasic TransPack(ushort cmd, byte[] vBytes)
|
| | | {
|
| | | #if UNITY_EDITOR
|
| | | int length = vBytes.Length;
|
| | |
| | | GodWeaponEffectConfig config = null; |
| | | foreach (var item in configs[type].Values) |
| | | { |
| | | if (item.level < level && item.level > config.level) |
| | | if (config != null) |
| | | { |
| | | config = item; |
| | | if (item.level < level && item.level > config.level) |
| | | { |
| | | config = item; |
| | | } |
| | | } |
| | | else |
| | | { |
| | | if (item.level < level) |
| | | { |
| | | config = item; |
| | | } |
| | | } |
| | | } |
| | | |
| | |
| | | }
|
| | | else
|
| | | {
|
| | | #if UNITY_EDITOR
|
| | | PackageRegedit.TransPack(cmd, vPackBytes);
|
| | | #endif
|
| | | CSharpCallLua.OnRecieveLuaNetPackage(cmd, vPackBytes);
|
| | | }
|
| | |
|
| | |
| | | private IEnumerator Wait()
|
| | | {
|
| | | yield return WaitingForSecondConst.WaitMS1500;
|
| | | if (WindowCenter.Instance.Open<VipExperienceWin>())
|
| | | {
|
| | | yield break;
|
| | | }
|
| | | if (PlayerDatas.Instance.extersion.bossState == 1)
|
| | | {
|
| | | yield break;
|
| New file |
| | |
| | | fileFormatVersion: 2 |
| | | guid: a545fb3dcf719304fa74180c10219375 |
| | | folderAsset: yes |
| | | timeCreated: 1542357825 |
| | | licenseType: Pro |
| | | DefaultImporter: |
| | | userData: |
| | | assetBundleName: |
| | | assetBundleVariant: |
| | |
| | | {
|
| | | return DailyQuestState.CanBuyTimes;
|
| | | }
|
| | | case 19:
|
| | | return DailyQuestState.Normal;
|
| | | default:
|
| | | return DailyQuestState.Completed;
|
| | | }
|
| New file |
| | |
| | | using UnityEngine;
|
| | | using UnityEngine.UI;
|
| | |
|
| | | namespace Snxxz.UI
|
| | | {
|
| | | [XLua.Hotfix]
|
| | | public class AssistCheckInSuccessWin : Window
|
| | | {
|
| | | [SerializeField] Text infoText;
|
| | | [SerializeField] Text conditionText;
|
| | | [SerializeField] Button sureBtn;
|
| | | [SerializeField] Button closeBtn;
|
| | |
|
| | | DungeonAssistModel assistModel { get { return ModelCenter.Instance.GetModel<DungeonAssistModel>(); } }
|
| | | #region Built-in
|
| | | protected override void BindController()
|
| | | {
|
| | |
|
| | | }
|
| | | protected override void AddListeners()
|
| | | {
|
| | | sureBtn.AddListener(CloseClick);
|
| | | closeBtn.AddListener(CloseClick);
|
| | | }
|
| | | protected override void OnPreOpen()
|
| | | {
|
| | | SetDisplay();
|
| | | }
|
| | | protected override void OnAfterOpen()
|
| | | {
|
| | |
|
| | | }
|
| | |
|
| | | protected override void OnPreClose()
|
| | | {
|
| | |
|
| | | }
|
| | |
|
| | | protected override void OnAfterClose()
|
| | | {
|
| | | |
| | | }
|
| | | #endregion
|
| | |
|
| | | public void SetDisplay()
|
| | | {
|
| | | infoText.text = Language.Get("DungeonAssist123",10);
|
| | | conditionText.text = Language.Get("DungeonAssist124",assistModel.checkInTotalTime);
|
| | | }
|
| | |
|
| | | }
|
| | | }
|
| New file |
| | |
| | | fileFormatVersion: 2 |
| | | guid: 9950bf1cb2fa6324d883d04122d4837b |
| | | timeCreated: 1543024934 |
| | | licenseType: Pro |
| | | MonoImporter: |
| | | serializedVersion: 2 |
| | | defaultReferences: [] |
| | | executionOrder: 0 |
| | | icon: {instanceID: 0} |
| | | userData: |
| | | assetBundleName: |
| | | assetBundleVariant: |
| | |
| | | using UnityEngine.UI;
|
| | | using TableConfig;
|
| | | using System;
|
| | | using System.Collections.Generic;
|
| | |
|
| | | namespace Snxxz.UI
|
| | | {
|
| | |
| | |
|
| | | private void OnEnable()
|
| | | {
|
| | | goldHelpBtn.AddListener(ClickGoldHelp);
|
| | | assistModel.UpdataAssistPlayerEvent += UpdateAssistState;
|
| | | }
|
| | |
|
| | | private void OnDisable()
|
| | | {
|
| | | helpBtn.RemoveAllListeners();
|
| | | goldHelpBtn.RemoveAllListeners();
|
| | | assistModel.UpdataAssistPlayerEvent -= UpdateAssistState;
|
| | | }
|
| | |
|
| | |
| | | int realmLv = playerInfo.RealmLV;
|
| | | var realmConfig = Config.Instance.Get<RealmConfig>(playerInfo.RealmLV);
|
| | | realmIcon.SetSprite(realmConfig == null ? "NoRealm" : realmConfig.Img);
|
| | | fightPowerText.text = StringUtility.Contact("战力:",playerInfo.FightPower);
|
| | | fightPowerText.text = StringUtility.Contact(Language.Get("MainInterfacePanel_HeadPortraitTip_ZL"),playerInfo.FightPower);
|
| | | helpBtn.gameObject.SetActive(!playerInfo.IsGoldAssist);
|
| | | goldHelpBtn.gameObject.SetActive(playerInfo.IsGoldAssist);
|
| | | UpdateAssistState(playerInfo.PlayerID);
|
| | | jobNameText.text = OccupationNameConfig.GetOccupationName(playerInfo.Job,1);
|
| | | goldHelpText.text = assistModel.goldAssistPlayer.ToString();
|
| | | UpdateAssistReward();
|
| | | int nirvanaLv = playerInfo.LV - friendsModel.OpenGreatLV;
|
| | | lvIcon.gameObject.SetActive(nirvanaLv > 0);
|
| | | if (nirvanaLv > 0)
|
| | |
| | |
|
| | | if(playerInfo.IsAssist)
|
| | | {
|
| | | helpText.text = "已召唤";
|
| | | helpText.text = Language.Get("DungeonAssist122");
|
| | | helpBgImg.material = MaterialUtility.GetDefaultSpriteGrayMaterial();
|
| | | }
|
| | | else
|
| | | {
|
| | | helpBtn.AddListener(ClickHelp);
|
| | | helpText.text = "召唤";
|
| | | helpText.text = Language.Get("DungeonAssist121");
|
| | | helpBgImg.material = MaterialUtility.GetUIDefaultGraphicMaterial();
|
| | | }
|
| | | }
|
| | |
|
| | | public void UpdateAssistReward()
|
| | | {
|
| | | if (playerInfo == null) return;
|
| | |
|
| | | var related = playerInfo.relatedToPlayer;
|
| | | List<int> rewards = null;
|
| | | int sumCoins = 0;
|
| | | switch (related)
|
| | | {
|
| | | case DungeonAssistModel.RelatedToPlayer.Ally:
|
| | | rewards = assistModel.GetAssistReward(2);
|
| | | break;
|
| | | case DungeonAssistModel.RelatedToPlayer.Friend:
|
| | | case DungeonAssistModel.RelatedToPlayer.FriendAndAlly:
|
| | | rewards = assistModel.GetAssistReward(1);
|
| | | break;
|
| | | }
|
| | |
|
| | | if (rewards != null)
|
| | | {
|
| | | for (int i = 0; i < rewards.Count; i++)
|
| | | {
|
| | | sumCoins += rewards[i];
|
| | | }
|
| | | }
|
| | |
|
| | | if (sumCoins > 0)
|
| | | {
|
| | | rewardText.gameObject.SetActive(true);
|
| | | rewardText.text = Language.Get("DungeonAssist127", sumCoins);
|
| | | }
|
| | | else
|
| | | {
|
| | | rewardText.gameObject.SetActive(false);
|
| | | }
|
| | | }
|
| | |
|
| | |
| | | assistModel.SendPlayerAssist(0,playerInfo.PlayerID,playerInfo.IsNeedGold);
|
| | | }
|
| | |
|
| | | private void ClickGoldHelp()
|
| | | {
|
| | | ulong haveMoney = UIHelper.GetMoneyCnt(1) + UIHelper.GetMoneyCnt(2);
|
| | | ConfirmCancel.ShowPopConfirm(Language.Get("Mail101"),Language.Get("DungeonAssist131",assistModel.goldAssistPlayer),
|
| | | (bool isOk)=>
|
| | | {
|
| | | if(isOk)
|
| | | {
|
| | | if(haveMoney >= (ulong)assistModel.goldAssistPlayer)
|
| | | {
|
| | | assistModel.SendPlayerAssist(0, playerInfo.PlayerID, playerInfo.IsNeedGold);
|
| | | }
|
| | | else
|
| | | {
|
| | | WindowCenter.Instance.Open<RechargeTipWin>();
|
| | | }
|
| | | }
|
| | | });
|
| | | }
|
| | |
|
| | | }
|
| | | }
|
| | |
| | | public int refreshCostMoney { get; private set; }
|
| | | public int maxXianYuanCoins { get; private set; }
|
| | | public int checkInTotalTime { get; private set; }
|
| | | public int assistRobotId { get; private set; }
|
| | | public Dictionary<int, List<int>> assistCoinsDict { get; private set; }
|
| | | private void ParseFuncConfig()
|
| | | {
|
| | |
| | | }
|
| | | FuncConfigConfig HelpBattleCheckIn = Config.Instance.Get<FuncConfigConfig>("HelpBattleCheckIn");
|
| | | checkInTotalTime = int.Parse(HelpBattleCheckIn.Numerical1);
|
| | | FuncConfigConfig HelpBattleRobot = Config.Instance.Get<FuncConfigConfig>("HelpBattleRobot");
|
| | | assistRobotId = int.Parse(HelpBattleRobot.Numerical1);
|
| | | }
|
| | |
|
| | | /// <summary>
|
| | |
| | | }
|
| | | else
|
| | | {
|
| | | NPCConfig nPCConfig = Config.Instance.Get<NPCConfig>(assistModel.assistRobotId);
|
| | | Name = nPCConfig.charName;
|
| | | relatedToPlayer = RelatedToPlayer.None;
|
| | | int mapId = PlayerDatas.Instance.baseData.MapID;
|
| | | int lineId = PlayerDatas.Instance.baseData.dungeonLineId;
|
| | |
| | | goldRefreshBtn.gameObject.SetActive(!isFree);
|
| | | if(isFree)
|
| | | {
|
| | | freeRefreshText.text = StringUtility.Contact("剩余", remainNum, "次");
|
| | | freeRefreshText.text = Language.Get("DungeonAssist129",remainNum);
|
| | | }
|
| | | else
|
| | | {
|
| | | goldRefreshCostMoneyText.text = assistModel.refreshCostMoney.ToString();
|
| | | goldRefreshRemianNumText.text = StringUtility.Contact("剩余", remainNum, "次");
|
| | | goldRefreshRemianNumText.text = Language.Get("DungeonAssist129", remainNum);
|
| | | }
|
| | | }
|
| | |
|
| | |
| | | {
|
| | | if(time > 0)
|
| | | {
|
| | | oneKeyHelpText.text = StringUtility.Contact(time,"秒后自动刷新");
|
| | | oneKeyHelpText.text = Language.Get("DungeonAssist128", time);
|
| | | }
|
| | | else
|
| | | {
|
| | |
| | |
|
| | | protected override void OnPreOpen()
|
| | | {
|
| | | assistModel.UpdateCheckInResultEvent += UpdateCheckIn;
|
| | | assistModel.UpdateCheckInResultEvent += UpdateCheckInResult;
|
| | | assistModel.UpdateResultEvent += UpdateResult;
|
| | | SetDisplay();
|
| | | }
|
| | |
| | | protected override void OnPreClose()
|
| | | {
|
| | | assistModel.UpdateResultEvent -= UpdateResult;
|
| | | assistModel.UpdateCheckInResultEvent -= UpdateCheckIn;
|
| | | assistModel.UpdateCheckInResultEvent -= UpdateCheckInResult;
|
| | | }
|
| | |
|
| | | protected override void OnAfterClose()
|
| | |
| | | private void SetDisplay()
|
| | | {
|
| | | CreateResultCell();
|
| | | UpdateRegisterBtn();
|
| | | }
|
| | |
|
| | | private void CreateResultCell()
|
| | |
| | | CreateResultCell();
|
| | | }
|
| | |
|
| | | private void UpdateCheckIn()
|
| | | private void UpdateRegisterBtn()
|
| | | {
|
| | | registerBtn.RemoveAllListeners();
|
| | | if(assistModel.IsCheckInOk)
|
| | | if (assistModel.IsCheckInOk)
|
| | | {
|
| | |
|
| | | registerBgImg.material = MaterialUtility.GetDefaultSpriteGrayMaterial();
|
| | | }
|
| | | else
|
| | | {
|
| | | registerBgImg.material = MaterialUtility.GetUIDefaultGraphicMaterial();
|
| | | registerBtn.AddListener(ClickAssistRegister);
|
| | | }
|
| | | }
|
| | |
|
| | | private void UpdateCheckInResult()
|
| | | {
|
| | | UpdateRegisterBtn();
|
| | | if(assistModel.IsCheckInOk)
|
| | | {
|
| | | WindowCenter.Instance.Open<AssistCheckInSuccessWin>();
|
| | | }
|
| | | }
|
| | |
|
| | |
| | | {
|
| | | assistModel.SendAssistCheckIn();
|
| | | }
|
| | | else
|
| | | {
|
| | |
|
| | | }
|
| | | |
| | | }
|
| | |
|
| | | private void ClickStore()
|
| | |
| | | DateTime dungeonEndTime;
|
| | |
|
| | | private bool exitDungeonStage = false;
|
| | | public enum CopyMapId
|
| | | {
|
| | | IceCrystalVein=31140,
|
| | | }
|
| | | private DungeonModel model
|
| | | {
|
| | | get
|
| | |
| | | protected override void OnPreOpen()
|
| | | {
|
| | | model.dungeonCoolDownEvent += DungeonCoolDownEvent;
|
| | | DebugEx.LogError(PlayerDatas.Instance.baseData.MapID);
|
| | | SetTween(gradePosTween, gradeScaleTween, 0);
|
| | | SetTween(expPosTween, expScaleTween, 0);
|
| | |
|
| | |
| | | int rate = 0;
|
| | | if (model.GetRewardRateWithGrade(_mapid, model.mission.grade, out rate))
|
| | | {
|
| | | if (PlayerDatas.Instance.baseData.MapID == (int)CopyMapId.IceCrystalVein)
|
| | | if (PlayerDatas.Instance.baseData.MapID ==IceCrystalVeinModel.ICECRYSTALVEIN_MAPID)
|
| | | {
|
| | | expGrade.SetSprite(GetStarNum(model.mission.grade));
|
| | | }
|
| | |
| | | }
|
| | | else
|
| | | {
|
| | | if (PlayerDatas.Instance.baseData.MapID == (int)CopyMapId.IceCrystalVein)
|
| | | if (PlayerDatas.Instance.baseData.MapID == IceCrystalVeinModel.ICECRYSTALVEIN_MAPID)
|
| | | {
|
| | | grade.SetSprite(GetStarNum(model.mission.grade));
|
| | | }
|
| | |
| | | else if (index == 1)
|
| | | {
|
| | | expContainer.SetActive(false);
|
| | | if (PlayerDatas.Instance.baseData.MapID == (int)CopyMapId.IceCrystalVein)
|
| | | if (PlayerDatas.Instance.baseData.MapID == IceCrystalVeinModel.ICECRYSTALVEIN_MAPID)
|
| | | {
|
| | | grade.SetSprite(GetStarNum(model.mission.grade));
|
| | | }
|
| | |
| | | endTime = model.GetCoolDownEndTime(type);
|
| | | break;
|
| | | case DungeonCoolDownType.LeaveMap:
|
| | | if (PlayerDatas.Instance.baseData.MapID == (int)CopyMapId.IceCrystalVein)
|
| | | if (PlayerDatas.Instance.baseData.MapID == IceCrystalVeinModel.ICECRYSTALVEIN_MAPID)
|
| | | {
|
| | | surplusTime.text = Language.Get("IceCrystal_3", GetStarNumStr(model.mission.grade));
|
| | | }
|
| | |
| | | expContainer.SetActive(false);
|
| | | gradeContainer.SetActive(false);
|
| | | }
|
| | | if (PlayerDatas.Instance.baseData.MapID == (int)CopyMapId.IceCrystalVein)
|
| | | if (PlayerDatas.Instance.baseData.MapID == IceCrystalVeinModel.ICECRYSTALVEIN_MAPID)
|
| | | {
|
| | | grade.SetSprite(GetStarNum(model.mission.grade));
|
| | | }
|
| | |
| | | }
|
| | | }
|
| | | else timeZeroShow = false;
|
| | | if (PlayerDatas.Instance.baseData.MapID == (int)CopyMapId.IceCrystalVein)
|
| | | if (PlayerDatas.Instance.baseData.MapID == IceCrystalVeinModel.ICECRYSTALVEIN_MAPID)
|
| | | {
|
| | | surplusTime.text = Language.Get("DungeonGrade_3", TimeUtility.SecondsToHMSCHSRetain((int)surplus.TotalSeconds, false, false), GetStarNumStr(model.mission.grade - 1));
|
| | | }
|
| | |
| | | public event Action UpdateIceLodeInf;
|
| | | DungeonModel m_Model;
|
| | | DungeonModel model { get { return m_Model ?? (m_Model = ModelCenter.Instance.GetModel<DungeonModel>()); } }
|
| | | public const int ICECRYSTALVEIN_MAPID = 31140;
|
| | | public override void Init()
|
| | | {
|
| | | var IceLodeCfg = Config.Instance.Get<FuncConfigConfig>("IceLodeCfg");
|
| | |
| | | [SerializeField] Transform m_GridBottom;//底层组 |
| | | [SerializeField] Text m_TextNumber;//扫荡战力 |
| | | [SerializeField] Text m_Text_Fight;//我的战力 |
| | | [SerializeField] Text m_TextLv;//挑战等级 |
| | | ItemTipsModel _itemTipsModel;
|
| | | ItemTipsModel itemTipsModel { get { return _itemTipsModel ?? (_itemTipsModel = ModelCenter.Instance.GetModel<ItemTipsModel>()); } }
|
| | | IceCrystalVeinModel m_IceCrystalVeinModel; |
| | |
| | | for (int i = 0; i < IceCrystalVeinReward.Length; i++)
|
| | | {
|
| | | IceCrystalVeinMiddle.Add(IceCrystalVeinReward[i]);
|
| | | } |
| | | |
| | | }
|
| | | var Openconfig = Config.Instance.Get<FuncOpenLVConfig>(83);
|
| | | m_TextLv.text = Language.Get("IceCrystal_4", Openconfig.LimitLV); |
| | | } |
| | | |
| | | protected override void AddListeners() |
| | |
| | | var dungeonConfig = Config.Instance.Get<DungeonConfig>(dungeonId);
|
| | | if (dungeonConfig == null)
|
| | | {
|
| | | return;
|
| | | }
|
| | | if (PlayerDatas.Instance.baseData.MapID == IceCrystalVeinModel.ICECRYSTALVEIN_MAPID)//副本中不允许扫荡
|
| | | {
|
| | | SysNotifyMgr.Instance.ShowTip("IceCrystal_Sweep");
|
| | | return;
|
| | | }
|
| | | if (dungeonConfig.SweepLVLimit > PlayerDatas.Instance.baseData.LV)
|
| | |
| | | m_TextNumber.text = PlayerLV.IceLodeFightPower.ToString();
|
| | | if (PlayerDatas.Instance.baseData.FightPoint >= PlayerLV.IceLodeFightPower)
|
| | | {
|
| | | m_Text_Fight.color = new Color32(27,103,22,255);
|
| | | m_Text_Fight.color = new Color32(16,157,6,255);
|
| | | }
|
| | | else
|
| | | {
|
| | |
| | |
|
| | | playerModel.Show(instance, job, weaponId, wingId, secondaryId, m_PlayerShowPoint);
|
| | | playerModel.UnloadClothedEffect();
|
| | | playerModel.TakeOffGodWeaponEffect();
|
| | | playerModel.StandUp();
|
| | |
|
| | | m_PlayerShowPoint.localEulerAngles = Vector3.zero;
|
| | |
| | | using UnityEngine;
|
| | | using TableConfig;
|
| | | using System.Collections.Generic;
|
| | | using LitJson;
|
| | |
|
| | | namespace Snxxz.UI
|
| | | {
|
| | |
| | |
|
| | | Transform showPoint;
|
| | | List<SFXController> closthesSFXList = new List<SFXController>();
|
| | | List<SFXController> godWeaponSFXList = new List<SFXController>();
|
| | |
|
| | | public GameObject Show(UI3DPlayerExhibitionData data, Transform showPoint)
|
| | | {
|
| | |
| | | secondaryId = 0;
|
| | |
|
| | | UnloadClothedEffect();
|
| | | TakeOffGodWeaponEffect();
|
| | | }
|
| | |
|
| | | public void StandUp()
|
| | |
| | |
|
| | | private void PutOnGodWeaponEffect(Dictionary<int, int> godWeapons)
|
| | | {
|
| | | TakeOffGodWeaponEffect();
|
| | | if (godWeapons == null)
|
| | | {
|
| | | return;
|
| | | }
|
| | |
|
| | | foreach (var key in godWeapons.Keys)
|
| | | {
|
| | | Transform bone = null;
|
| | | switch (key)
|
| | | {
|
| | | case 1:
|
| | | if (clothesModel != null)
|
| | | {
|
| | | bone = clothesModel.transform.GetChildTransformDeeply("Bip001 Spine");
|
| | | }
|
| | | break;
|
| | | case 2:
|
| | | if (weaponModel != null)
|
| | | {
|
| | | bone = weaponModel.transform;
|
| | | }
|
| | | break;
|
| | | case 3:
|
| | | if (secondaryModel != null)
|
| | | {
|
| | | bone = secondaryModel.transform;
|
| | | }
|
| | | break;
|
| | | case 4:
|
| | | if (clothesModel != null)
|
| | | {
|
| | | bone = clothesModel.transform.GetChildTransformDeeply("Bip001 Neck");
|
| | | }
|
| | | break;
|
| | | default:
|
| | | break;
|
| | | }
|
| | |
|
| | | if (bone != null)
|
| | | {
|
| | | var config = GodWeaponEffectConfig.Get(key, godWeapons[key]);
|
| | | if (config != null)
|
| | | {
|
| | | var effectJson = JsonMapper.ToObject(config.effect);
|
| | | var effectId = int.Parse(effectJson[this.job.ToString()].ToString());
|
| | | var effect = SFXPlayUtility.Instance.PlayBattleEffect(effectId, bone);
|
| | | godWeaponSFXList.Add(effect);
|
| | | }
|
| | | }
|
| | | }
|
| | |
|
| | | }
|
| | |
|
| | | public void TakeOffGodWeaponEffect()
|
| | | {
|
| | | foreach (var effect in godWeaponSFXList)
|
| | | {
|
| | | SFXPlayUtility.Instance.Release(effect);
|
| | | }
|
| | |
|
| | | godWeaponSFXList.Clear();
|
| | | }
|
| | |
|
| | | private PlayerSuitModel SuitModel { get { return ModelCenter.Instance.GetModel<PlayerSuitModel>(); } }
|
| | | private PlayerPackModel PlayerBackModel { get { return ModelCenter.Instance.GetModel<PlayerPackModel>(); } }
|
| | |
|