Ejemplo n.º 1
0
        private void BattleInTavern(MenuCallbackArgs args)
        {
            this._sneakType = SneakType.Tavern;
            int    upgradeLevel = Settlement.CurrentSettlement.GetComponent <Town>().GetWallLevel();
            String scene        = LocationComplex.Current.GetLocationWithId("tavern").GetSceneName(upgradeLevel);
            int    num          = Campaign.Current.Models.LocationModel.GetSettlementUpgradeLevel(PlayerEncounter.LocationEncounter);

            //CampaignMission.OpenIndoorMission(scene, num, LocationComplex.Current.GetLocationWithId("prison"), null);
            this._tempTargetParty = MBObjectManager.Instance.CreateObject <MobileParty>("sms_prison");
            AddRandomTroopToParty(this._tempTargetParty);
            SelectMainPartyMember(args, () => {
                PreBattle(this._tempTargetParty);
                OpenBattleJustHero(scene, upgradeLevel);
            }, 20);
        }
Ejemplo n.º 2
0
        public void BattleInCenter(MenuCallbackArgs args)
        {
            this._sneakType = SneakType.Center;
            MobileParty targetParty = this._parties.Where(obj => obj.Name.ToString() == args.Text.ToString()).ToList().GetRandomElement();

            if (null == targetParty)
            {
                PlayerEncounter.LeaveSettlement();
                PlayerEncounter.Finish(true);
                return;
            }

            int    upgradeLevel = Settlement.CurrentSettlement.GetComponent <Town>().GetWallLevel();
            String scene        = LocationComplex.Current.GetLocationWithId("center").GetSceneName(upgradeLevel);

            PreBattle(targetParty);
            StartBattleNormal(scene, upgradeLevel);
        }
Ejemplo n.º 3
0
        private void BattleInPrison(MenuCallbackArgs args)
        {
            this._sneakType = SneakType.Prison;
            int    upgradeLevel = Settlement.CurrentSettlement.GetComponent <Town>().GetWallLevel();
            String scene        = LocationComplex.Current.GetLocationWithId("prison").GetSceneName(upgradeLevel);

            //int num = Campaign.Current.Models.LocationModel.GetSettlementUpgradeLevel(PlayerEncounter.LocationEncounter);
            scene = "sms_prison";
            //scene = "sue_test";
            this._tempTargetParty             = MBObjectManager.Instance.CreateObject <MobileParty>("sms_prison");
            this._tempTargetParty.Party.Owner = Settlement.CurrentSettlement.OwnerClan.Leader;

            AddRandomTroopToParty(this._tempTargetParty);
            this._tempTargetParty.SetCustomName(new TextObject(Settlement.CurrentSettlement.Name + "监狱警卫队"));

            SelectMainPartyMember(args, () => {
                PreBattle(this._tempTargetParty);
                OpenBattleJustHero(scene, upgradeLevel);
            }, SneakMaxNum);
        }
Ejemplo n.º 4
0
        public void BattleInLordShall(MenuCallbackArgs args)
        {
            this._sneakType = SneakType.LordShall;
            Hero target = this._lordHerosWithOutParty.Where(obj => obj.Name.ToString() == args.Text.ToString()).ToList().GetRandomElement();

            if (null == target)
            {
                PlayerEncounter.LeaveSettlement();
                PlayerEncounter.Finish(true);
                return;
            }
            int    upgradeLevel = Settlement.CurrentSettlement.GetComponent <Town>().GetWallLevel();
            String scene        = LocationComplex.Current.GetLocationWithId("lordshall").GetSceneName(upgradeLevel);

            //empire_castle_keep_a_l3_interior

            this._tempTargetParty = target.Clan.CreateNewMobileParty(target);
            AddRandomTroopToParty(this._tempTargetParty);
            SelectMainPartyMember(args, () => {
                PreBattle(this._tempTargetParty);
                OpenBattleJustHero(scene, upgradeLevel);
            }, SneakMaxNum);
        }