// Token: 0x06004379 RID: 17273 RVA: 0x00143BD4 File Offset: 0x00141DD4
        public int AttackHeroTrainningLevel(int levelId)
        {
            if (!BJLuaObjHelper.IsSkipLuaHotfix && this.TryInitHotFix("") && this.m_AttackHeroTrainningLevelInt32_hotfix != null)
            {
                return(Convert.ToInt32(this.m_AttackHeroTrainningLevelInt32_hotfix.call(new object[]
                {
                    this,
                    levelId
                })));
            }
            BJLuaObjHelper.IsSkipLuaHotfix = false;
            int num = this.CanAttackHeroTrainningLevel(levelId, false);

            if (num != 0)
            {
                if (num == -900)
                {
                    this.m_battle.FightFinished(GameFunctionStatus.Error, false, true);
                }
                return(num);
            }
            ConfigDataHeroTrainningLevelInfo configDataHeroTrainningLevelInfo = this.m_configDataLoader.GetConfigDataHeroTrainningLevelInfo(levelId);

            this.m_basicInfo.DecreaseEnergy(configDataHeroTrainningLevelInfo.EnergyFail, GameFunctionType.GameFunctionType_HeroTrainning, levelId.ToString());
            this.m_battle.SetProcessingBattleInfo(BattleType.HeroTrainning, levelId);
            return(0);
        }
Beispiel #2
0
        // Token: 0x06011809 RID: 71689 RVA: 0x00487BF8 File Offset: 0x00485DF8
        public void SetHeroTrainningLevelInfo(ConfigDataHeroTrainningLevelInfo levelInfo)
        {
            if (!BJLuaObjHelper.IsSkipLuaHotfix && this.TryInitHotFix("") && this.m_SetHeroTrainningLevelInfoConfigDataHeroTrainningLevelInfo_hotfix != null)
            {
                this.m_SetHeroTrainningLevelInfoConfigDataHeroTrainningLevelInfo_hotfix.call(new object[]
                {
                    this,
                    levelInfo
                });
                return;
            }
            BJLuaObjHelper.IsSkipLuaHotfix = false;
            this.m_heroTrainningLevelInfo  = levelInfo;
            this.m_levelText.text          = levelInfo.MonsterLevel.ToString();
            this.m_energyText.text         = levelInfo.EnergySuccess.ToString();
            this.m_levelNameText.text      = levelInfo.Name;
            this.m_iconImage.sprite        = AssetUtility.Instance.GetSprite(levelInfo.Icon);
            GameObjectUtility.DestroyChildren(this.m_rewardGroupGameObject);
            GameObject   assetInContainer = base.GetAssetInContainer <GameObject>("RewardGoods");
            List <Goods> list             = new List <Goods>();

            UIUtility.AppendRandomDropRewardGoodsToList(levelInfo.Drop_ID, list);
            if (list.Count > levelInfo.DisplayRewardCount)
            {
                list.RemoveRange(levelInfo.DisplayRewardCount, list.Count - levelInfo.DisplayRewardCount);
            }
            RewardGoodsUIController.CreateRewardGoodsList(list, this.m_rewardGroupGameObject.transform, assetInContainer, null, false, 0, true);
        }
        // Token: 0x0600437B RID: 17275 RVA: 0x00143D34 File Offset: 0x00141F34
        public virtual int CanAttackHeroTrainningLevel(int levelId, bool isTeamBattle = false)
        {
            if (!BJLuaObjHelper.IsSkipLuaHotfix && this.TryInitHotFix("") && this.m_CanAttackHeroTrainningLevelInt32Boolean_hotfix != null)
            {
                return(Convert.ToInt32(this.m_CanAttackHeroTrainningLevelInt32Boolean_hotfix.call(new object[]
                {
                    this,
                    levelId,
                    isTeamBattle
                })));
            }
            BJLuaObjHelper.IsSkipLuaHotfix = false;
            int num = this.CanOpenLevel(levelId);

            if (num != 0)
            {
                return(num);
            }
            if (this.m_battle.IsFighting())
            {
                return(-900);
            }
            ConfigDataHeroTrainningLevelInfo configDataHeroTrainningLevelInfo = this.m_configDataLoader.GetConfigDataHeroTrainningLevelInfo(levelId);

            return(this.CanAttackLevelByEnergyAndSoOn(configDataHeroTrainningLevelInfo, isTeamBattle));
        }
Beispiel #4
0
        // Token: 0x06007273 RID: 29299 RVA: 0x001FB1EC File Offset: 0x001F93EC
        public int FinishedHeroTrainningLevel(int levelId, bool isWin, List <int> battleTreasures)
        {
            if (!BJLuaObjHelper.IsSkipLuaHotfix && this.TryInitHotFix("") && this.m_FinishedHeroTrainningLevelInt32BooleanList ` 1_hotfix != null)
            {
                return(Convert.ToInt32(this.m_FinishedHeroTrainningLevelInt32BooleanList ` 1_hotfix.call(new object[]
                {
                    this,
                    levelId,
                    isWin,
                    battleTreasures
                })));
            }
            BJLuaObjHelper.IsSkipLuaHotfix = false;
            ConfigDataHeroTrainningLevelInfo configDataHeroTrainningLevelInfo = this.m_configDataLoader.GetConfigDataHeroTrainningLevelInfo(levelId);

            if (configDataHeroTrainningLevelInfo == null)
            {
                this.m_battle.FightFinished(GameFunctionStatus.Error, false, true);
                return(-4201);
            }
            if (isWin)
            {
                List <int> pveTeam = this.m_battle.GetPveTeam();
                this.SetSuccessHeroTrainningLevel(configDataHeroTrainningLevelInfo, battleTreasures, pveTeam, false);
            }
            this.m_battle.FightFinished(GameFunctionStatus.End, isWin, true);
            return(0);
        }
        // Token: 0x0600437E RID: 17278 RVA: 0x00143FDC File Offset: 0x001421DC
        private int CanAttackLevelByEnergyAndSoOn(ConfigDataHeroTrainningLevelInfo levelInfo, bool isTeamBattle)
        {
            if (!BJLuaObjHelper.IsSkipLuaHotfix && this.TryInitHotFix("") && this.m_CanAttackLevelByEnergyAndSoOnConfigDataHeroTrainningLevelInfoBoolean_hotfix != null)
            {
                return(Convert.ToInt32(this.m_CanAttackLevelByEnergyAndSoOnConfigDataHeroTrainningLevelInfoBoolean_hotfix.call(new object[]
                {
                    this,
                    levelInfo,
                    isTeamBattle
                })));
            }
            BJLuaObjHelper.IsSkipLuaHotfix = false;
            int ticketId = this.m_bag.GetTicketId(GameFunctionType.GameFunctionType_HeroTrainning);

            if (!this.m_bag.IsBagItemEnough(GoodsType.GoodsType_Item, ticketId, levelInfo.TicketCost))
            {
                return(-4207);
            }
            int consumeEnergy = levelInfo.EnergySuccess;

            if (isTeamBattle)
            {
                consumeEnergy = levelInfo.TeamEnergyCost;
            }
            if (!this.m_basicInfo.IsEnergyEnough(consumeEnergy))
            {
                return(-402);
            }
            if (this.m_bag.IsBagFullByCurrentSize())
            {
                return(-500);
            }
            return(0);
        }
Beispiel #6
0
        // Token: 0x06007274 RID: 29300 RVA: 0x001FB2DC File Offset: 0x001F94DC
        public void SetSuccessHeroTrainningLevel(ConfigDataHeroTrainningLevelInfo levelInfo, List <int> battleTreasures, List <int> heroes, bool isTeamBattle)
        {
            if (!BJLuaObjHelper.IsSkipLuaHotfix && this.TryInitHotFix("") && this.m_SetSuccessHeroTrainningLevelConfigDataHeroTrainningLevelInfoList ` 1List ` 1Boolean_hotfix != null)
            {
                this.m_SetSuccessHeroTrainningLevelConfigDataHeroTrainningLevelInfoList ` 1List ` 1Boolean_hotfix.call(new object[]
                {
                    this,
                    levelInfo,
                    battleTreasures,
                    heroes,
                    isTeamBattle
                });
                return;
            }
            BJLuaObjHelper.IsSkipLuaHotfix = false;
            int energyCost = 0;

            if (!isTeamBattle)
            {
                energyCost = levelInfo.EnergySuccess - levelInfo.EnergyFail;
            }
            base.SetCommonSuccessHeroTrainningLevel(levelInfo, battleTreasures, heroes, energyCost, isTeamBattle);
            BattleReward battleReward = (this.m_battle as BattleComponent).GetBattleReward();

            battleReward.PlayerExp = levelInfo.PlayerExp;
            battleReward.HeroExp   = this.m_hero.GetAdditiveHeroAddExp(levelInfo.HeroExp);
            battleReward.Gold      = levelInfo.Gold;
        }
Beispiel #7
0
        // Token: 0x060117CC RID: 71628 RVA: 0x00487468 File Offset: 0x00485668
        private void __callDele_EventOnStartHeroTrainningLevel(ConfigDataHeroTrainningLevelInfo obj)
        {
            Action <ConfigDataHeroTrainningLevelInfo> eventOnStartHeroTrainningLevel = this.EventOnStartHeroTrainningLevel;

            if (eventOnStartHeroTrainningLevel != null)
            {
                eventOnStartHeroTrainningLevel(obj);
            }
        }
Beispiel #8
0
        // Token: 0x06007276 RID: 29302 RVA: 0x001FB4C8 File Offset: 0x001F96C8
        public bool IsHeroTrainningLevelOpened(int levelId)
        {
            if (!BJLuaObjHelper.IsSkipLuaHotfix && this.TryInitHotFix("") && this.m_IsHeroTrainningLevelOpenedInt32_hotfix != null)
            {
                return(Convert.ToBoolean(this.m_IsHeroTrainningLevelOpenedInt32_hotfix.call(new object[]
                {
                    this,
                    levelId
                })));
            }
            BJLuaObjHelper.IsSkipLuaHotfix = false;
            ConfigDataHeroTrainningLevelInfo configDataHeroTrainningLevelInfo = this.m_configDataLoader.GetConfigDataHeroTrainningLevelInfo(levelId);

            return(configDataHeroTrainningLevelInfo != null && this.m_basicInfo.GetLevel() >= configDataHeroTrainningLevelInfo.OpenPlayerLevel);
        }
        // Token: 0x0600437C RID: 17276 RVA: 0x00143DFC File Offset: 0x00141FFC
        private int CanOpenLevel(int levelId)
        {
            if (!BJLuaObjHelper.IsSkipLuaHotfix && this.TryInitHotFix("") && this.m_CanOpenLevelInt32_hotfix != null)
            {
                return(Convert.ToInt32(this.m_CanOpenLevelInt32_hotfix.call(new object[]
                {
                    this,
                    levelId
                })));
            }
            BJLuaObjHelper.IsSkipLuaHotfix = false;
            if (!this.IsGameFunctionOpened())
            {
                return(-4208);
            }
            ConfigDataHeroTrainningLevelInfo levelInfo = this.m_configDataLoader.GetConfigDataHeroTrainningLevelInfo(levelId);

            if (levelInfo == null)
            {
                return(-4201);
            }
            if (levelInfo.m_battleInfo == null)
            {
                return(-4206);
            }
            int dayOfWeek = (int)this.m_basicInfo.GetCurrentTime().DayOfWeek;
            int key       = (dayOfWeek != 0) ? dayOfWeek : 7;
            List <ConfigDataHeroTrainningInfo> list;

            if (!this.m_configDataLoader.HeroTrainningData.HeroTrainningOfWeekDict.TryGetValue(key, out list))
            {
                return(-4200);
            }
            if (list.Find((ConfigDataHeroTrainningInfo t) => t.ID == levelInfo.m_groupInfo.ID) == null)
            {
                return(-4202);
            }
            int level = this.m_basicInfo.GetLevel();

            if (level < levelInfo.OpenPlayerLevel)
            {
                return(-413);
            }
            return(0);
        }
 // Token: 0x0600437F RID: 17279 RVA: 0x001440D8 File Offset: 0x001422D8
 protected void SetCommonSuccessHeroTrainningLevel(ConfigDataHeroTrainningLevelInfo levelInfo, List <int> battleTreasures, List <int> heroes, int energyCost, bool isBattleTeam)
 {
     if (!BJLuaObjHelper.IsSkipLuaHotfix && this.TryInitHotFix("") && this.m_SetCommonSuccessHeroTrainningLevelConfigDataHeroTrainningLevelInfoList ` 1List ` 1Int32Boolean_hotfix != null)
     {
         this.m_SetCommonSuccessHeroTrainningLevelConfigDataHeroTrainningLevelInfoList ` 1List ` 1Int32Boolean_hotfix.call(new object[]
         {
             this,
             levelInfo,
             battleTreasures,
             heroes,
             energyCost,
             isBattleTeam
         });
         return;
     }
     BJLuaObjHelper.IsSkipLuaHotfix = false;
     this.m_battle.AddBattleTreasures(battleTreasures);
     this.m_basicInfo.AddPlayerExp(levelInfo.PlayerExp);
     this.m_battle.AddFightHeroFightNumsAndExp(heroes, levelInfo.HeroExp);
     this.m_basicInfo.AddGold(levelInfo.Gold, GameFunctionType.GameFunctionType_HeroTrainning, levelInfo.ID.ToString());
     if (levelInfo.TicketCost > 0)
     {
         int         ticketId = this.m_bag.GetTicketId(GameFunctionType.GameFunctionType_HeroTrainning);
         BagItemBase bagItem  = this.m_bag.FindBagItemByType(GoodsType.GoodsType_Item, ticketId);
         this.m_bag.RemoveBagItemDirectly(bagItem, levelInfo.TicketCost, GameFunctionType.GameFunctionType_HeroTrainning, levelInfo.ID.ToString());
     }
     if (energyCost > 0)
     {
         this.m_basicInfo.DecreaseEnergy(energyCost, GameFunctionType.GameFunctionType_HeroTrainning, levelInfo.ID.ToString());
     }
     this.m_battle.WinPveBattle(levelInfo.Battle_ID);
     if (!isBattleTeam)
     {
         this.m_heroTrainningDS.AddFinishedLevel(levelInfo.ID);
     }
     if (this.IsDailyChallenge())
     {
         this.AddChallengedNums(1);
     }
     if (this.CompleteHeroTrainningMissionEvent != null)
     {
         this.CompleteHeroTrainningMissionEvent(BattleType.HeroTrainning, levelInfo.ID, heroes);
     }
 }
Beispiel #11
0
        // Token: 0x060117A3 RID: 71587 RVA: 0x00486838 File Offset: 0x00484A38
        private void AddHeroTrainningLevelListItem(ConfigDataHeroTrainningLevelInfo levelnfo, bool opened)
        {
            if (!BJLuaObjHelper.IsSkipLuaHotfix && this.TryInitHotFix("") && this.m_AddHeroTrainningLevelListItemConfigDataHeroTrainningLevelInfoBoolean_hotfix != null)
            {
                this.m_AddHeroTrainningLevelListItemConfigDataHeroTrainningLevelInfoBoolean_hotfix.call(new object[]
                {
                    this,
                    levelnfo,
                    opened
                });
                return;
            }
            BJLuaObjHelper.IsSkipLuaHotfix = false;
            GameObject go = UnityEngine.Object.Instantiate <GameObject>(this.m_heroTrainningLevelListItemPrefab, this.m_levelListScrollRect.content, false);
            HeroTrainningLevelListItemUIController heroTrainningLevelListItemUIController = GameObjectUtility.AddControllerToGameObject <HeroTrainningLevelListItemUIController>(go);

            heroTrainningLevelListItemUIController.SetHeroTrainningLevelInfo(levelnfo);
            heroTrainningLevelListItemUIController.SetLocked(!opened);
            heroTrainningLevelListItemUIController.EventOnStartButtonClick += this.HeroTrainningLevelListItem_OnStartButtonClick;
            this.m_heroTrainningLevelListItems.Add(heroTrainningLevelListItemUIController);
        }
        // Token: 0x0601185A RID: 71770 RVA: 0x00489144 File Offset: 0x00487344
        private void HeroTrainningUIController_OnStartHeroTrainningLevel(ConfigDataHeroTrainningLevelInfo levelInfo)
        {
            if (!BJLuaObjHelper.IsSkipLuaHotfix && this.TryInitHotFix("") && this.m_HeroTrainningUIController_OnStartHeroTrainningLevelConfigDataHeroTrainningLevelInfo_hotfix != null)
            {
                this.m_HeroTrainningUIController_OnStartHeroTrainningLevelConfigDataHeroTrainningLevelInfo_hotfix.call(new object[]
                {
                    this,
                    levelInfo
                });
                return;
            }
            BJLuaObjHelper.IsSkipLuaHotfix = false;
            ProjectLPlayerContext projectLPlayerContext = GameManager.Instance.PlayerContext as ProjectLPlayerContext;
            int num = projectLPlayerContext.CanAttackHeroTrainningLevel(levelInfo.ID);

            if (num == 0)
            {
                WorldUITask.StartBattleHappening(BattleType.HeroTrainning, levelInfo.ID);
            }
            else
            {
                WorldUITask.HandleAttackFailResult(num, this.m_currIntent);
            }
        }
 // Token: 0x060118AB RID: 71851 RVA: 0x00489A18 File Offset: 0x00487C18
 public void HeroTrainningUIController_OnStartHeroTrainningLevel(ConfigDataHeroTrainningLevelInfo levelInfo)
 {
     this.m_owner.HeroTrainningUIController_OnStartHeroTrainningLevel(levelInfo);
 }
 // Token: 0x060043A5 RID: 17317 RVA: 0x00144EC8 File Offset: 0x001430C8
 public void SetCommonSuccessHeroTrainningLevel(ConfigDataHeroTrainningLevelInfo levelInfo, List <int> battleTreasures, List <int> heroes, int energyCost, bool isBattleTeam)
 {
     this.m_owner.SetCommonSuccessHeroTrainningLevel(levelInfo, battleTreasures, heroes, energyCost, isBattleTeam);
 }
 // Token: 0x060043A4 RID: 17316 RVA: 0x00144EB8 File Offset: 0x001430B8
 public int CanAttackLevelByEnergyAndSoOn(ConfigDataHeroTrainningLevelInfo levelInfo, bool isTeamBattle)
 {
     return(this.m_owner.CanAttackLevelByEnergyAndSoOn(levelInfo, isTeamBattle));
 }
Beispiel #16
0
 // Token: 0x06007282 RID: 29314 RVA: 0x001FB5F4 File Offset: 0x001F97F4
 private void __callBase_SetCommonSuccessHeroTrainningLevel(ConfigDataHeroTrainningLevelInfo levelInfo, List <int> battleTreasures, List <int> heroes, int energyCost, bool isBattleTeam)
 {
     base.SetCommonSuccessHeroTrainningLevel(levelInfo, battleTreasures, heroes, energyCost, isBattleTeam);
 }
Beispiel #17
0
 // Token: 0x060117E7 RID: 71655 RVA: 0x00487950 File Offset: 0x00485B50
 public void __clearDele_EventOnStartHeroTrainningLevel(ConfigDataHeroTrainningLevelInfo obj)
 {
     this.m_owner.__clearDele_EventOnStartHeroTrainningLevel(obj);
 }
Beispiel #18
0
 // Token: 0x060117CD RID: 71629 RVA: 0x0048748C File Offset: 0x0048568C
 private void __clearDele_EventOnStartHeroTrainningLevel(ConfigDataHeroTrainningLevelInfo obj)
 {
     this.EventOnStartHeroTrainningLevel = null;
 }
Beispiel #19
0
 // Token: 0x06011800 RID: 71680 RVA: 0x00487AE0 File Offset: 0x00485CE0
 public void AddHeroTrainningLevelListItem(ConfigDataHeroTrainningLevelInfo levelnfo, bool opened)
 {
     this.m_owner.AddHeroTrainningLevelListItem(levelnfo, opened);
 }
Beispiel #20
0
        // Token: 0x0600403F RID: 16447 RVA: 0x0012AAF0 File Offset: 0x00128CF0
        public int CanPostLevelDanmaku(int gameFunctionTypeId, int locationId, List <PostDanmakuEntry> entries)
        {
            if (!BJLuaObjHelper.IsSkipLuaHotfix && this.TryInitHotFix("") && this.m_CanPostLevelDanmakuInt32Int32List ` 1_hotfix != null)
            {
                return(Convert.ToInt32(this.m_CanPostLevelDanmakuInt32Int32List ` 1_hotfix.call(new object[]
                {
                    this,
                    gameFunctionTypeId,
                    locationId,
                    entries
                })));
            }
            BJLuaObjHelper.IsSkipLuaHotfix = false;
            int battle_ID;

            switch (gameFunctionTypeId)
            {
            case 9:
            {
                ConfigDataRiftLevelInfo configDataRiftLevelInfo = this.m_configDataLoader.GetConfigDataRiftLevelInfo(locationId);
                if (configDataRiftLevelInfo == null)
                {
                    return(-2701);
                }
                battle_ID = configDataRiftLevelInfo.Battle_ID;
                break;
            }

            case 10:
            {
                ConfigDataScenarioInfo configDataScenarioInfo = this.m_configDataLoader.GetConfigDataScenarioInfo(locationId);
                if (configDataScenarioInfo == null)
                {
                    return(-2701);
                }
                battle_ID = configDataScenarioInfo.Battle_ID;
                break;
            }

            case 11:
            {
                ConfigDataEventInfo configDataEventInfo = this.m_configDataLoader.GetConfigDataEventInfo(locationId);
                if (configDataEventInfo == null)
                {
                    return(-2701);
                }
                battle_ID = configDataEventInfo.Battle_ID;
                break;
            }

            case 12:
            {
                ConfigDataAnikiLevelInfo configDataAnikiLevelInfo = this.m_configDataLoader.GetConfigDataAnikiLevelInfo(locationId);
                if (configDataAnikiLevelInfo == null)
                {
                    return(-2701);
                }
                battle_ID = configDataAnikiLevelInfo.Battle_ID;
                break;
            }

            case 13:
            {
                ConfigDataThearchyTrialLevelInfo configDataThearchyTrialLevelInfo = this.m_configDataLoader.GetConfigDataThearchyTrialLevelInfo(locationId);
                if (configDataThearchyTrialLevelInfo == null)
                {
                    return(-2701);
                }
                battle_ID = configDataThearchyTrialLevelInfo.Battle_ID;
                break;
            }

            default:
                if (gameFunctionTypeId != 41)
                {
                    if (gameFunctionTypeId != 42)
                    {
                        if (gameFunctionTypeId != 56)
                        {
                            if (gameFunctionTypeId != 57)
                            {
                                if (gameFunctionTypeId != 79)
                                {
                                    if (gameFunctionTypeId != 80)
                                    {
                                        if (gameFunctionTypeId != 28)
                                        {
                                            if (gameFunctionTypeId != 51)
                                            {
                                                return(-2700);
                                            }
                                            ConfigDataHeroTrainningLevelInfo configDataHeroTrainningLevelInfo = this.m_configDataLoader.GetConfigDataHeroTrainningLevelInfo(locationId);
                                            if (configDataHeroTrainningLevelInfo == null)
                                            {
                                                return(-2701);
                                            }
                                            battle_ID = configDataHeroTrainningLevelInfo.Battle_ID;
                                        }
                                        else
                                        {
                                            ConfigDataHeroDungeonLevelInfo configDataHeroDungeonLevelInfo = this.m_configDataLoader.GetConfigDataHeroDungeonLevelInfo(locationId);
                                            if (configDataHeroDungeonLevelInfo == null)
                                            {
                                                return(-2701);
                                            }
                                            battle_ID = configDataHeroDungeonLevelInfo.Battle_ID;
                                        }
                                    }
                                    else
                                    {
                                        ConfigDataScoreLevelInfo configDataScoreLevelInfo = this.m_configDataLoader.GetConfigDataScoreLevelInfo(locationId);
                                        if (configDataScoreLevelInfo == null)
                                        {
                                            return(-2701);
                                        }
                                        battle_ID = configDataScoreLevelInfo.Battle_ID;
                                    }
                                }
                                else
                                {
                                    ConfigDataChallengeLevelInfo configDataChallengeLevelInfo = this.m_configDataLoader.GetConfigDataChallengeLevelInfo(locationId);
                                    if (configDataChallengeLevelInfo == null)
                                    {
                                        return(-2701);
                                    }
                                    battle_ID = configDataChallengeLevelInfo.Battle_ID;
                                }
                            }
                            else
                            {
                                ConfigDataCooperateBattleLevelInfo configDataCooperateBattleLevelInfo = this.m_configDataLoader.GetConfigDataCooperateBattleLevelInfo(locationId);
                                if (configDataCooperateBattleLevelInfo == null)
                                {
                                    return(-2701);
                                }
                                battle_ID = configDataCooperateBattleLevelInfo.Battle_ID;
                            }
                        }
                        else
                        {
                            ConfigDataHeroPhantomLevelInfo configDataHeroPhantomLevelInfo = this.m_configDataLoader.GetConfigDataHeroPhantomLevelInfo(locationId);
                            if (configDataHeroPhantomLevelInfo == null)
                            {
                                return(-2701);
                            }
                            battle_ID = configDataHeroPhantomLevelInfo.Battle_ID;
                        }
                    }
                    else
                    {
                        ConfigDataMemoryCorridorLevelInfo configDataMemoryCorridorLevelInfo = this.m_configDataLoader.GetConfigDataMemoryCorridorLevelInfo(locationId);
                        if (configDataMemoryCorridorLevelInfo == null)
                        {
                            return(-2701);
                        }
                        battle_ID = configDataMemoryCorridorLevelInfo.Battle_ID;
                    }
                }
                else
                {
                    ConfigDataTreasureLevelInfo configDataTreasureLevelInfo = this.m_configDataLoader.GetConfigDataTreasureLevelInfo(locationId);
                    if (configDataTreasureLevelInfo == null)
                    {
                        return(-2701);
                    }
                    battle_ID = configDataTreasureLevelInfo.Battle_ID;
                }
                break;
            }
            ConfigDataBattleInfo configDataBattleInfo = this.m_configDataLoader.GetConfigDataBattleInfo(battle_ID);
            int num = 0;

            foreach (PostDanmakuEntry postDanmakuEntry in entries)
            {
                if (postDanmakuEntry.Turn > configDataBattleInfo.TurnMax)
                {
                    return(-2702);
                }
                if (postDanmakuEntry.Turn <= num)
                {
                    return(-2703);
                }
                num = postDanmakuEntry.Turn;
            }
            return(0);
        }