예제 #1
0
        public static void PrintStageInfo(StageInfo stage, MainWindowViewModel viewModel)
        {
            string history = "";
            history += String.Format("场景:{0}[{1}] ({2})", stage.name, stage.stage, stage.isBossStage ? "BOSS" : stage.progress + "%") + Environment.NewLine;

            if (stage.status != null)
            {
                history += String.Format("体力:{0} / {1}", stage.status.stamina.value, stage.status.stamina.max) + Environment.NewLine;
                history += String.Format("经验:{0} / {1}", stage.status.exp.value, stage.status.exp.max) + Environment.NewLine;
                history += String.Format(" BP:{0} / {1}", stage.status.bp.value, stage.status.bp.max) + Environment.NewLine;
                history += String.Format(" TP:{0} / {1}", stage.status.tp.value, stage.status.tp.max) + Environment.NewLine;
            }
            viewModel.History = history;
        }
예제 #2
0
        public static void UpdateStageView(StageInfo stage, MainWindowViewModel viewModel)
        {
            if (stage.status != null)
            {
                viewModel.Level = stage.status.level;

                viewModel.StaminaValue = stage.status.stamina.value;
                viewModel.StaminaMax = stage.status.stamina.max;

                viewModel.ExpValue = stage.status.exp.value;
                viewModel.ExpMin = stage.status.exp.min;
                viewModel.ExpMax = stage.status.exp.max;

                viewModel.BpValue = stage.status.bp.value;
                viewModel.BpMax = stage.status.bp.max;

                viewModel.TpValue = stage.status.tp.value;
                viewModel.TpMax = stage.status.tp.max;

                if (viewModel.IsFuryRaidEnable)
                {
                    viewModel.Fever = stage.status.furyraid != null && stage.status.furyraid.fever != null;
                }

                if (viewModel.IsLimitedRaidEnable)
                {
                    viewModel.Fever = stage.status.limitedraid != null && stage.status.limitedraid.fever != null && stage.status.limitedraid.fever.gachaTicket != null;
                }

                if (viewModel.IsBreedingEnable)
                {
                    viewModel.Fever = stage.status.breeding != null && stage.status.breeding.fever != null && stage.status.breeding.fever.breedingPoint != null;
                }
            }
        }