Beispiel #1
0
        private void btFightVsTemplate_Click(object sender, EventArgs e)
        {
            ChooseFightTemplateScreen chooseFightTemplateScreen = new ChooseFightTemplateScreen(_formationTemplateRepository);

            if (chooseFightTemplateScreen.ShowDialog() == DialogResult.OK)
            {
                var selectedTemplate = chooseFightTemplateScreen.SelectedTemplate;
                _fightManagement.PrepareFightAgainstTemplate(selectedTemplate.ID);
                _fightManagement.StartFight();

                FightScreen fightScreen = new FightScreen(_fightManagement.GetFightReplay());
                fightScreen.ShowDialog();
            }
        }
Beispiel #2
0
        private void btBeginQuest_Click(object sender, EventArgs e)
        {
            if (listQuests.SelectedItems.Count == 1)
            {
                var quest       = (Quest)listQuests.SelectedItems[0].Tag;
                var questResult = _questManagement.StartQuest(quest.ID);

                FightScreen fightScreen = new FightScreen(_questManagement.GetLastFightReplay());
                fightScreen.ShowDialog();


                questResultsBox.Text = $"Quest {quest.Name} {questResult} {Environment.NewLine} Rewards: {quest.WinRewards}";
                RefreshQuests();
            }
        }