From b077974d88d3d960094eee62b1a793fa49655b81 Mon Sep 17 00:00:00 2001 From: Aaron Date: Wed, 20 Jul 2022 17:47:38 +0200 Subject: [PATCH] Added solo and group dungeon stats & remove static dungeons --- .../Languages/de-DE.xml | 2 + .../Languages/en-US.xml | 2 + .../Models/DashboardBindings.cs | 9 +- .../Models/LootedChests.cs | 238 ++++++++++++++---- .../Network/Manager/TreasureController.cs | 45 ++-- .../Styles/DashboardStyles.xaml | 116 ++++++--- .../UserControls/DashboardControl.xaml | 2 +- 7 files changed, 313 insertions(+), 101 deletions(-) diff --git a/src/StatisticsAnalysisTool/Languages/de-DE.xml b/src/StatisticsAnalysisTool/Languages/de-DE.xml index 1d3d7b702..ab6e76fd6 100644 --- a/src/StatisticsAnalysisTool/Languages/de-DE.xml +++ b/src/StatisticsAnalysisTool/Languages/de-DE.xml @@ -624,4 +624,6 @@ Schnappschuss Ausgewählten Schnappschuss löschen Machen einen Schnappschuss der Schadensanzeige und sehen ihn dir im Schnappschuss-Tab an + Zufällige Solo Dungeons + Zufällige Gruppen Dungeons \ No newline at end of file diff --git a/src/StatisticsAnalysisTool/Languages/en-US.xml b/src/StatisticsAnalysisTool/Languages/en-US.xml index 255a195a3..af537804b 100644 --- a/src/StatisticsAnalysisTool/Languages/en-US.xml +++ b/src/StatisticsAnalysisTool/Languages/en-US.xml @@ -624,4 +624,6 @@ Snapshot Delete selected snapshot Take a snapshot of damage meter and view it in the snapshot tab + Random solo dungeons + Random group dungeons \ No newline at end of file diff --git a/src/StatisticsAnalysisTool/Models/DashboardBindings.cs b/src/StatisticsAnalysisTool/Models/DashboardBindings.cs index 6272ae853..3036b267f 100644 --- a/src/StatisticsAnalysisTool/Models/DashboardBindings.cs +++ b/src/StatisticsAnalysisTool/Models/DashboardBindings.cs @@ -1,11 +1,10 @@ -using StatisticsAnalysisTool.Properties; +using StatisticsAnalysisTool.Common; +using StatisticsAnalysisTool.Properties; using System; using System.Collections.Generic; using System.ComponentModel; using System.Linq; using System.Runtime.CompilerServices; -using StatisticsAnalysisTool.Common; -using StatisticsAnalysisTool.Models.TranslationModel; namespace StatisticsAnalysisTool.Models { @@ -40,7 +39,7 @@ public class DashboardBindings : INotifyPropertyChanged private int _soloKillsToday; private int _soloKillsThisWeek; private int _soloKillsThisMonth; - private LootedChests _lootedChests = new (); + private LootedChests _lootedChests = new(); #region Fame / Respec / Silver / Might / Faction @@ -398,7 +397,7 @@ public LootedChests LootedChests } #endregion - + public static string TranslationTitle => $"{LanguageController.Translation("DASHBOARD")}"; public static string TranslationFame => LanguageController.Translation("FAME"); public static string TranslationSilver => LanguageController.Translation("SILVER"); diff --git a/src/StatisticsAnalysisTool/Models/LootedChests.cs b/src/StatisticsAnalysisTool/Models/LootedChests.cs index dc73bbb9e..4fbccd104 100644 --- a/src/StatisticsAnalysisTool/Models/LootedChests.cs +++ b/src/StatisticsAnalysisTool/Models/LootedChests.cs @@ -15,14 +15,14 @@ public class LootedChests : INotifyPropertyChanged private int _outlandsEpicMonth; private int _outlandsLegendaryWeek; private int _outlandsLegendaryMonth; - private int _staticCommonWeek; - private int _staticCommonMonth; - private int _staticUncommonWeek; - private int _staticUncommonMonth; - private int _staticEpicWeek; - private int _staticEpicMonth; - private int _staticLegendaryWeek; - private int _staticLegendaryMonth; + private int _randomGroupDungeonCommonWeek; + private int _randomGroupDungeonCommonMonth; + private int _randomGroupDungeonUncommonWeek; + private int _randomGroupDungeonUncommonMonth; + private int _randomGroupDungeonEpicWeek; + private int _randomGroupDungeonEpicMonth; + private int _randomGroupDungeonLegendaryWeek; + private int _randomGroupDungeonLegendaryMonth; private int _avalonianRoadCommonWeek; private int _avalonianRoadCommonMonth; private int _avalonianRoadUncommonWeek; @@ -43,10 +43,10 @@ public class LootedChests : INotifyPropertyChanged private int _outlandsUncommonYear; private int _outlandsEpicYear; private int _outlandsLegendaryYear; - private int _staticCommonYear; - private int _staticUncommonYear; - private int _staticEpicYear; - private int _staticLegendaryYear; + private int _randomGroupDungeonCommonYear; + private int _randomGroupDungeonUncommonYear; + private int _randomGroupDungeonEpicYear; + private int _randomGroupDungeonLegendaryYear; private int _avalonianRoadCommonYear; private int _avalonianRoadUncommonYear; private int _avalonianRoadEpicYear; @@ -55,7 +55,19 @@ public class LootedChests : INotifyPropertyChanged private int _hellGatesUncommonYear; private int _hellGatesEpicYear; private int _hellGatesLegendaryYear; - + private int _randomSoloDungeonCommonWeek; + private int _randomSoloDungeonCommonMonth; + private int _randomSoloDungeonCommonYear; + private int _randomSoloDungeonUncommonWeek; + private int _randomSoloDungeonUncommonMonth; + private int _randomSoloDungeonUncommonYear; + private int _randomSoloDungeonEpicWeek; + private int _randomSoloDungeonEpicMonth; + private int _randomSoloDungeonEpicYear; + private int _randomSoloDungeonLegendaryWeek; + private int _randomSoloDungeonLegendaryMonth; + private int _randomSoloDungeonLegendaryYear; + #region OpenWorld bindings public int OpenWorldCommonWeek @@ -180,128 +192,252 @@ public int OpenWorldLegendaryYear #endregion - #region Static bindings + #region Random group dungeon bindings + + public int RandomGroupDungeonCommonWeek + { + get => _randomGroupDungeonCommonWeek; + set + { + _randomGroupDungeonCommonWeek = value; + OnPropertyChanged(); + } + } - public int StaticCommonWeek + public int RandomGroupDungeonCommonMonth { - get => _staticCommonWeek; + get => _randomGroupDungeonCommonMonth; set { - _staticCommonWeek = value; + _randomGroupDungeonCommonMonth = value; OnPropertyChanged(); } } - public int StaticCommonMonth + public int RandomGroupDungeonCommonYear { - get => _staticCommonMonth; + get => _randomGroupDungeonCommonYear; set { - _staticCommonMonth = value; + _randomGroupDungeonCommonYear = value; OnPropertyChanged(); } } - public int StaticCommonYear + public int RandomGroupDungeonUncommonWeek { - get => _staticCommonYear; + get => _randomGroupDungeonUncommonWeek; set { - _staticCommonYear = value; + _randomGroupDungeonUncommonWeek = value; OnPropertyChanged(); } } - public int StaticUncommonWeek + public int RandomGroupDungeonUncommonMonth { - get => _staticUncommonWeek; + get => _randomGroupDungeonUncommonMonth; set { - _staticUncommonWeek = value; + _randomGroupDungeonUncommonMonth = value; OnPropertyChanged(); } } - public int StaticUncommonMonth + public int RandomGroupDungeonUncommonYear { - get => _staticUncommonMonth; + get => _randomGroupDungeonUncommonYear; set { - _staticUncommonMonth = value; + _randomGroupDungeonUncommonYear = value; OnPropertyChanged(); } } - public int StaticUncommonYear + public int RandomGroupDungeonEpicWeek { - get => _staticUncommonYear; + get => _randomGroupDungeonEpicWeek; set { - _staticUncommonYear = value; + _randomGroupDungeonEpicWeek = value; OnPropertyChanged(); } } - public int StaticEpicWeek + public int RandomGroupDungeonEpicMonth { - get => _staticEpicWeek; + get => _randomGroupDungeonEpicMonth; set { - _staticEpicWeek = value; + _randomGroupDungeonEpicMonth = value; OnPropertyChanged(); } } - public int StaticEpicMonth + public int RandomGroupDungeonEpicYear { - get => _staticEpicMonth; + get => _randomGroupDungeonEpicYear; set { - _staticEpicMonth = value; + _randomGroupDungeonEpicYear = value; OnPropertyChanged(); } } - public int StaticEpicYear + public int RandomGroupDungeonLegendaryWeek { - get => _staticEpicYear; + get => _randomGroupDungeonLegendaryWeek; set { - _staticEpicYear = value; + _randomGroupDungeonLegendaryWeek = value; OnPropertyChanged(); } } - public int StaticLegendaryWeek + public int RandomGroupDungeonLegendaryMonth { - get => _staticLegendaryWeek; + get => _randomGroupDungeonLegendaryMonth; set { - _staticLegendaryWeek = value; + _randomGroupDungeonLegendaryMonth = value; OnPropertyChanged(); } } - public int StaticLegendaryMonth + public int RandomGroupDungeonLegendaryYear { - get => _staticLegendaryMonth; + get => _randomGroupDungeonLegendaryYear; set { - _staticLegendaryMonth = value; + _randomGroupDungeonLegendaryYear = value; OnPropertyChanged(); } } - public int StaticLegendaryYear + #endregion + + #region Random solo dungeon bindings + + public int RandomSoloDungeonCommonWeek { - get => _staticLegendaryYear; + get => _randomSoloDungeonCommonWeek; set { - _staticLegendaryYear = value; + _randomSoloDungeonCommonWeek = value; OnPropertyChanged(); } } + public int RandomSoloDungeonCommonMonth + { + get => _randomSoloDungeonCommonMonth; + set + { + _randomSoloDungeonCommonMonth = value; + OnPropertyChanged(); + } + } + + public int RandomSoloDungeonCommonYear + { + get => _randomSoloDungeonCommonYear; + set + { + _randomSoloDungeonCommonYear = value; + OnPropertyChanged(); + } + } + + public int RandomSoloDungeonUncommonWeek + { + get => _randomSoloDungeonUncommonWeek; + set + { + _randomSoloDungeonUncommonWeek = value; + OnPropertyChanged(); + } + } + + public int RandomSoloDungeonUncommonMonth + { + get => _randomSoloDungeonUncommonMonth; + set + { + _randomSoloDungeonUncommonMonth = value; + OnPropertyChanged(); + } + } + + public int RandomSoloDungeonUncommonYear + { + get => _randomSoloDungeonUncommonYear; + set + { + _randomSoloDungeonUncommonYear = value; + OnPropertyChanged(); + } + } + + public int RandomSoloDungeonEpicWeek + { + get => _randomSoloDungeonEpicWeek; + set + { + _randomSoloDungeonEpicWeek = value; + OnPropertyChanged(); + } + } + + public int RandomSoloDungeonEpicMonth + { + get => _randomSoloDungeonEpicMonth; + set + { + _randomSoloDungeonEpicMonth = value; + OnPropertyChanged(); + } + } + + public int RandomSoloDungeonEpicYear + { + get => _randomSoloDungeonEpicYear; + set + { + _randomSoloDungeonEpicYear = value; + OnPropertyChanged(); + } + } + + public int RandomSoloDungeonLegendaryWeek + { + get => _randomSoloDungeonLegendaryWeek; + set + { + _randomSoloDungeonLegendaryWeek = value; + OnPropertyChanged(); + } + } + + public int RandomSoloDungeonLegendaryMonth + { + get => _randomSoloDungeonLegendaryMonth; + set + { + _randomSoloDungeonLegendaryMonth = value; + OnPropertyChanged(); + } + } + + public int RandomSoloDungeonLegendaryYear + { + get => _randomSoloDungeonLegendaryYear; + set + { + _randomSoloDungeonLegendaryYear = value; + OnPropertyChanged(); + } + } + #endregion #region Avalonian Road bindings @@ -556,6 +692,8 @@ public int HellGateLegendaryYear public static string TranslationOpenWorld => LanguageController.Translation("OPEN_WORLD"); public static string TranslationStaticDungeons => LanguageController.Translation("STATIC_DUNGEONS"); public static string TranslationAvalonianRoads => LanguageController.Translation("AVALONIAN_ROADS"); + public static string TranslationRandomSoloDungeons => LanguageController.Translation("RANDOM_SOLO_DUNGEONS"); + public static string TranslationRandomGroupDungeons => LanguageController.Translation("RANDOM_GROUP_DUNGEONS"); public static string TranslationHellGates => LanguageController.Translation("HELLGATES"); public static string TranslationLast7Days => LanguageController.Translation("LAST_7_DAYS"); public static string TranslationLast30Days => LanguageController.Translation("LAST_30_DAYS"); diff --git a/src/StatisticsAnalysisTool/Network/Manager/TreasureController.cs b/src/StatisticsAnalysisTool/Network/Manager/TreasureController.cs index 3c35206f7..94e4343ea 100644 --- a/src/StatisticsAnalysisTool/Network/Manager/TreasureController.cs +++ b/src/StatisticsAnalysisTool/Network/Manager/TreasureController.cs @@ -120,20 +120,37 @@ private void UpdateLootedChestsDashboardUi(object sender, NotifyCollectionChange #endregion - #region Static dungeons - - _mainWindowViewModel.DashboardBindings.LootedChests.StaticCommonWeek = GetStats(TreasureRarity.Standard, TreasureType.StaticDungeon, -7); - _mainWindowViewModel.DashboardBindings.LootedChests.StaticCommonMonth = GetStats(TreasureRarity.Standard, TreasureType.StaticDungeon, -30); - _mainWindowViewModel.DashboardBindings.LootedChests.StaticCommonYear = GetStats(TreasureRarity.Standard, TreasureType.StaticDungeon, -365); - _mainWindowViewModel.DashboardBindings.LootedChests.StaticUncommonWeek = GetStats(TreasureRarity.Uncommon, TreasureType.StaticDungeon, -7); - _mainWindowViewModel.DashboardBindings.LootedChests.StaticUncommonMonth = GetStats(TreasureRarity.Uncommon, TreasureType.StaticDungeon, -30); - _mainWindowViewModel.DashboardBindings.LootedChests.StaticUncommonYear = GetStats(TreasureRarity.Uncommon, TreasureType.StaticDungeon, -365); - _mainWindowViewModel.DashboardBindings.LootedChests.StaticEpicWeek = GetStats(TreasureRarity.Rare, TreasureType.StaticDungeon, -7); - _mainWindowViewModel.DashboardBindings.LootedChests.StaticEpicMonth = GetStats(TreasureRarity.Rare, TreasureType.StaticDungeon, -30); - _mainWindowViewModel.DashboardBindings.LootedChests.StaticEpicYear = GetStats(TreasureRarity.Rare, TreasureType.StaticDungeon, -365); - _mainWindowViewModel.DashboardBindings.LootedChests.StaticLegendaryWeek = GetStats(TreasureRarity.Legendary, TreasureType.StaticDungeon, -7); - _mainWindowViewModel.DashboardBindings.LootedChests.StaticLegendaryMonth = GetStats(TreasureRarity.Legendary, TreasureType.StaticDungeon, -30); - _mainWindowViewModel.DashboardBindings.LootedChests.StaticLegendaryYear = GetStats(TreasureRarity.Legendary, TreasureType.StaticDungeon, -365); + #region Random group dungeons + + _mainWindowViewModel.DashboardBindings.LootedChests.RandomGroupDungeonCommonWeek = GetStats(TreasureRarity.Standard, TreasureType.RandomGroupDungeon, -7); + _mainWindowViewModel.DashboardBindings.LootedChests.RandomGroupDungeonCommonMonth = GetStats(TreasureRarity.Standard, TreasureType.RandomGroupDungeon, -30); + _mainWindowViewModel.DashboardBindings.LootedChests.RandomGroupDungeonCommonYear = GetStats(TreasureRarity.Standard, TreasureType.RandomGroupDungeon, -365); + _mainWindowViewModel.DashboardBindings.LootedChests.RandomGroupDungeonUncommonWeek = GetStats(TreasureRarity.Uncommon, TreasureType.RandomGroupDungeon, -7); + _mainWindowViewModel.DashboardBindings.LootedChests.RandomGroupDungeonUncommonMonth = GetStats(TreasureRarity.Uncommon, TreasureType.RandomGroupDungeon, -30); + _mainWindowViewModel.DashboardBindings.LootedChests.RandomGroupDungeonUncommonYear = GetStats(TreasureRarity.Uncommon, TreasureType.RandomGroupDungeon, -365); + _mainWindowViewModel.DashboardBindings.LootedChests.RandomGroupDungeonEpicWeek = GetStats(TreasureRarity.Rare, TreasureType.RandomGroupDungeon, -7); + _mainWindowViewModel.DashboardBindings.LootedChests.RandomGroupDungeonEpicMonth = GetStats(TreasureRarity.Rare, TreasureType.RandomGroupDungeon, -30); + _mainWindowViewModel.DashboardBindings.LootedChests.RandomGroupDungeonEpicYear = GetStats(TreasureRarity.Rare, TreasureType.RandomGroupDungeon, -365); + _mainWindowViewModel.DashboardBindings.LootedChests.RandomGroupDungeonLegendaryWeek = GetStats(TreasureRarity.Legendary, TreasureType.RandomGroupDungeon, -7); + _mainWindowViewModel.DashboardBindings.LootedChests.RandomGroupDungeonLegendaryMonth = GetStats(TreasureRarity.Legendary, TreasureType.RandomGroupDungeon, -30); + _mainWindowViewModel.DashboardBindings.LootedChests.RandomGroupDungeonLegendaryYear = GetStats(TreasureRarity.Legendary, TreasureType.RandomGroupDungeon, -365); + + #endregion + + #region Random solo dungeons + + _mainWindowViewModel.DashboardBindings.LootedChests.RandomSoloDungeonCommonWeek = GetStats(TreasureRarity.Standard, TreasureType.RandomSoloDungeon, -7); + _mainWindowViewModel.DashboardBindings.LootedChests.RandomSoloDungeonCommonMonth = GetStats(TreasureRarity.Standard, TreasureType.RandomSoloDungeon, -30); + _mainWindowViewModel.DashboardBindings.LootedChests.RandomSoloDungeonCommonYear = GetStats(TreasureRarity.Standard, TreasureType.RandomSoloDungeon, -365); + _mainWindowViewModel.DashboardBindings.LootedChests.RandomSoloDungeonUncommonWeek = GetStats(TreasureRarity.Uncommon, TreasureType.RandomSoloDungeon, -7); + _mainWindowViewModel.DashboardBindings.LootedChests.RandomSoloDungeonUncommonMonth = GetStats(TreasureRarity.Uncommon, TreasureType.RandomSoloDungeon, -30); + _mainWindowViewModel.DashboardBindings.LootedChests.RandomSoloDungeonUncommonYear = GetStats(TreasureRarity.Uncommon, TreasureType.RandomSoloDungeon, -365); + _mainWindowViewModel.DashboardBindings.LootedChests.RandomSoloDungeonEpicWeek = GetStats(TreasureRarity.Rare, TreasureType.RandomSoloDungeon, -7); + _mainWindowViewModel.DashboardBindings.LootedChests.RandomSoloDungeonEpicMonth = GetStats(TreasureRarity.Rare, TreasureType.RandomSoloDungeon, -30); + _mainWindowViewModel.DashboardBindings.LootedChests.RandomSoloDungeonEpicYear = GetStats(TreasureRarity.Rare, TreasureType.RandomSoloDungeon, -365); + _mainWindowViewModel.DashboardBindings.LootedChests.RandomSoloDungeonLegendaryWeek = GetStats(TreasureRarity.Legendary, TreasureType.RandomSoloDungeon, -7); + _mainWindowViewModel.DashboardBindings.LootedChests.RandomSoloDungeonLegendaryMonth = GetStats(TreasureRarity.Legendary, TreasureType.RandomSoloDungeon, -30); + _mainWindowViewModel.DashboardBindings.LootedChests.RandomSoloDungeonLegendaryYear = GetStats(TreasureRarity.Legendary, TreasureType.RandomSoloDungeon, -365); #endregion diff --git a/src/StatisticsAnalysisTool/Styles/DashboardStyles.xaml b/src/StatisticsAnalysisTool/Styles/DashboardStyles.xaml index 77d322ef3..393fb93fd 100644 --- a/src/StatisticsAnalysisTool/Styles/DashboardStyles.xaml +++ b/src/StatisticsAnalysisTool/Styles/DashboardStyles.xaml @@ -26,84 +26,84 @@ - - + + - + - - - + + + - + - - - + + + - + - - - + + + - + - - - + + + - + - - - + + + - - - + + + - - - + + + - - - + + + @@ -157,6 +157,56 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -198,6 +248,10 @@ + + + + diff --git a/src/StatisticsAnalysisTool/UserControls/DashboardControl.xaml b/src/StatisticsAnalysisTool/UserControls/DashboardControl.xaml index 205768316..b7c85586f 100644 --- a/src/StatisticsAnalysisTool/UserControls/DashboardControl.xaml +++ b/src/StatisticsAnalysisTool/UserControls/DashboardControl.xaml @@ -6,7 +6,7 @@ xmlns:viewModels="clr-namespace:StatisticsAnalysisTool.ViewModels" xmlns:fa5="http://schemas.fontawesome.com/icons/" mc:Ignorable="d" - d:DesignHeight="850" d:DesignWidth="800" + d:DesignHeight="1000" d:DesignWidth="800" d:DataContext="{d:DesignInstance Type=viewModels:MainWindowViewModel}">