diff --git a/DamageCalculator/.vs/DamageCalculator/v16/.suo b/DamageCalculator/.vs/DamageCalculator/v16/.suo index e638e13..2c0c297 100644 Binary files a/DamageCalculator/.vs/DamageCalculator/v16/.suo and b/DamageCalculator/.vs/DamageCalculator/v16/.suo differ diff --git a/DamageCalculator/.vs/DamageCalculator/v17/.suo b/DamageCalculator/.vs/DamageCalculator/v17/.suo new file mode 100644 index 0000000..817af84 Binary files /dev/null and b/DamageCalculator/.vs/DamageCalculator/v17/.suo differ diff --git a/DamageCalculator/DamageCalculator/CsgoHelper.cs b/DamageCalculator/DamageCalculator/CsgoHelper.cs index a3ce3a3..f3f5e0f 100644 --- a/DamageCalculator/DamageCalculator/CsgoHelper.cs +++ b/DamageCalculator/DamageCalculator/CsgoHelper.cs @@ -83,22 +83,59 @@ namespace Damage_Calculator return true; } - public List GetMaps() + public List GetMaps() { List mapTextFiles = Directory.GetFiles(System.IO.Path.Combine(this.CsgoPath, "csgo\\resource\\overviews")).ToList().Where(f => f.ToLower().EndsWith(".txt")).Where(f => this.mapFileNameValid(f)).ToList(); - List maps = new List(); + List maps = new List(); foreach (string file in mapTextFiles) { + var map = new CsgoMap(); + + // Save path to radar file if available string potentialRadarFile = System.IO.Path.Combine(this.CsgoPath, "csgo\\resource\\overviews", System.IO.Path.GetFileNameWithoutExtension(file) + "_radar.dds"); - var map = new CsgoMapOverview(); if (File.Exists(potentialRadarFile)) { map.MapImagePath = potentialRadarFile; } + // Save path to BSP file if available + string potentialBspFile = System.IO.Path.Combine(this.CsgoPath, "csgo\\maps", System.IO.Path.GetFileNameWithoutExtension(file) + ".bsp"); + if (File.Exists(potentialBspFile)) + { + map.BspFilePath = potentialBspFile; + } + + // Save path to NAV file if available + string potentialNavFile = System.IO.Path.Combine(this.CsgoPath, "csgo\\maps", System.IO.Path.GetFileNameWithoutExtension(file) + ".nav"); + if (File.Exists(potentialNavFile)) + { + map.NavFilePath = potentialNavFile; + } + + // Set map type + switch (System.IO.Path.GetFileNameWithoutExtension(file).Split('_').First().ToLower()) + { + case "de": + map.MapType = CsgoMap.eMapType.Defusal; + break; + case "cs": + map.MapType = CsgoMap.eMapType.Hostage; + break; + case "dz": + map.MapType = CsgoMap.eMapType.DangerZone; + break; + case "ar": + map.MapType = CsgoMap.eMapType.ArmsRace; + break; + default: + map.MapType = CsgoMap.eMapType.Undefined; + break; + } + + // Get properties from accompanying text file var vdf = new VDFFile(file); if (vdf.RootElements.Count > 0) { @@ -149,11 +186,13 @@ namespace Damage_Calculator } } + // Save map name without prefix map.MapFileName = System.IO.Path.GetFileNameWithoutExtension(file).Split('_').Last(); DDSImage image; try { + // Read actual radar image = new DDSImage(System.IO.File.ReadAllBytes(map.MapImagePath)); } catch @@ -162,8 +201,10 @@ namespace Damage_Calculator } if (image.BitmapImage.Width != image.BitmapImage.Height) + // We only want square map images, which should normally always be given continue; + // Some workaround I found online for some thread error I forgot System.Windows.Application.Current.Dispatcher.Invoke((Action)delegate { map.MapImage = Globals.BitmapToImageSource(image.BitmapImage); @@ -338,5 +379,44 @@ namespace Damage_Calculator return false; } + + /// + /// Reads entity list from uncompressed BSP file. + /// + /// The absolute path to the BSP file. + /// the entity list, null if actual length differed from length specified in file, or a general error occurred. + public string ReadEntityListFromBsp(string bspFilePath) + { + using(var bspFile = File.OpenRead(bspFilePath)) + { + using(var reader = new BinaryReader(bspFile)) + { + reader.BaseStream.Position = 8; // Skip magic bytes and file version + int offset = reader.ReadInt32(); // Lump data offset from beginning of file + int length = reader.ReadInt32(); // Length of lump data + + reader.BaseStream.Position = offset; + char[] chars = new char[length]; + int charsRead = reader.Read(chars, 0, length); + + if(charsRead == length) + { + // Everything was read + return new string(chars); + } + } + } + return null; + } + + private bool isLumpUnused(byte[] lump) + { + for(int i = 0; i < lump.Length; i++) + { + if (lump[i] != 0) + return false; + } + return true; + } } } diff --git a/DamageCalculator/DamageCalculator/DamageCalculator.csproj b/DamageCalculator/DamageCalculator/DamageCalculator.csproj index c9d72b2..fb0fd5e 100644 --- a/DamageCalculator/DamageCalculator/DamageCalculator.csproj +++ b/DamageCalculator/DamageCalculator/DamageCalculator.csproj @@ -68,8 +68,10 @@ + + - + diff --git a/DamageCalculator/DamageCalculator/Globals.cs b/DamageCalculator/DamageCalculator/Globals.cs index 7a0b488..6a32d3c 100644 --- a/DamageCalculator/DamageCalculator/Globals.cs +++ b/DamageCalculator/DamageCalculator/Globals.cs @@ -24,5 +24,22 @@ namespace Damage_Calculator image.EndInit(); return image; } + + /// + /// Reads data (structs and primitive types (except strings)) into a struct. + /// + /// The type of struct. + /// The data to be fitted. + /// The data interpreted as the given struct. + static T ReadByteArrayIntoStruct(byte[] data) where T : struct + { + unsafe // needed to use pointers + { + fixed (byte* p = &data[0]) // Fixed so GC doesn't move shit, point to the first element + { + return (T)System.Runtime.InteropServices.Marshal.PtrToStructure(new IntPtr(p), typeof(T)); + } + } + } } } diff --git a/DamageCalculator/DamageCalculator/MainWindow.xaml b/DamageCalculator/DamageCalculator/MainWindow.xaml index 7d88da3..05b4cc8 100644 --- a/DamageCalculator/DamageCalculator/MainWindow.xaml +++ b/DamageCalculator/DamageCalculator/MainWindow.xaml @@ -5,7 +5,7 @@ xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" xmlns:local="clr-namespace:Damage_Calculator" mc:Ignorable="d" - Title="CS:GO Damage Calculator" Height="566" Width="826" MinHeight="560" MinWidth="450" + Title="CS:GO Damage Calculator" Height="566" Width="826" MinHeight="560" MinWidth="690" Style="{DynamicResource CustomWindowStyle}" WindowStartupLocation="CenterScreen" Icon="27.ico" MouseMove="Window_MouseMove" @@ -24,45 +24,53 @@ - + + + + + + - - - - - + + + + + + + + + + - - - - - - + - - + + + + + - + - + diff --git a/DamageCalculator/DamageCalculator/MainWindow.xaml.cs b/DamageCalculator/DamageCalculator/MainWindow.xaml.cs index 8fd773b..f6546f8 100644 --- a/DamageCalculator/DamageCalculator/MainWindow.xaml.cs +++ b/DamageCalculator/DamageCalculator/MainWindow.xaml.cs @@ -39,6 +39,11 @@ namespace Damage_Calculator private Line connectingLine = new Line(); + private MapPoint bombCircle = new MapPoint(); + + private eDrawMode DrawMode = eDrawMode.Shooting; + + // Extra icons private Image CTSpawnIcon; private Image TSpawnIcon; private Image ASiteIcon; @@ -49,7 +54,7 @@ namespace Damage_Calculator /// /// Gets or sets the currently loaded map. /// - private CsgoMapOverview loadedMap; + private CsgoMap loadedMap; private CsgoWeapon selectedWeapon; private BackgroundWorker bgWorker = new BackgroundWorker(); @@ -84,7 +89,7 @@ namespace Damage_Calculator // Add maps var maps = new List(); - foreach (var map in e.UserState as List) + foreach (var map in e.UserState as List) { var item = new ComboBoxItem(); @@ -191,27 +196,90 @@ namespace Damage_Calculator private void resetCanvas() { - this.pointsCanvas.Children.Clear(); - this.leftPoint = null; - this.rightPoint = null; - this.connectingLine = null; - this.unitsDistance = -1; - this.textDistanceMetres.Text = "0"; - this.textDistanceUnits.Text = "0"; - this.txtResult.Text = "0"; - this.txtResultArmor.Text = "0"; + if (this.IsInitialized) + { + this.pointsCanvas.Children.Clear(); + this.leftPoint = null; + this.rightPoint = null; + this.connectingLine = null; + this.bombCircle = null; + this.unitsDistance = -1; + this.textDistanceMetres.Text = "0"; + this.textDistanceUnits.Text = "0"; + this.txtResult.Text = "0"; + this.txtResultArmor.Text = "0"; + } } - private void loadMap(CsgoMapOverview map) + private void loadMap(CsgoMap map) { mapImage.Source = map.MapImage; + + if (map.BspFilePath != null) + { + // Map radar has an actual existing BSP map file + map.EntityList = Globals.Settings.CsgoHelper.ReadEntityListFromBsp(map.BspFilePath); + + // Separate all entities, which removes curly braces from the start or end of entities + string[] entities = map.EntityList.Split(new string[] { "}\n{" }, StringSplitOptions.None); + for (int i = 0; i < entities.Length; i++) + { + // Add start or end curly brace back, if nonexistent + if (!entities[i].StartsWith("{")) + entities[i] = "{" + entities[i]; + else if (!entities[i].EndsWith("}")) + entities[i] += "}"; + + // Add a generic name for the object, to fool it into complying with normal VDF standards + entities[i] = "\"entity\"\n" + entities[i]; + + VDFFile vdf = new VDFFile(entities[i], parseTextDirectly: true); + var elementRootVdf = vdf["entity"]; + if(elementRootVdf["classname"].Value == "info_map_parameters") + { + string bombRadius = elementRootVdf["bombradius"]?.Value; + if (bombRadius != null) + { + // Custom bomb radius + if (float.TryParse(bombRadius, out float bombRad) && bombRad >= 0) + { + // bombradius is valid and not negative + map.BombDamage = bombRad; + } + } + break; + } + } + } + + this.resetCanvas(); + + if (map.MapType == CsgoMap.eMapType.Defusal) + { + this.radioModeBomb.IsEnabled = true; + } + else + { + this.radioModeBomb.IsEnabled = false; + // Select the only other working one in that case + this.radioModeShooting.IsChecked = true; + } + + this.loadedMap = map; + } + + private double getPixelsFromUnits(double units) + { + int mapSizePixels = (this.mapImage.Source as BitmapSource).PixelWidth; + double mapSizeUnits = mapSizePixels * this.loadedMap.MapSizeMultiplier; + return units * this.pointsCanvas.ActualWidth / mapSizeUnits; } private Ellipse getPointEllipse(Color strokeColour) { Ellipse circle = new Ellipse(); circle.Fill = null; - circle.Width = circle.Height = 14; + circle.Width = circle.Height = this.getPixelsFromUnits(150); circle.Stroke = new SolidColorBrush(strokeColour); circle.StrokeThickness = 2; circle.IsHitTestVisible = false; @@ -219,29 +287,65 @@ namespace Damage_Calculator return circle; } + private Ellipse getBombEllipse(Color strokeColour) + { + Ellipse circle = new Ellipse(); + + Color fillColour = strokeColour; + fillColour.A = 50; + + circle.Fill = new SolidColorBrush(fillColour); + circle.Width = circle.Height = this.getPixelsFromUnits(loadedMap.BombDamage * 3.5 * 2); // * 2 cause radius to width + circle.Stroke = new SolidColorBrush(strokeColour); + circle.StrokeThickness = 3; + circle.IsHitTestVisible = false; + + return circle; + } + private void updateCirclePositions() { + // TODO: Update bomb circle size + if (this.connectingLine == null) this.connectingLine = new Line(); - if (leftPoint?.Circle != null) + if (this.leftPoint?.Circle != null) { - Canvas.SetLeft(leftPoint.Circle, (leftPoint.PercentageX * pointsCanvas.ActualWidth / 100f) - (leftPoint.Circle.Width / 2)); - Canvas.SetTop(leftPoint.Circle, (leftPoint.PercentageY * pointsCanvas.ActualHeight / 100f) - (leftPoint.Circle.Height / 2)); + Canvas.SetLeft(this.leftPoint.Circle, (this.leftPoint.PercentageX * pointsCanvas.ActualWidth / 100f) - (this.leftPoint.Circle.Width / 2)); + Canvas.SetTop(this.leftPoint.Circle, (this.leftPoint.PercentageY * pointsCanvas.ActualHeight / 100f) - (this.leftPoint.Circle.Height / 2)); + this.leftPoint.Circle.Width = this.leftPoint.Circle.Height = this.leftPoint.PercentageScale * this.pointsCanvas.ActualWidth / 100f; } - if (rightPoint?.Circle != null) + if (this.rightPoint?.Circle != null) { - Canvas.SetLeft(rightPoint.Circle, (rightPoint.PercentageX * pointsCanvas.ActualWidth / 100f) - (rightPoint.Circle.Width / 2)); - Canvas.SetTop(rightPoint.Circle, (rightPoint.PercentageY * pointsCanvas.ActualHeight / 100f) - (rightPoint.Circle.Height / 2)); + Canvas.SetLeft(this.rightPoint.Circle, (this.rightPoint.PercentageX * pointsCanvas.ActualWidth / 100f) - (this.rightPoint.Circle.Width / 2)); + Canvas.SetTop(this.rightPoint.Circle, (this.rightPoint.PercentageY * pointsCanvas.ActualHeight / 100f) - (this.rightPoint.Circle.Height / 2)); + this.rightPoint.Circle.Width = this.rightPoint.Circle.Height = this.rightPoint.PercentageScale * this.pointsCanvas.ActualWidth / 100f; } - if(leftPoint?.Circle != null && rightPoint?.Circle != null) + if (this.bombCircle?.Circle != null) { - this.connectingLine.X1 = Canvas.GetLeft(leftPoint.Circle) + (leftPoint.Circle.Width / 2); - this.connectingLine.Y1 = Canvas.GetTop(leftPoint.Circle) + (leftPoint.Circle.Height / 2); - this.connectingLine.X2 = Canvas.GetLeft(rightPoint.Circle) + (rightPoint.Circle.Width / 2); - this.connectingLine.Y2 = Canvas.GetTop(rightPoint.Circle) + (rightPoint.Circle.Height / 2); + Canvas.SetLeft(this.bombCircle.Circle, (this.bombCircle.PercentageX * pointsCanvas.ActualWidth / 100f) - (this.bombCircle.Circle.Width / 2)); + Canvas.SetTop(this.bombCircle.Circle, (this.bombCircle.PercentageY * pointsCanvas.ActualHeight / 100f) - (this.bombCircle.Circle.Height / 2)); + this.bombCircle.Circle.Width = this.bombCircle.Circle.Height = this.bombCircle.PercentageScale * this.pointsCanvas.ActualWidth / 100f; + } + + if((this.leftPoint?.Circle != null || this.bombCircle?.Circle != null) && this.rightPoint?.Circle != null) + { + if (this.DrawMode == eDrawMode.Shooting) + { + this.connectingLine.X1 = Canvas.GetLeft(this.leftPoint.Circle) + (this.leftPoint.Circle.Width / 2); + this.connectingLine.Y1 = Canvas.GetTop(this.leftPoint.Circle) + (this.leftPoint.Circle.Height / 2); + } + else + { + this.connectingLine.X1 = Canvas.GetLeft(this.bombCircle.Circle) + (this.bombCircle.Circle.Width / 2); + this.connectingLine.Y1 = Canvas.GetTop(this.bombCircle.Circle) + (this.bombCircle.Circle.Height / 2); + } + this.connectingLine.X2 = Canvas.GetLeft(this.rightPoint.Circle) + (this.rightPoint.Circle.Width / 2); + this.connectingLine.Y2 = Canvas.GetTop(this.rightPoint.Circle) + (this.rightPoint.Circle.Height / 2); + this.connectingLine.Fill = null; this.connectingLine.Stroke = new SolidColorBrush(Color.FromArgb(140, 255, 255, 255)); this.connectingLine.StrokeThickness = 2; @@ -261,91 +365,97 @@ namespace Damage_Calculator } else { + // No 2 circles are being drawn that need any connection this.lineDrawn = false; } if(this.loadedMap != null && this.loadedMap.CTSpawnMultiplierX != -1 && this.loadedMap.CTSpawnMultiplierY != -1) { - // CT Icon - if (this.CTSpawnIcon == null) - { - this.CTSpawnIcon = new Image(); - this.CTSpawnIcon.Source = new BitmapImage(new Uri("icon_ct.png", UriKind.RelativeOrAbsolute)); - this.CTSpawnIcon.Width = 25; - this.CTSpawnIcon.Height = 25; - this.CTSpawnIcon.Opacity = 0.6; - this.CTSpawnIcon.IsHitTestVisible = false; - } - - if(pointsCanvas.Children.IndexOf(CTSpawnIcon) == -1) - pointsCanvas.Children.Add(CTSpawnIcon); - - - Canvas.SetLeft(CTSpawnIcon, this.loadedMap.CTSpawnMultiplierX * this.mapImage.ActualWidth - (CTSpawnIcon.ActualWidth / 2)); - Canvas.SetTop(CTSpawnIcon, this.loadedMap.CTSpawnMultiplierY * this.mapImage.ActualWidth - (CTSpawnIcon.ActualHeight / 2)); - - // T Icon - if (this.TSpawnIcon == null) - { - this.TSpawnIcon = new Image(); - this.TSpawnIcon.Source = new BitmapImage(new Uri("icon_t.png", UriKind.RelativeOrAbsolute)); - this.TSpawnIcon.Width = 25; - this.TSpawnIcon.Height = 25; - this.TSpawnIcon.Opacity = 0.6; - this.TSpawnIcon.IsHitTestVisible = false; - } - - if (pointsCanvas.Children.IndexOf(TSpawnIcon) == -1) - pointsCanvas.Children.Add(TSpawnIcon); - - Canvas.SetLeft(TSpawnIcon, this.loadedMap.TSpawnMultiplierX * this.mapImage.ActualWidth - (TSpawnIcon.ActualWidth / 2)); - Canvas.SetTop(TSpawnIcon, this.loadedMap.TSpawnMultiplierY * this.mapImage.ActualWidth - (TSpawnIcon.ActualHeight / 2)); - - // Bomb A Icon - if (this.ASiteIcon == null) - { - this.ASiteIcon = new Image(); - this.ASiteIcon.Source = new BitmapImage(new Uri("icon_a_site.png", UriKind.RelativeOrAbsolute)); - this.ASiteIcon.Width = 25; - this.ASiteIcon.Height = 25; - this.ASiteIcon.Opacity = 0.6; - this.ASiteIcon.IsHitTestVisible = false; - } - - if (pointsCanvas.Children.IndexOf(ASiteIcon) == -1) - pointsCanvas.Children.Add(ASiteIcon); - - Canvas.SetLeft(ASiteIcon, this.loadedMap.BombAX * this.mapImage.ActualWidth - (ASiteIcon.ActualWidth / 2)); - Canvas.SetTop(ASiteIcon, this.loadedMap.BombAY * this.mapImage.ActualWidth - (ASiteIcon.ActualHeight / 2)); - - // Bomb B Icon - if (this.BSiteIcon == null) - { - this.BSiteIcon = new Image(); - this.BSiteIcon.Source = new BitmapImage(new Uri("icon_b_site.png", UriKind.RelativeOrAbsolute)); - this.BSiteIcon.Width = 25; - this.BSiteIcon.Height = 25; - this.BSiteIcon.Opacity = 0.6; - this.BSiteIcon.IsHitTestVisible = false; - } - - if (pointsCanvas.Children.IndexOf(BSiteIcon) == -1) - pointsCanvas.Children.Add(BSiteIcon); - - Canvas.SetLeft(BSiteIcon, this.loadedMap.BombBX * this.mapImage.ActualWidth - (BSiteIcon.ActualWidth / 2)); - Canvas.SetTop(BSiteIcon, this.loadedMap.BombBY * this.mapImage.ActualWidth - (BSiteIcon.ActualHeight / 2)); + this.positionIcons(); } } + private void positionIcons() + { + // CT Icon + if (this.CTSpawnIcon == null) + { + this.CTSpawnIcon = new Image(); + this.CTSpawnIcon.Source = new BitmapImage(new Uri("icon_ct.png", UriKind.RelativeOrAbsolute)); + this.CTSpawnIcon.Width = 25; + this.CTSpawnIcon.Height = 25; + this.CTSpawnIcon.Opacity = 0.6; + this.CTSpawnIcon.IsHitTestVisible = false; + } + + if (pointsCanvas.Children.IndexOf(CTSpawnIcon) == -1) + pointsCanvas.Children.Add(CTSpawnIcon); + + + Canvas.SetLeft(CTSpawnIcon, this.loadedMap.CTSpawnMultiplierX * this.mapImage.ActualWidth - (CTSpawnIcon.ActualWidth / 2)); + Canvas.SetTop(CTSpawnIcon, this.loadedMap.CTSpawnMultiplierY * this.mapImage.ActualWidth - (CTSpawnIcon.ActualHeight / 2)); + + // T Icon + if (this.TSpawnIcon == null) + { + this.TSpawnIcon = new Image(); + this.TSpawnIcon.Source = new BitmapImage(new Uri("icon_t.png", UriKind.RelativeOrAbsolute)); + this.TSpawnIcon.Width = 25; + this.TSpawnIcon.Height = 25; + this.TSpawnIcon.Opacity = 0.6; + this.TSpawnIcon.IsHitTestVisible = false; + } + + if (pointsCanvas.Children.IndexOf(TSpawnIcon) == -1) + pointsCanvas.Children.Add(TSpawnIcon); + + Canvas.SetLeft(TSpawnIcon, this.loadedMap.TSpawnMultiplierX * this.mapImage.ActualWidth - (TSpawnIcon.ActualWidth / 2)); + Canvas.SetTop(TSpawnIcon, this.loadedMap.TSpawnMultiplierY * this.mapImage.ActualWidth - (TSpawnIcon.ActualHeight / 2)); + + // Bomb A Icon + if (this.ASiteIcon == null) + { + this.ASiteIcon = new Image(); + this.ASiteIcon.Source = new BitmapImage(new Uri("icon_a_site.png", UriKind.RelativeOrAbsolute)); + this.ASiteIcon.Width = 25; + this.ASiteIcon.Height = 25; + this.ASiteIcon.Opacity = 0.6; + this.ASiteIcon.IsHitTestVisible = false; + } + + if (pointsCanvas.Children.IndexOf(ASiteIcon) == -1) + pointsCanvas.Children.Add(ASiteIcon); + + Canvas.SetLeft(ASiteIcon, this.loadedMap.BombAX * this.mapImage.ActualWidth - (ASiteIcon.ActualWidth / 2)); + Canvas.SetTop(ASiteIcon, this.loadedMap.BombAY * this.mapImage.ActualWidth - (ASiteIcon.ActualHeight / 2)); + + // Bomb B Icon + if (this.BSiteIcon == null) + { + this.BSiteIcon = new Image(); + this.BSiteIcon.Source = new BitmapImage(new Uri("icon_b_site.png", UriKind.RelativeOrAbsolute)); + this.BSiteIcon.Width = 25; + this.BSiteIcon.Height = 25; + this.BSiteIcon.Opacity = 0.6; + this.BSiteIcon.IsHitTestVisible = false; + } + + if (pointsCanvas.Children.IndexOf(BSiteIcon) == -1) + pointsCanvas.Children.Add(BSiteIcon); + + Canvas.SetLeft(BSiteIcon, this.loadedMap.BombBX * this.mapImage.ActualWidth - (BSiteIcon.ActualWidth / 2)); + Canvas.SetTop(BSiteIcon, this.loadedMap.BombBY * this.mapImage.ActualWidth - (BSiteIcon.ActualHeight / 2)); + } + private double calculateDotDistanceInUnits() { - Ellipse circleLeft = pointsCanvas.Children[pointsCanvas.Children.IndexOf(leftPoint.Circle)] as Ellipse; - double leftX = Canvas.GetLeft(circleLeft); - double leftY = Canvas.GetTop(circleLeft); + Ellipse circleLeft = pointsCanvas.Children[pointsCanvas.Children.IndexOf(this.DrawMode == eDrawMode.Shooting ? this.leftPoint.Circle : this.bombCircle.Circle)] as Ellipse; + double leftX = Canvas.GetLeft(circleLeft) + circleLeft.ActualWidth / 2; + double leftY = Canvas.GetTop(circleLeft) + circleLeft.ActualHeight / 2; Ellipse circleRight = pointsCanvas.Children[pointsCanvas.Children.IndexOf(rightPoint.Circle)] as Ellipse; - double rightX = Canvas.GetLeft(circleRight); - double rightY = Canvas.GetTop(circleRight); + double rightX = Canvas.GetLeft(circleRight) + circleRight.ActualWidth / 2; + double rightY = Canvas.GetTop(circleRight) + circleRight.ActualHeight / 2; // Distance in shown pixels double diffPixels = Math.Sqrt(Math.Pow(Math.Abs(leftX - rightX), 2) + Math.Pow(Math.Abs(leftY - rightY), 2)); @@ -362,94 +472,13 @@ namespace Damage_Calculator return unitsDifference; } - #region events - private void mapImage_LayoutUpdated(object sender, EventArgs e) + private void calculateAndUpdateShootingDamage() { - this.updateCirclePositions(); - } - - private void mapImage_MouseLeftButtonUp(object sender, MouseButtonEventArgs e) - { - if (this.leftPoint == null) - leftPoint = new MapPoint(); - - Point mousePos = Mouse.GetPosition(pointsCanvas); - pointsCanvas.Children.Remove(leftPoint.Circle); - - var circle = this.getPointEllipse(this.leftPointColour); - - pointsCanvas.Children.Add(circle); - - leftPoint.PercentageX = mousePos.X * 100f / pointsCanvas.ActualWidth; - leftPoint.PercentageY = mousePos.Y * 100f / pointsCanvas.ActualHeight; - - leftPoint.Circle = circle; - - this.updateCirclePositions(); - } - - private void mapImage_MouseRightButtonUp(object sender, MouseButtonEventArgs e) - { - if (this.rightPoint == null) - this.rightPoint = new MapPoint(); - - Point mousePos = Mouse.GetPosition(pointsCanvas); - pointsCanvas.Children.Remove(rightPoint.Circle); - - var circle = this.getPointEllipse(this.rightPointColour); - - pointsCanvas.Children.Add(circle); - - rightPoint.PercentageX = mousePos.X * 100f / pointsCanvas.ActualWidth; - rightPoint.PercentageY = mousePos.Y * 100f / pointsCanvas.ActualHeight; - - rightPoint.Circle = circle; - - this.updateCirclePositions(); - } - - private void changeTheme_Click(object sender, RoutedEventArgs e) - { - switch (int.Parse(((MenuItem)sender).Uid)) - { - case 0: REghZyFramework.Themes.ThemesController.SetTheme(REghZyFramework.Themes.ThemesController.ThemeTypes.Dark); - rectTop.Fill = rectSide.Fill = new SolidColorBrush(Colors.White); - txtEasterEggMetres.Text = "Metres:"; - break; - case 1: REghZyFramework.Themes.ThemesController.SetTheme(REghZyFramework.Themes.ThemesController.ThemeTypes.Light); - rectTop.Fill = rectSide.Fill = new SolidColorBrush(Colors.Black); - txtEasterEggMetres.Text = "Meters:"; - break; - } - e.Handled = true; - } - - private void comboBoxMaps_SelectionChanged(object sender, SelectionChangedEventArgs e) - { - var map = ((sender as ComboBox).SelectedItem as ComboBoxItem)?.Tag as CsgoMapOverview; - - if (map != null) - this.loadMap(map); - - this.resetCanvas(); - this.loadedMap = map; - } - - private void settings_Updated(object sender, EventArgs e) - { - if (this.selectedWeapon == null || !this.lineDrawn) - { - if(txtResult != null && txtResultArmor != null) - txtResult.Text = txtResultArmor.Text = "0"; - - return; - } - double damage = this.selectedWeapon.BaseDamage; double absorbedDamageByArmor = 0; bool wasArmorHit = false; - if(this.unitsDistance > this.selectedWeapon.MaxBulletRange) + if (this.unitsDistance > this.selectedWeapon.MaxBulletRange) { damage = 0; txtResult.Text = txtResultArmor.Text = damage.ToString(); @@ -474,7 +503,7 @@ namespace Damage_Calculator wasArmorHit = true; } } - else if(radioChestArms.IsChecked == true) + else if (radioChestArms.IsChecked == true) { // Chest or arms if (chkKevlar.IsChecked == true) @@ -486,7 +515,7 @@ namespace Damage_Calculator wasArmorHit = true; } } - else if(radioStomach.IsChecked == true) + else if (radioStomach.IsChecked == true) { // Stomach damage *= 1.25f; @@ -513,6 +542,184 @@ namespace Damage_Calculator // TODO: HP and armor and HP and armor left after shot } + private void calculateAndUpdateBombDamage() + { + const double damagePercentage = 1.0d; + + double flDamage = this.loadedMap.BombDamage; // 500 - default, if radius is not written on the map https://i.imgur.com/mUSaTHj.png + double flBombRadius = flDamage * 3.5d; + double flDistanceToLocalPlayer = (double)this.unitsDistance;// ((c4bomb origin + viewoffset) - (localplayer origin + viewoffset)) + double fSigma = flBombRadius / 3.0d; + double fGaussianFalloff = Math.Exp(-flDistanceToLocalPlayer * flDistanceToLocalPlayer / (2.0d * fSigma * fSigma)); + double flAdjustedDamage = flDamage * fGaussianFalloff * damagePercentage; + + bool wasArmorHit = false; + double flAdjustedDamageBeforeArmor = flAdjustedDamage; + + if (chkArmorAny.IsChecked == true) + { + flAdjustedDamage = scaleDamageArmor(flAdjustedDamage, 100); + wasArmorHit = true; + } + + txtResult.Text = ((int)flAdjustedDamage).ToString(); + + txtResultArmor.Text = (wasArmorHit ? (int)((flAdjustedDamageBeforeArmor - flAdjustedDamage) / 2) : 0).ToString(); + } + + double scaleDamageArmor(double flDamage, int armor_value) + { + double flArmorRatio = 0.5d; + double flArmorBonus = 0.5d; + if (armor_value > 0) + { + double flNew = flDamage * flArmorRatio; + double flArmor = (flDamage - flNew) * flArmorBonus; + + if (flArmor > (double)armor_value) + { + flArmor = (double)armor_value * (1d / flArmorBonus); + flNew = flDamage - flArmor; + } + + flDamage = flNew; + } + return flDamage; + } + + #region events + private void radioModeShooting_Checked(object sender, RoutedEventArgs e) + { + this.resetCanvas(); + this.DrawMode = eDrawMode.Shooting; + if (this.IsInitialized) + { + this.stackArmorSeparated.Visibility = this.stackAreaHit.Visibility = this.stackWeaponUsed.Visibility = Visibility.Visible; + this.chkArmorAny.Visibility = Visibility.Collapsed; + } + } + + private void radioModeBomb_Checked(object sender, RoutedEventArgs e) + { + this.resetCanvas(); + this.DrawMode = eDrawMode.Bomb; + if (this.IsInitialized) + { + this.stackArmorSeparated.Visibility = this.stackAreaHit.Visibility = this.stackWeaponUsed.Visibility = Visibility.Collapsed; + this.chkArmorAny.Visibility = Visibility.Visible; + } + } + + private void mapImage_LayoutUpdated(object sender, EventArgs e) + { + this.updateCirclePositions(); + } + + private void mapImage_MouseLeftButtonUp(object sender, MouseButtonEventArgs e) + { + if (this.DrawMode == eDrawMode.Shooting) + { + if (this.leftPoint == null) + this.leftPoint = new MapPoint(); + + Point mousePos = Mouse.GetPosition(this.pointsCanvas); + this.pointsCanvas.Children.Remove(this.leftPoint.Circle); + + var circle = this.getPointEllipse(this.leftPointColour); + + this.pointsCanvas.Children.Add(circle); + + this.leftPoint.PercentageX = mousePos.X * 100f / this.pointsCanvas.ActualWidth; + this.leftPoint.PercentageY = mousePos.Y * 100f / this.pointsCanvas.ActualHeight; + this.leftPoint.PercentageScale = circle.Width * 100f / this.pointsCanvas.ActualWidth; + + this.leftPoint.Circle = circle; + + this.updateCirclePositions(); + } + else if (this.DrawMode == eDrawMode.Bomb) + { + if (this.bombCircle == null) + this.bombCircle = new MapPoint(); + + Point mousePos = Mouse.GetPosition(this.pointsCanvas); + this.pointsCanvas.Children.Remove(this.bombCircle.Circle); + + var circle = this.getBombEllipse(this.leftPointColour); + + this.pointsCanvas.Children.Add(circle); + + this.bombCircle.PercentageX = mousePos.X * 100f / this.pointsCanvas.ActualWidth; + this.bombCircle.PercentageY = mousePos.Y * 100f / this.pointsCanvas.ActualHeight; + this.bombCircle.PercentageScale = circle.Width * 100f / this.pointsCanvas.ActualWidth; + + this.bombCircle.Circle = circle; + + this.updateCirclePositions(); + } + } + + private void mapImage_MouseRightButtonUp(object sender, MouseButtonEventArgs e) + { + if (this.rightPoint == null) + this.rightPoint = new MapPoint(); + + Point mousePos = Mouse.GetPosition(this.pointsCanvas); + this.pointsCanvas.Children.Remove(this.rightPoint.Circle); + + var circle = this.getPointEllipse(this.rightPointColour); + + this.pointsCanvas.Children.Add(circle); + + this.rightPoint.PercentageX = mousePos.X * 100f / this.pointsCanvas.ActualWidth; + this.rightPoint.PercentageY = mousePos.Y * 100f / this.pointsCanvas.ActualHeight; + this.rightPoint.PercentageScale = circle.Width * 100f / this.pointsCanvas.ActualWidth; + + this.rightPoint.Circle = circle; + + this.updateCirclePositions(); + } + + private void changeTheme_Click(object sender, RoutedEventArgs e) + { + switch (int.Parse(((MenuItem)sender).Uid)) + { + case 0: REghZyFramework.Themes.ThemesController.SetTheme(REghZyFramework.Themes.ThemesController.ThemeTypes.Dark); + rectTop.Fill = rectSide.Fill = new SolidColorBrush(Colors.White); + txtEasterEggMetres.Text = "Metres:"; + break; + case 1: REghZyFramework.Themes.ThemesController.SetTheme(REghZyFramework.Themes.ThemesController.ThemeTypes.Light); + rectTop.Fill = rectSide.Fill = new SolidColorBrush(Colors.Black); + txtEasterEggMetres.Text = "Meters:"; + break; + } + e.Handled = true; + } + + private void comboBoxMaps_SelectionChanged(object sender, SelectionChangedEventArgs e) + { + var map = ((sender as ComboBox).SelectedItem as ComboBoxItem)?.Tag as CsgoMap; + + if (map != null) + this.loadMap(map); + } + + private void settings_Updated(object sender, EventArgs e) + { + if ((this.DrawMode == eDrawMode.Shooting && this.selectedWeapon == null) || !this.lineDrawn) + { + if(txtResult != null && txtResultArmor != null) + txtResult.Text = txtResultArmor.Text = "0"; + + return; + } + + if (this.DrawMode == eDrawMode.Shooting) + this.calculateAndUpdateShootingDamage(); + else if (this.DrawMode == eDrawMode.Bomb) + calculateAndUpdateBombDamage(); + } + private void comboWeapons_SelectionChanged(object sender, SelectionChangedEventArgs e) { var weapon = ((sender as ComboBox).SelectedItem as ComboBoxItem)?.Tag as CsgoWeapon; @@ -566,4 +773,6 @@ namespace Damage_Calculator } #endregion } + + enum eDrawMode { Shooting, Bomb } } diff --git a/DamageCalculator/DamageCalculator/Models/BSPHeader.cs b/DamageCalculator/DamageCalculator/Models/BSPHeader.cs new file mode 100644 index 0000000..5013e75 --- /dev/null +++ b/DamageCalculator/DamageCalculator/Models/BSPHeader.cs @@ -0,0 +1,34 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace Damage_Calculator.Models +{ + internal class BSPHeader + { + public static int HEADER_LUMPS = 64; + + /// + /// The magic bytes that should be VBSP. + /// + public int Ident { get; set; } + + /// + /// The BSP file version. (CS:GO uses 21 or 0x15) + /// + public int Version { get; set; } + + /// + /// The dictionary of lumps. The size is set as 64, probably in the SDK. + /// Unusued lumps have all bytes set to 0. + /// + public BSPLump[] Lumps = new BSPLump[HEADER_LUMPS]; + + /// + /// Version number of map. Might increase every time a map is saved in Hammer. + /// + public int MapRevision { get; set; } + } +} diff --git a/DamageCalculator/DamageCalculator/Models/BSPLump.cs b/DamageCalculator/DamageCalculator/Models/BSPLump.cs new file mode 100644 index 0000000..15372c2 --- /dev/null +++ b/DamageCalculator/DamageCalculator/Models/BSPLump.cs @@ -0,0 +1,32 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace Damage_Calculator.Models +{ + internal class BSPLump + { + /// + /// The offset of the lump block from the beginning of the file. + /// It's rounded up to the nearest 4-byte boundary, as is the corresponding data lump. + /// + public int LumpBlockOffset { get; set; } + + /// + /// The length of the lump block in bytes. + /// + public int LumpBlockLength { get; set; } + + /// + /// Version of the format of the lump, usually 0. + /// + public int LumpVersion { get; set; } + + /// + /// The four CC identifier, that is usually all 0s. For compressed lumps it's the uncompressed lump data size as int. + /// + public char[] FourCC { get; set; } = new char[4]; + } +} diff --git a/DamageCalculator/DamageCalculator/Models/CsgoMap.cs b/DamageCalculator/DamageCalculator/Models/CsgoMap.cs new file mode 100644 index 0000000..a42c7e2 --- /dev/null +++ b/DamageCalculator/DamageCalculator/Models/CsgoMap.cs @@ -0,0 +1,126 @@ +using System; +using System.Collections.Generic; +using System.Drawing; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Windows.Media.Imaging; + +namespace Damage_Calculator.Models +{ + public class CsgoMap + { + /// + /// The types of maps. + /// + public enum eMapType { Undefined, Defusal, Hostage, DangerZone, ArmsRace } + + /// + /// The actual radar image of the map. + /// + public BitmapSource MapImage { get; set; } + + /// + /// The type of gamemode that's played on this map by default. + /// + public eMapType MapType { get; set; } + + /// + /// The absolute path to the DDS map radar file. + /// + public string MapImagePath { get; set; } + + /// + /// The absolute path to the actual BSP map file. + /// + public string BspFilePath { get; set; } + + /// + /// The absolute path to the file that holds this map's navigation meshes and callouts. + /// This might not always be existent, because it is generated by the map builder. + /// It is always created with maps that are in the main game, because they need callouts and bot movements. + /// + public string NavFilePath { get; set; } + + /// + /// The map name as given in the file name, but without the prefix. + /// + public string MapFileName { get; set; } + + /// + /// The multiplier that is stored in the text file with each map. + /// The pixels will get multiplied with this multiplier to get in-game units. + /// + public float MapSizeMultiplier { get; set; } + + /// + /// The X coordinate that is in the upper left hand corner of the radar. + /// This is used to position some things according to their coordinates, such as player spawns and nav meshes. + /// + public float UpperLeftWorldXCoordinate { get; set; } = -1; + + /// + /// The Y coordinate that is in the upper left hand corner of the radar. + /// This is used to position some things according to their coordinates, such as player spawns and nav meshes. + /// + public float UpperLeftWorldYCoordinate { get; set; } = -1; + + /// + /// The X position of the CT spawn icon on the map (used in the loading screen). + /// Floating point, 0 is left and 1 is right. + /// + public float CTSpawnMultiplierX { get; set; } = -1; + + /// + /// The Y position of the CT spawn icon on the map (used in the loading screen). + /// Floating point, 0 is top and 1 is bottom. + /// + public float CTSpawnMultiplierY { get; set; } = -1; + + /// + /// The X position of the T spawn icon on the map (used in the loading screen). + /// Floating point, 0 is left and 1 is right. + /// + public float TSpawnMultiplierX { get; set; } = -1; + + /// + /// The Y position of the T spawn icon on the map (used in the loading screen). + /// Floating point, 0 is top and 1 is bottom. + /// + public float TSpawnMultiplierY { get; set; } = -1; + + /// + /// The X position of the bomb site A icon on the map (used in the loading screen). + /// Floating point, 0 is left and 1 is right. + /// + public float BombAX { get; set; } = -1; + + /// + /// The Y position of the bomb site A icon on the map (used in the loading screen). + /// Floating point, 0 is top and 1 is bottom. + /// + public float BombAY { get; set; } = -1; + + /// + /// The X position of the bomb site B icon on the map (used in the loading screen). + /// Floating point, 0 is left and 1 is right. + /// + public float BombBX { get; set; } = -1; + + /// + /// The Y position of the bomb site B icon on the map (used in the loading screen). + /// Floating point, 0 is top and 1 is bottom. + /// + public float BombBY { get; set; } = -1; + + /// + /// The bomb damage in this map. By default it's 500. + /// + public float BombDamage { get; set; } = 500; + + /// + /// Raw list of entities in this map, as stored in the BSP file. + /// + public string EntityList { get; set; } + } +} diff --git a/DamageCalculator/DamageCalculator/Models/CsgoMapOverview.cs b/DamageCalculator/DamageCalculator/Models/CsgoMapOverview.cs deleted file mode 100644 index e223fa7..0000000 --- a/DamageCalculator/DamageCalculator/Models/CsgoMapOverview.cs +++ /dev/null @@ -1,41 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Drawing; -using System.Linq; -using System.Text; -using System.Threading.Tasks; -using System.Windows.Media.Imaging; - -namespace Damage_Calculator.Models -{ - public class CsgoMapOverview - { - public BitmapSource MapImage { get; set; } - - public string MapImagePath { get; set; } - - public string MapFileName { get; set; } - - public float MapSizeMultiplier { get; set; } - - public float UpperLeftWorldXCoordinate { get; set; } = -1; - - public float UpperLeftWorldYCoordinate { get; set; } = -1; - - public float CTSpawnMultiplierX { get; set; } = -1; - - public float CTSpawnMultiplierY { get; set; } = -1; - - public float TSpawnMultiplierX { get; set; } = -1; - - public float TSpawnMultiplierY { get; set; } = -1; - - public float BombAX { get; set; } = -1; - - public float BombAY { get; set; } = -1; - - public float BombBX { get; set; } = -1; - - public float BombBY { get; set; } = -1; - } -} diff --git a/DamageCalculator/DamageCalculator/Models/MapPoint.cs b/DamageCalculator/DamageCalculator/Models/MapPoint.cs index 3616dd1..e5f1a78 100644 --- a/DamageCalculator/DamageCalculator/Models/MapPoint.cs +++ b/DamageCalculator/DamageCalculator/Models/MapPoint.cs @@ -13,5 +13,7 @@ namespace Damage_Calculator.Models public double PercentageX { get; set; } public double PercentageY { get; set; } + + public double PercentageScale { get; set; } } } diff --git a/DamageCalculator/DamageCalculator/Properties/AssemblyInfo.cs b/DamageCalculator/DamageCalculator/Properties/AssemblyInfo.cs index e70fd94..b91b22c 100644 --- a/DamageCalculator/DamageCalculator/Properties/AssemblyInfo.cs +++ b/DamageCalculator/DamageCalculator/Properties/AssemblyInfo.cs @@ -51,5 +51,5 @@ using System.Windows; // You can specify all the values or you can default the Build and Revision Numbers // by using the '*' as shown below: // [assembly: AssemblyVersion("1.0.*")] -[assembly: AssemblyVersion("1.0.0.0")] -[assembly: AssemblyFileVersion("1.0.0.0")] +[assembly: AssemblyVersion("1.1.0.0")] +[assembly: AssemblyFileVersion("1.1.0.0")] diff --git a/DamageCalculator/DamageCalculator/ZatVdfParser/VdfFile.cs b/DamageCalculator/DamageCalculator/ZatVdfParser/VdfFile.cs index cb7c4d3..04bda32 100644 --- a/DamageCalculator/DamageCalculator/ZatVdfParser/VdfFile.cs +++ b/DamageCalculator/DamageCalculator/ZatVdfParser/VdfFile.cs @@ -19,10 +19,15 @@ namespace Damage_Calculator.ZatVdfParser #endregion #region CONSTRUCTORS - public VDFFile(string filePath) + /// + /// Default constructor. + /// + /// The path to the file, or the text to be parsed. + /// Whether the given parameter is a file path or the actual string to be parsed. + public VDFFile(string filePathOrText, bool parseTextDirectly = false) { RootElements = new List(); - Parse(filePath); + Parse(filePathOrText, parseTextDirectly); } #endregion @@ -34,10 +39,18 @@ namespace Damage_Calculator.ZatVdfParser builder.Append(child.ToVDF()); return builder.ToString(); } - private void Parse(string filePath) + private void Parse(string filePathOrText, bool parseTextDirectly) { Element currentLevel = null; - using (StreamReader reader = new StreamReader(filePath)) + + // Generate stream from string in case we want to read it directly, instead of using a file stream (boolean parameter) + var stream = new MemoryStream(); + var writer = new StreamWriter(stream); + writer.Write(filePathOrText); + writer.Flush(); + stream.Position = 0; + + using (StreamReader reader = parseTextDirectly ? new StreamReader(stream) : new StreamReader(filePathOrText)) { string line = null; while ((line = reader.ReadLine()) != null) diff --git a/DamageCalculator/DamageCalculator/bin/Debug/CSGO Damage Calculator.exe b/DamageCalculator/DamageCalculator/bin/Debug/CSGO Damage Calculator.exe index 7757c76..5507d8e 100644 Binary files a/DamageCalculator/DamageCalculator/bin/Debug/CSGO Damage Calculator.exe and b/DamageCalculator/DamageCalculator/bin/Debug/CSGO Damage Calculator.exe differ diff --git a/DamageCalculator/DamageCalculator/bin/Debug/CSGO Damage Calculator.pdb b/DamageCalculator/DamageCalculator/bin/Debug/CSGO Damage Calculator.pdb index 33cd9dd..d26fcf6 100644 Binary files a/DamageCalculator/DamageCalculator/bin/Debug/CSGO Damage Calculator.pdb and b/DamageCalculator/DamageCalculator/bin/Debug/CSGO Damage Calculator.pdb differ diff --git a/DamageCalculator/DamageCalculator/obj/Debug/About.baml b/DamageCalculator/DamageCalculator/obj/Debug/About.baml new file mode 100644 index 0000000..a862a04 Binary files /dev/null and b/DamageCalculator/DamageCalculator/obj/Debug/About.baml differ diff --git a/DamageCalculator/DamageCalculator/obj/Debug/App.baml b/DamageCalculator/DamageCalculator/obj/Debug/App.baml new file mode 100644 index 0000000..bdb0740 Binary files /dev/null and b/DamageCalculator/DamageCalculator/obj/Debug/App.baml differ diff --git a/DamageCalculator/DamageCalculator/obj/Debug/CSGO Damage Calculator.exe b/DamageCalculator/DamageCalculator/obj/Debug/CSGO Damage Calculator.exe index 7757c76..5507d8e 100644 Binary files a/DamageCalculator/DamageCalculator/obj/Debug/CSGO Damage Calculator.exe and b/DamageCalculator/DamageCalculator/obj/Debug/CSGO Damage Calculator.exe differ diff --git a/DamageCalculator/DamageCalculator/obj/Debug/CSGO Damage Calculator.g.resources b/DamageCalculator/DamageCalculator/obj/Debug/CSGO Damage Calculator.g.resources index 3e50f36..5fabdd1 100644 Binary files a/DamageCalculator/DamageCalculator/obj/Debug/CSGO Damage Calculator.g.resources and b/DamageCalculator/DamageCalculator/obj/Debug/CSGO Damage Calculator.g.resources differ diff --git a/DamageCalculator/DamageCalculator/obj/Debug/CSGO Damage Calculator.pdb b/DamageCalculator/DamageCalculator/obj/Debug/CSGO Damage Calculator.pdb index 33cd9dd..d26fcf6 100644 Binary files a/DamageCalculator/DamageCalculator/obj/Debug/CSGO Damage Calculator.pdb and b/DamageCalculator/DamageCalculator/obj/Debug/CSGO Damage Calculator.pdb differ diff --git a/DamageCalculator/DamageCalculator/obj/Debug/CSGO Damage Calculator_MarkupCompile.cache b/DamageCalculator/DamageCalculator/obj/Debug/CSGO Damage Calculator_MarkupCompile.cache index 3920e72..194ec0c 100644 --- a/DamageCalculator/DamageCalculator/obj/Debug/CSGO Damage Calculator_MarkupCompile.cache +++ b/DamageCalculator/DamageCalculator/obj/Debug/CSGO Damage Calculator_MarkupCompile.cache @@ -10,11 +10,11 @@ none false DEBUG;TRACE D:\source\repos\_Git Repos\DamageCalculator\DamageCalculator\DamageCalculator\App.xaml -6-2134167639 +6-1451057398 -26-1617113909 -15-2024074300 +27-418087645 +15-431277860 About.xaml;MainWindow.xaml;Themes\ColourfulDarkTheme.xaml;Themes\ColourfulLightTheme.xaml;Themes\DarkTheme.xaml;Themes\LightTheme.xaml; -True +False diff --git a/DamageCalculator/DamageCalculator/obj/Debug/CSGO Damage Calculator_MarkupCompile.i.cache b/DamageCalculator/DamageCalculator/obj/Debug/CSGO Damage Calculator_MarkupCompile.i.cache index 85a572f..76bdf40 100644 --- a/DamageCalculator/DamageCalculator/obj/Debug/CSGO Damage Calculator_MarkupCompile.i.cache +++ b/DamageCalculator/DamageCalculator/obj/Debug/CSGO Damage Calculator_MarkupCompile.i.cache @@ -4,16 +4,16 @@ winexe C# .cs -D:\source\repos\_Git Repos\ConfigManager\Config Manager\Config Manager\obj\Debug\ +D:\source\repos\_Git Repos\DamageCalculator\DamageCalculator\DamageCalculator\obj\Debug\ Damage_Calculator none false DEBUG;TRACE -D:\source\repos\_Git Repos\ConfigManager\Config Manager\Config Manager\App.xaml -6-2134167639 +D:\source\repos\_Git Repos\DamageCalculator\DamageCalculator\DamageCalculator\App.xaml +6-1451057398 -26-1617113909 -15-2024074300 +281503690476 +15-431277860 About.xaml;MainWindow.xaml;Themes\ColourfulDarkTheme.xaml;Themes\ColourfulLightTheme.xaml;Themes\DarkTheme.xaml;Themes\LightTheme.xaml; False diff --git a/DamageCalculator/DamageCalculator/obj/Debug/DamageCalculator.csproj.AssemblyReference.cache b/DamageCalculator/DamageCalculator/obj/Debug/DamageCalculator.csproj.AssemblyReference.cache index ac27525..319484c 100644 Binary files a/DamageCalculator/DamageCalculator/obj/Debug/DamageCalculator.csproj.AssemblyReference.cache and b/DamageCalculator/DamageCalculator/obj/Debug/DamageCalculator.csproj.AssemblyReference.cache differ diff --git a/DamageCalculator/DamageCalculator/obj/Debug/DamageCalculator.csproj.CoreCompileInputs.cache b/DamageCalculator/DamageCalculator/obj/Debug/DamageCalculator.csproj.CoreCompileInputs.cache index 98fd2b7..c998576 100644 --- a/DamageCalculator/DamageCalculator/obj/Debug/DamageCalculator.csproj.CoreCompileInputs.cache +++ b/DamageCalculator/DamageCalculator/obj/Debug/DamageCalculator.csproj.CoreCompileInputs.cache @@ -1 +1 @@ -122c08730e8337de833cb8cdc126614cbd177202 +9c412881d045825628cde2338aa0ccf0cb1fd134 diff --git a/DamageCalculator/DamageCalculator/obj/Debug/DamageCalculator.csproj.FileListAbsolute.txt b/DamageCalculator/DamageCalculator/obj/Debug/DamageCalculator.csproj.FileListAbsolute.txt index a71e40e..98a1374 100644 --- a/DamageCalculator/DamageCalculator/obj/Debug/DamageCalculator.csproj.FileListAbsolute.txt +++ b/DamageCalculator/DamageCalculator/obj/Debug/DamageCalculator.csproj.FileListAbsolute.txt @@ -23,3 +23,30 @@ D:\source\repos\_Git Repos\ConfigManager\Config Manager\DamageCalculator\obj\Deb D:\source\repos\_Git Repos\ConfigManager\Config Manager\DamageCalculator\obj\Debug\DamageCalculator.csproj.CoreCompileInputs.cache D:\source\repos\_Git Repos\ConfigManager\Config Manager\DamageCalculator\obj\Debug\CSGO Damage Calculator.exe D:\source\repos\_Git Repos\ConfigManager\Config Manager\DamageCalculator\obj\Debug\CSGO Damage Calculator.pdb +D:\source\repos\_Git Repos\DamageCalculator\DamageCalculator\DamageCalculator\bin\Debug\CSGO Damage Calculator.exe.config +D:\source\repos\_Git Repos\DamageCalculator\DamageCalculator\DamageCalculator\bin\Debug\CSGO Damage Calculator.exe +D:\source\repos\_Git Repos\DamageCalculator\DamageCalculator\DamageCalculator\bin\Debug\CSGO Damage Calculator.pdb +D:\source\repos\_Git Repos\DamageCalculator\DamageCalculator\DamageCalculator\obj\Debug\DamageCalculator.csproj.AssemblyReference.cache +D:\source\repos\_Git Repos\DamageCalculator\DamageCalculator\DamageCalculator\obj\Debug\Themes\ColourfulDarkTheme.baml +D:\source\repos\_Git Repos\DamageCalculator\DamageCalculator\DamageCalculator\obj\Debug\Themes\ColourfulLightTheme.baml +D:\source\repos\_Git Repos\DamageCalculator\DamageCalculator\DamageCalculator\obj\Debug\Themes\DarkTheme.baml +D:\source\repos\_Git Repos\DamageCalculator\DamageCalculator\DamageCalculator\obj\Debug\Themes\LightTheme.baml +D:\source\repos\_Git Repos\DamageCalculator\DamageCalculator\DamageCalculator\obj\Debug\About.g.cs +D:\source\repos\_Git Repos\DamageCalculator\DamageCalculator\DamageCalculator\obj\Debug\MainWindow.g.cs +D:\source\repos\_Git Repos\DamageCalculator\DamageCalculator\DamageCalculator\obj\Debug\Themes\ColourfulDarkTheme.g.cs +D:\source\repos\_Git Repos\DamageCalculator\DamageCalculator\DamageCalculator\obj\Debug\Themes\ColourfulLightTheme.g.cs +D:\source\repos\_Git Repos\DamageCalculator\DamageCalculator\DamageCalculator\obj\Debug\Themes\DarkTheme.g.cs +D:\source\repos\_Git Repos\DamageCalculator\DamageCalculator\DamageCalculator\obj\Debug\Themes\LightTheme.g.cs +D:\source\repos\_Git Repos\DamageCalculator\DamageCalculator\DamageCalculator\obj\Debug\App.g.cs +D:\source\repos\_Git Repos\DamageCalculator\DamageCalculator\DamageCalculator\obj\Debug\CSGO Damage Calculator_MarkupCompile.cache +D:\source\repos\_Git Repos\DamageCalculator\DamageCalculator\DamageCalculator\obj\Debug\CSGO Damage Calculator_MarkupCompile.lref +D:\source\repos\_Git Repos\DamageCalculator\DamageCalculator\DamageCalculator\obj\Debug\App.baml +D:\source\repos\_Git Repos\DamageCalculator\DamageCalculator\DamageCalculator\obj\Debug\About.baml +D:\source\repos\_Git Repos\DamageCalculator\DamageCalculator\DamageCalculator\obj\Debug\MainWindow.baml +D:\source\repos\_Git Repos\DamageCalculator\DamageCalculator\DamageCalculator\obj\Debug\CSGO Damage Calculator.g.resources +D:\source\repos\_Git Repos\DamageCalculator\DamageCalculator\DamageCalculator\obj\Debug\Damage_Calculator.Properties.Resources.resources +D:\source\repos\_Git Repos\DamageCalculator\DamageCalculator\DamageCalculator\obj\Debug\DamageCalculator.csproj.GenerateResource.cache +D:\source\repos\_Git Repos\DamageCalculator\DamageCalculator\DamageCalculator\obj\Debug\DamageCalculator.csproj.CoreCompileInputs.cache +D:\source\repos\_Git Repos\DamageCalculator\DamageCalculator\DamageCalculator\obj\Debug\CSGO Damage Calculator.exe +D:\source\repos\_Git Repos\DamageCalculator\DamageCalculator\DamageCalculator\obj\Debug\CSGO Damage Calculator.pdb +D:\source\repos\_Git Repos\DamageCalculator\DamageCalculator\DamageCalculator\obj\Debug\DamageCalculator.csproj.SuggestedBindingRedirects.cache diff --git a/DamageCalculator/DamageCalculator/obj/Debug/DamageCalculator.csproj.GenerateResource.cache b/DamageCalculator/DamageCalculator/obj/Debug/DamageCalculator.csproj.GenerateResource.cache index c6b911f..a619c8c 100644 Binary files a/DamageCalculator/DamageCalculator/obj/Debug/DamageCalculator.csproj.GenerateResource.cache and b/DamageCalculator/DamageCalculator/obj/Debug/DamageCalculator.csproj.GenerateResource.cache differ diff --git a/DamageCalculator/DamageCalculator/obj/Debug/DamageCalculator.csproj.SuggestedBindingRedirects.cache b/DamageCalculator/DamageCalculator/obj/Debug/DamageCalculator.csproj.SuggestedBindingRedirects.cache new file mode 100644 index 0000000..e69de29 diff --git a/DamageCalculator/DamageCalculator/obj/Debug/DesignTimeResolveAssemblyReferences.cache b/DamageCalculator/DamageCalculator/obj/Debug/DesignTimeResolveAssemblyReferences.cache index 4f3c311..98868be 100644 Binary files a/DamageCalculator/DamageCalculator/obj/Debug/DesignTimeResolveAssemblyReferences.cache and b/DamageCalculator/DamageCalculator/obj/Debug/DesignTimeResolveAssemblyReferences.cache differ diff --git a/DamageCalculator/DamageCalculator/obj/Debug/DesignTimeResolveAssemblyReferencesInput.cache b/DamageCalculator/DamageCalculator/obj/Debug/DesignTimeResolveAssemblyReferencesInput.cache index 90d79d0..5ffa4a9 100644 Binary files a/DamageCalculator/DamageCalculator/obj/Debug/DesignTimeResolveAssemblyReferencesInput.cache and b/DamageCalculator/DamageCalculator/obj/Debug/DesignTimeResolveAssemblyReferencesInput.cache differ diff --git a/DamageCalculator/DamageCalculator/obj/Debug/MainWindow.baml b/DamageCalculator/DamageCalculator/obj/Debug/MainWindow.baml new file mode 100644 index 0000000..55961d0 Binary files /dev/null and b/DamageCalculator/DamageCalculator/obj/Debug/MainWindow.baml differ diff --git a/DamageCalculator/DamageCalculator/obj/Debug/MainWindow.g.cs b/DamageCalculator/DamageCalculator/obj/Debug/MainWindow.g.cs index 17544ba..a64f0db 100644 --- a/DamageCalculator/DamageCalculator/obj/Debug/MainWindow.g.cs +++ b/DamageCalculator/DamageCalculator/obj/Debug/MainWindow.g.cs @@ -1,4 +1,4 @@ -#pragma checksum "..\..\MainWindow.xaml" "{8829d00f-11b8-4213-878b-770e8597ac16}" "ED5BBC5CC0EF7E0364C4C9F7606BFAD438DA441A3D87364DB6EA1B2DD7DB2529" +#pragma checksum "..\..\MainWindow.xaml" "{8829d00f-11b8-4213-878b-770e8597ac16}" "7FEF1C1C14931282E3CD4C845E600884ED2172B171609E698A3BF061C58787F7" //------------------------------------------------------------------------------ // // This code was generated by a tool. @@ -49,7 +49,23 @@ namespace Damage_Calculator { #line hidden - #line 34 "..\..\MainWindow.xaml" + #line 36 "..\..\MainWindow.xaml" + [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] + internal System.Windows.Controls.RadioButton radioModeShooting; + + #line default + #line hidden + + + #line 37 "..\..\MainWindow.xaml" + [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] + internal System.Windows.Controls.RadioButton radioModeBomb; + + #line default + #line hidden + + + #line 39 "..\..\MainWindow.xaml" [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] internal System.Windows.Controls.StackPanel topStackPanel; @@ -57,7 +73,7 @@ namespace Damage_Calculator { #line hidden - #line 36 "..\..\MainWindow.xaml" + #line 41 "..\..\MainWindow.xaml" [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] internal System.Windows.Controls.ComboBox comboBoxMaps; @@ -65,7 +81,7 @@ namespace Damage_Calculator { #line hidden - #line 41 "..\..\MainWindow.xaml" + #line 46 "..\..\MainWindow.xaml" [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] internal System.Windows.Controls.TextBlock txtEasterEggMetres; @@ -73,7 +89,7 @@ namespace Damage_Calculator { #line hidden - #line 42 "..\..\MainWindow.xaml" + #line 47 "..\..\MainWindow.xaml" [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] internal System.Windows.Controls.TextBlock textDistanceMetres; @@ -81,7 +97,7 @@ namespace Damage_Calculator { #line hidden - #line 46 "..\..\MainWindow.xaml" + #line 51 "..\..\MainWindow.xaml" [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] internal System.Windows.Controls.TextBlock textDistanceUnits; @@ -89,7 +105,7 @@ namespace Damage_Calculator { #line hidden - #line 49 "..\..\MainWindow.xaml" + #line 54 "..\..\MainWindow.xaml" [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] internal System.Windows.Shapes.Rectangle rectTop; @@ -97,7 +113,7 @@ namespace Damage_Calculator { #line hidden - #line 50 "..\..\MainWindow.xaml" + #line 55 "..\..\MainWindow.xaml" [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] internal System.Windows.Shapes.Rectangle rectSide; @@ -105,7 +121,7 @@ namespace Damage_Calculator { #line hidden - #line 51 "..\..\MainWindow.xaml" + #line 56 "..\..\MainWindow.xaml" [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] internal System.Windows.Controls.StackPanel leftStackPanel; @@ -113,25 +129,9 @@ namespace Damage_Calculator { #line hidden - #line 55 "..\..\MainWindow.xaml" - [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] - internal System.Windows.Controls.CheckBox chkHelmet; - - #line default - #line hidden - - - #line 56 "..\..\MainWindow.xaml" - [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] - internal System.Windows.Controls.CheckBox chkKevlar; - - #line default - #line hidden - - #line 60 "..\..\MainWindow.xaml" [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] - internal System.Windows.Controls.RadioButton radioHead; + internal System.Windows.Controls.StackPanel stackArmorSeparated; #line default #line hidden @@ -139,7 +139,7 @@ namespace Damage_Calculator { #line 61 "..\..\MainWindow.xaml" [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] - internal System.Windows.Controls.RadioButton radioChestArms; + internal System.Windows.Controls.CheckBox chkHelmet; #line default #line hidden @@ -147,39 +147,79 @@ namespace Damage_Calculator { #line 62 "..\..\MainWindow.xaml" [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] + internal System.Windows.Controls.CheckBox chkKevlar; + + #line default + #line hidden + + + #line 64 "..\..\MainWindow.xaml" + [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] + internal System.Windows.Controls.CheckBox chkArmorAny; + + #line default + #line hidden + + + #line 66 "..\..\MainWindow.xaml" + [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] + internal System.Windows.Controls.StackPanel stackAreaHit; + + #line default + #line hidden + + + #line 68 "..\..\MainWindow.xaml" + [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] + internal System.Windows.Controls.RadioButton radioHead; + + #line default + #line hidden + + + #line 69 "..\..\MainWindow.xaml" + [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] + internal System.Windows.Controls.RadioButton radioChestArms; + + #line default + #line hidden + + + #line 70 "..\..\MainWindow.xaml" + [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] internal System.Windows.Controls.RadioButton radioStomach; #line default #line hidden - #line 63 "..\..\MainWindow.xaml" - [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] - internal System.Windows.Controls.RadioButton radioLegs; - - #line default - #line hidden - - - #line 67 "..\..\MainWindow.xaml" - [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] - internal System.Windows.Controls.ComboBox comboWeapons; - - #line default - #line hidden - - #line 71 "..\..\MainWindow.xaml" [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] - internal System.Windows.Controls.TextBlock txtResult; + internal System.Windows.Controls.RadioButton radioLegs; #line default #line hidden - #line 72 "..\..\MainWindow.xaml" + #line 73 "..\..\MainWindow.xaml" [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] - internal System.Windows.Controls.TextBlock txtResultArmor; + internal System.Windows.Controls.StackPanel stackWeaponUsed; + + #line default + #line hidden + + + #line 75 "..\..\MainWindow.xaml" + [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] + internal System.Windows.Controls.ComboBox comboWeapons; + + #line default + #line hidden + + + #line 79 "..\..\MainWindow.xaml" + [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] + internal System.Windows.Controls.TextBlock txtResult; #line default #line hidden @@ -187,23 +227,7 @@ namespace Damage_Calculator { #line 80 "..\..\MainWindow.xaml" [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] - internal System.Windows.Controls.TextBlock txtCursorX; - - #line default - #line hidden - - - #line 84 "..\..\MainWindow.xaml" - [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] - internal System.Windows.Controls.TextBlock txtCursorY; - - #line default - #line hidden - - - #line 87 "..\..\MainWindow.xaml" - [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] - internal System.Windows.Controls.Grid rightGrid; + internal System.Windows.Controls.TextBlock txtResultArmor; #line default #line hidden @@ -211,13 +235,37 @@ namespace Damage_Calculator { #line 88 "..\..\MainWindow.xaml" [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] + internal System.Windows.Controls.TextBlock txtCursorX; + + #line default + #line hidden + + + #line 92 "..\..\MainWindow.xaml" + [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] + internal System.Windows.Controls.TextBlock txtCursorY; + + #line default + #line hidden + + + #line 95 "..\..\MainWindow.xaml" + [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] + internal System.Windows.Controls.Grid rightGrid; + + #line default + #line hidden + + + #line 96 "..\..\MainWindow.xaml" + [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] internal System.Windows.Controls.Image mapImage; #line default #line hidden - #line 89 "..\..\MainWindow.xaml" + #line 97 "..\..\MainWindow.xaml" [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] internal System.Windows.Controls.Canvas pointsCanvas; @@ -225,7 +273,7 @@ namespace Damage_Calculator { #line hidden - #line 92 "..\..\MainWindow.xaml" + #line 100 "..\..\MainWindow.xaml" [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] internal System.Windows.Controls.Grid gridLoading; @@ -302,150 +350,192 @@ namespace Damage_Calculator { #line hidden return; case 5: - this.topStackPanel = ((System.Windows.Controls.StackPanel)(target)); - return; - case 6: - this.comboBoxMaps = ((System.Windows.Controls.ComboBox)(target)); + this.radioModeShooting = ((System.Windows.Controls.RadioButton)(target)); #line 36 "..\..\MainWindow.xaml" - this.comboBoxMaps.SelectionChanged += new System.Windows.Controls.SelectionChangedEventHandler(this.comboBoxMaps_SelectionChanged); + this.radioModeShooting.Checked += new System.Windows.RoutedEventHandler(this.radioModeShooting_Checked); + + #line default + #line hidden + return; + case 6: + this.radioModeBomb = ((System.Windows.Controls.RadioButton)(target)); + + #line 37 "..\..\MainWindow.xaml" + this.radioModeBomb.Checked += new System.Windows.RoutedEventHandler(this.radioModeBomb_Checked); #line default #line hidden return; case 7: - this.txtEasterEggMetres = ((System.Windows.Controls.TextBlock)(target)); + this.topStackPanel = ((System.Windows.Controls.StackPanel)(target)); return; case 8: - this.textDistanceMetres = ((System.Windows.Controls.TextBlock)(target)); + this.comboBoxMaps = ((System.Windows.Controls.ComboBox)(target)); + + #line 41 "..\..\MainWindow.xaml" + this.comboBoxMaps.SelectionChanged += new System.Windows.Controls.SelectionChangedEventHandler(this.comboBoxMaps_SelectionChanged); + + #line default + #line hidden return; case 9: - this.textDistanceUnits = ((System.Windows.Controls.TextBlock)(target)); + this.txtEasterEggMetres = ((System.Windows.Controls.TextBlock)(target)); return; case 10: - this.rectTop = ((System.Windows.Shapes.Rectangle)(target)); + this.textDistanceMetres = ((System.Windows.Controls.TextBlock)(target)); return; case 11: - this.rectSide = ((System.Windows.Shapes.Rectangle)(target)); + this.textDistanceUnits = ((System.Windows.Controls.TextBlock)(target)); return; case 12: - this.leftStackPanel = ((System.Windows.Controls.StackPanel)(target)); + this.rectTop = ((System.Windows.Shapes.Rectangle)(target)); return; case 13: + this.rectSide = ((System.Windows.Shapes.Rectangle)(target)); + return; + case 14: + this.leftStackPanel = ((System.Windows.Controls.StackPanel)(target)); + return; + case 15: + this.stackArmorSeparated = ((System.Windows.Controls.StackPanel)(target)); + return; + case 16: this.chkHelmet = ((System.Windows.Controls.CheckBox)(target)); - #line 55 "..\..\MainWindow.xaml" + #line 61 "..\..\MainWindow.xaml" this.chkHelmet.Checked += new System.Windows.RoutedEventHandler(this.settings_Updated); #line default #line hidden - #line 55 "..\..\MainWindow.xaml" + #line 61 "..\..\MainWindow.xaml" this.chkHelmet.Unchecked += new System.Windows.RoutedEventHandler(this.settings_Updated); #line default #line hidden return; - case 14: + case 17: this.chkKevlar = ((System.Windows.Controls.CheckBox)(target)); - #line 56 "..\..\MainWindow.xaml" + #line 62 "..\..\MainWindow.xaml" this.chkKevlar.Checked += new System.Windows.RoutedEventHandler(this.settings_Updated); #line default #line hidden - #line 56 "..\..\MainWindow.xaml" + #line 62 "..\..\MainWindow.xaml" this.chkKevlar.Unchecked += new System.Windows.RoutedEventHandler(this.settings_Updated); - #line default - #line hidden - return; - case 15: - this.radioHead = ((System.Windows.Controls.RadioButton)(target)); - - #line 60 "..\..\MainWindow.xaml" - this.radioHead.Checked += new System.Windows.RoutedEventHandler(this.settings_Updated); - - #line default - #line hidden - return; - case 16: - this.radioChestArms = ((System.Windows.Controls.RadioButton)(target)); - - #line 61 "..\..\MainWindow.xaml" - this.radioChestArms.Checked += new System.Windows.RoutedEventHandler(this.settings_Updated); - - #line default - #line hidden - return; - case 17: - this.radioStomach = ((System.Windows.Controls.RadioButton)(target)); - - #line 62 "..\..\MainWindow.xaml" - this.radioStomach.Checked += new System.Windows.RoutedEventHandler(this.settings_Updated); - #line default #line hidden return; case 18: - this.radioLegs = ((System.Windows.Controls.RadioButton)(target)); + this.chkArmorAny = ((System.Windows.Controls.CheckBox)(target)); - #line 63 "..\..\MainWindow.xaml" - this.radioLegs.Checked += new System.Windows.RoutedEventHandler(this.settings_Updated); + #line 64 "..\..\MainWindow.xaml" + this.chkArmorAny.Checked += new System.Windows.RoutedEventHandler(this.settings_Updated); + + #line default + #line hidden + + #line 64 "..\..\MainWindow.xaml" + this.chkArmorAny.Unchecked += new System.Windows.RoutedEventHandler(this.settings_Updated); #line default #line hidden return; case 19: + this.stackAreaHit = ((System.Windows.Controls.StackPanel)(target)); + return; + case 20: + this.radioHead = ((System.Windows.Controls.RadioButton)(target)); + + #line 68 "..\..\MainWindow.xaml" + this.radioHead.Checked += new System.Windows.RoutedEventHandler(this.settings_Updated); + + #line default + #line hidden + return; + case 21: + this.radioChestArms = ((System.Windows.Controls.RadioButton)(target)); + + #line 69 "..\..\MainWindow.xaml" + this.radioChestArms.Checked += new System.Windows.RoutedEventHandler(this.settings_Updated); + + #line default + #line hidden + return; + case 22: + this.radioStomach = ((System.Windows.Controls.RadioButton)(target)); + + #line 70 "..\..\MainWindow.xaml" + this.radioStomach.Checked += new System.Windows.RoutedEventHandler(this.settings_Updated); + + #line default + #line hidden + return; + case 23: + this.radioLegs = ((System.Windows.Controls.RadioButton)(target)); + + #line 71 "..\..\MainWindow.xaml" + this.radioLegs.Checked += new System.Windows.RoutedEventHandler(this.settings_Updated); + + #line default + #line hidden + return; + case 24: + this.stackWeaponUsed = ((System.Windows.Controls.StackPanel)(target)); + return; + case 25: this.comboWeapons = ((System.Windows.Controls.ComboBox)(target)); - #line 67 "..\..\MainWindow.xaml" + #line 75 "..\..\MainWindow.xaml" this.comboWeapons.SelectionChanged += new System.Windows.Controls.SelectionChangedEventHandler(this.comboWeapons_SelectionChanged); #line default #line hidden return; - case 20: + case 26: this.txtResult = ((System.Windows.Controls.TextBlock)(target)); return; - case 21: + case 27: this.txtResultArmor = ((System.Windows.Controls.TextBlock)(target)); return; - case 22: + case 28: this.txtCursorX = ((System.Windows.Controls.TextBlock)(target)); return; - case 23: + case 29: this.txtCursorY = ((System.Windows.Controls.TextBlock)(target)); return; - case 24: + case 30: this.rightGrid = ((System.Windows.Controls.Grid)(target)); return; - case 25: + case 31: this.mapImage = ((System.Windows.Controls.Image)(target)); - #line 88 "..\..\MainWindow.xaml" + #line 96 "..\..\MainWindow.xaml" this.mapImage.MouseLeftButtonUp += new System.Windows.Input.MouseButtonEventHandler(this.mapImage_MouseLeftButtonUp); #line default #line hidden - #line 88 "..\..\MainWindow.xaml" + #line 96 "..\..\MainWindow.xaml" this.mapImage.MouseRightButtonUp += new System.Windows.Input.MouseButtonEventHandler(this.mapImage_MouseRightButtonUp); #line default #line hidden - #line 88 "..\..\MainWindow.xaml" + #line 96 "..\..\MainWindow.xaml" this.mapImage.LayoutUpdated += new System.EventHandler(this.mapImage_LayoutUpdated); #line default #line hidden return; - case 26: + case 32: this.pointsCanvas = ((System.Windows.Controls.Canvas)(target)); return; - case 27: + case 33: this.gridLoading = ((System.Windows.Controls.Grid)(target)); return; } diff --git a/DamageCalculator/DamageCalculator/obj/Debug/MainWindow.g.i.cs b/DamageCalculator/DamageCalculator/obj/Debug/MainWindow.g.i.cs index 17544ba..a64f0db 100644 --- a/DamageCalculator/DamageCalculator/obj/Debug/MainWindow.g.i.cs +++ b/DamageCalculator/DamageCalculator/obj/Debug/MainWindow.g.i.cs @@ -1,4 +1,4 @@ -#pragma checksum "..\..\MainWindow.xaml" "{8829d00f-11b8-4213-878b-770e8597ac16}" "ED5BBC5CC0EF7E0364C4C9F7606BFAD438DA441A3D87364DB6EA1B2DD7DB2529" +#pragma checksum "..\..\MainWindow.xaml" "{8829d00f-11b8-4213-878b-770e8597ac16}" "7FEF1C1C14931282E3CD4C845E600884ED2172B171609E698A3BF061C58787F7" //------------------------------------------------------------------------------ // // This code was generated by a tool. @@ -49,7 +49,23 @@ namespace Damage_Calculator { #line hidden - #line 34 "..\..\MainWindow.xaml" + #line 36 "..\..\MainWindow.xaml" + [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] + internal System.Windows.Controls.RadioButton radioModeShooting; + + #line default + #line hidden + + + #line 37 "..\..\MainWindow.xaml" + [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] + internal System.Windows.Controls.RadioButton radioModeBomb; + + #line default + #line hidden + + + #line 39 "..\..\MainWindow.xaml" [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] internal System.Windows.Controls.StackPanel topStackPanel; @@ -57,7 +73,7 @@ namespace Damage_Calculator { #line hidden - #line 36 "..\..\MainWindow.xaml" + #line 41 "..\..\MainWindow.xaml" [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] internal System.Windows.Controls.ComboBox comboBoxMaps; @@ -65,7 +81,7 @@ namespace Damage_Calculator { #line hidden - #line 41 "..\..\MainWindow.xaml" + #line 46 "..\..\MainWindow.xaml" [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] internal System.Windows.Controls.TextBlock txtEasterEggMetres; @@ -73,7 +89,7 @@ namespace Damage_Calculator { #line hidden - #line 42 "..\..\MainWindow.xaml" + #line 47 "..\..\MainWindow.xaml" [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] internal System.Windows.Controls.TextBlock textDistanceMetres; @@ -81,7 +97,7 @@ namespace Damage_Calculator { #line hidden - #line 46 "..\..\MainWindow.xaml" + #line 51 "..\..\MainWindow.xaml" [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] internal System.Windows.Controls.TextBlock textDistanceUnits; @@ -89,7 +105,7 @@ namespace Damage_Calculator { #line hidden - #line 49 "..\..\MainWindow.xaml" + #line 54 "..\..\MainWindow.xaml" [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] internal System.Windows.Shapes.Rectangle rectTop; @@ -97,7 +113,7 @@ namespace Damage_Calculator { #line hidden - #line 50 "..\..\MainWindow.xaml" + #line 55 "..\..\MainWindow.xaml" [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] internal System.Windows.Shapes.Rectangle rectSide; @@ -105,7 +121,7 @@ namespace Damage_Calculator { #line hidden - #line 51 "..\..\MainWindow.xaml" + #line 56 "..\..\MainWindow.xaml" [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] internal System.Windows.Controls.StackPanel leftStackPanel; @@ -113,25 +129,9 @@ namespace Damage_Calculator { #line hidden - #line 55 "..\..\MainWindow.xaml" - [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] - internal System.Windows.Controls.CheckBox chkHelmet; - - #line default - #line hidden - - - #line 56 "..\..\MainWindow.xaml" - [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] - internal System.Windows.Controls.CheckBox chkKevlar; - - #line default - #line hidden - - #line 60 "..\..\MainWindow.xaml" [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] - internal System.Windows.Controls.RadioButton radioHead; + internal System.Windows.Controls.StackPanel stackArmorSeparated; #line default #line hidden @@ -139,7 +139,7 @@ namespace Damage_Calculator { #line 61 "..\..\MainWindow.xaml" [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] - internal System.Windows.Controls.RadioButton radioChestArms; + internal System.Windows.Controls.CheckBox chkHelmet; #line default #line hidden @@ -147,39 +147,79 @@ namespace Damage_Calculator { #line 62 "..\..\MainWindow.xaml" [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] + internal System.Windows.Controls.CheckBox chkKevlar; + + #line default + #line hidden + + + #line 64 "..\..\MainWindow.xaml" + [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] + internal System.Windows.Controls.CheckBox chkArmorAny; + + #line default + #line hidden + + + #line 66 "..\..\MainWindow.xaml" + [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] + internal System.Windows.Controls.StackPanel stackAreaHit; + + #line default + #line hidden + + + #line 68 "..\..\MainWindow.xaml" + [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] + internal System.Windows.Controls.RadioButton radioHead; + + #line default + #line hidden + + + #line 69 "..\..\MainWindow.xaml" + [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] + internal System.Windows.Controls.RadioButton radioChestArms; + + #line default + #line hidden + + + #line 70 "..\..\MainWindow.xaml" + [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] internal System.Windows.Controls.RadioButton radioStomach; #line default #line hidden - #line 63 "..\..\MainWindow.xaml" - [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] - internal System.Windows.Controls.RadioButton radioLegs; - - #line default - #line hidden - - - #line 67 "..\..\MainWindow.xaml" - [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] - internal System.Windows.Controls.ComboBox comboWeapons; - - #line default - #line hidden - - #line 71 "..\..\MainWindow.xaml" [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] - internal System.Windows.Controls.TextBlock txtResult; + internal System.Windows.Controls.RadioButton radioLegs; #line default #line hidden - #line 72 "..\..\MainWindow.xaml" + #line 73 "..\..\MainWindow.xaml" [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] - internal System.Windows.Controls.TextBlock txtResultArmor; + internal System.Windows.Controls.StackPanel stackWeaponUsed; + + #line default + #line hidden + + + #line 75 "..\..\MainWindow.xaml" + [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] + internal System.Windows.Controls.ComboBox comboWeapons; + + #line default + #line hidden + + + #line 79 "..\..\MainWindow.xaml" + [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] + internal System.Windows.Controls.TextBlock txtResult; #line default #line hidden @@ -187,23 +227,7 @@ namespace Damage_Calculator { #line 80 "..\..\MainWindow.xaml" [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] - internal System.Windows.Controls.TextBlock txtCursorX; - - #line default - #line hidden - - - #line 84 "..\..\MainWindow.xaml" - [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] - internal System.Windows.Controls.TextBlock txtCursorY; - - #line default - #line hidden - - - #line 87 "..\..\MainWindow.xaml" - [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] - internal System.Windows.Controls.Grid rightGrid; + internal System.Windows.Controls.TextBlock txtResultArmor; #line default #line hidden @@ -211,13 +235,37 @@ namespace Damage_Calculator { #line 88 "..\..\MainWindow.xaml" [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] + internal System.Windows.Controls.TextBlock txtCursorX; + + #line default + #line hidden + + + #line 92 "..\..\MainWindow.xaml" + [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] + internal System.Windows.Controls.TextBlock txtCursorY; + + #line default + #line hidden + + + #line 95 "..\..\MainWindow.xaml" + [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] + internal System.Windows.Controls.Grid rightGrid; + + #line default + #line hidden + + + #line 96 "..\..\MainWindow.xaml" + [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] internal System.Windows.Controls.Image mapImage; #line default #line hidden - #line 89 "..\..\MainWindow.xaml" + #line 97 "..\..\MainWindow.xaml" [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] internal System.Windows.Controls.Canvas pointsCanvas; @@ -225,7 +273,7 @@ namespace Damage_Calculator { #line hidden - #line 92 "..\..\MainWindow.xaml" + #line 100 "..\..\MainWindow.xaml" [System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")] internal System.Windows.Controls.Grid gridLoading; @@ -302,150 +350,192 @@ namespace Damage_Calculator { #line hidden return; case 5: - this.topStackPanel = ((System.Windows.Controls.StackPanel)(target)); - return; - case 6: - this.comboBoxMaps = ((System.Windows.Controls.ComboBox)(target)); + this.radioModeShooting = ((System.Windows.Controls.RadioButton)(target)); #line 36 "..\..\MainWindow.xaml" - this.comboBoxMaps.SelectionChanged += new System.Windows.Controls.SelectionChangedEventHandler(this.comboBoxMaps_SelectionChanged); + this.radioModeShooting.Checked += new System.Windows.RoutedEventHandler(this.radioModeShooting_Checked); + + #line default + #line hidden + return; + case 6: + this.radioModeBomb = ((System.Windows.Controls.RadioButton)(target)); + + #line 37 "..\..\MainWindow.xaml" + this.radioModeBomb.Checked += new System.Windows.RoutedEventHandler(this.radioModeBomb_Checked); #line default #line hidden return; case 7: - this.txtEasterEggMetres = ((System.Windows.Controls.TextBlock)(target)); + this.topStackPanel = ((System.Windows.Controls.StackPanel)(target)); return; case 8: - this.textDistanceMetres = ((System.Windows.Controls.TextBlock)(target)); + this.comboBoxMaps = ((System.Windows.Controls.ComboBox)(target)); + + #line 41 "..\..\MainWindow.xaml" + this.comboBoxMaps.SelectionChanged += new System.Windows.Controls.SelectionChangedEventHandler(this.comboBoxMaps_SelectionChanged); + + #line default + #line hidden return; case 9: - this.textDistanceUnits = ((System.Windows.Controls.TextBlock)(target)); + this.txtEasterEggMetres = ((System.Windows.Controls.TextBlock)(target)); return; case 10: - this.rectTop = ((System.Windows.Shapes.Rectangle)(target)); + this.textDistanceMetres = ((System.Windows.Controls.TextBlock)(target)); return; case 11: - this.rectSide = ((System.Windows.Shapes.Rectangle)(target)); + this.textDistanceUnits = ((System.Windows.Controls.TextBlock)(target)); return; case 12: - this.leftStackPanel = ((System.Windows.Controls.StackPanel)(target)); + this.rectTop = ((System.Windows.Shapes.Rectangle)(target)); return; case 13: + this.rectSide = ((System.Windows.Shapes.Rectangle)(target)); + return; + case 14: + this.leftStackPanel = ((System.Windows.Controls.StackPanel)(target)); + return; + case 15: + this.stackArmorSeparated = ((System.Windows.Controls.StackPanel)(target)); + return; + case 16: this.chkHelmet = ((System.Windows.Controls.CheckBox)(target)); - #line 55 "..\..\MainWindow.xaml" + #line 61 "..\..\MainWindow.xaml" this.chkHelmet.Checked += new System.Windows.RoutedEventHandler(this.settings_Updated); #line default #line hidden - #line 55 "..\..\MainWindow.xaml" + #line 61 "..\..\MainWindow.xaml" this.chkHelmet.Unchecked += new System.Windows.RoutedEventHandler(this.settings_Updated); #line default #line hidden return; - case 14: + case 17: this.chkKevlar = ((System.Windows.Controls.CheckBox)(target)); - #line 56 "..\..\MainWindow.xaml" + #line 62 "..\..\MainWindow.xaml" this.chkKevlar.Checked += new System.Windows.RoutedEventHandler(this.settings_Updated); #line default #line hidden - #line 56 "..\..\MainWindow.xaml" + #line 62 "..\..\MainWindow.xaml" this.chkKevlar.Unchecked += new System.Windows.RoutedEventHandler(this.settings_Updated); - #line default - #line hidden - return; - case 15: - this.radioHead = ((System.Windows.Controls.RadioButton)(target)); - - #line 60 "..\..\MainWindow.xaml" - this.radioHead.Checked += new System.Windows.RoutedEventHandler(this.settings_Updated); - - #line default - #line hidden - return; - case 16: - this.radioChestArms = ((System.Windows.Controls.RadioButton)(target)); - - #line 61 "..\..\MainWindow.xaml" - this.radioChestArms.Checked += new System.Windows.RoutedEventHandler(this.settings_Updated); - - #line default - #line hidden - return; - case 17: - this.radioStomach = ((System.Windows.Controls.RadioButton)(target)); - - #line 62 "..\..\MainWindow.xaml" - this.radioStomach.Checked += new System.Windows.RoutedEventHandler(this.settings_Updated); - #line default #line hidden return; case 18: - this.radioLegs = ((System.Windows.Controls.RadioButton)(target)); + this.chkArmorAny = ((System.Windows.Controls.CheckBox)(target)); - #line 63 "..\..\MainWindow.xaml" - this.radioLegs.Checked += new System.Windows.RoutedEventHandler(this.settings_Updated); + #line 64 "..\..\MainWindow.xaml" + this.chkArmorAny.Checked += new System.Windows.RoutedEventHandler(this.settings_Updated); + + #line default + #line hidden + + #line 64 "..\..\MainWindow.xaml" + this.chkArmorAny.Unchecked += new System.Windows.RoutedEventHandler(this.settings_Updated); #line default #line hidden return; case 19: + this.stackAreaHit = ((System.Windows.Controls.StackPanel)(target)); + return; + case 20: + this.radioHead = ((System.Windows.Controls.RadioButton)(target)); + + #line 68 "..\..\MainWindow.xaml" + this.radioHead.Checked += new System.Windows.RoutedEventHandler(this.settings_Updated); + + #line default + #line hidden + return; + case 21: + this.radioChestArms = ((System.Windows.Controls.RadioButton)(target)); + + #line 69 "..\..\MainWindow.xaml" + this.radioChestArms.Checked += new System.Windows.RoutedEventHandler(this.settings_Updated); + + #line default + #line hidden + return; + case 22: + this.radioStomach = ((System.Windows.Controls.RadioButton)(target)); + + #line 70 "..\..\MainWindow.xaml" + this.radioStomach.Checked += new System.Windows.RoutedEventHandler(this.settings_Updated); + + #line default + #line hidden + return; + case 23: + this.radioLegs = ((System.Windows.Controls.RadioButton)(target)); + + #line 71 "..\..\MainWindow.xaml" + this.radioLegs.Checked += new System.Windows.RoutedEventHandler(this.settings_Updated); + + #line default + #line hidden + return; + case 24: + this.stackWeaponUsed = ((System.Windows.Controls.StackPanel)(target)); + return; + case 25: this.comboWeapons = ((System.Windows.Controls.ComboBox)(target)); - #line 67 "..\..\MainWindow.xaml" + #line 75 "..\..\MainWindow.xaml" this.comboWeapons.SelectionChanged += new System.Windows.Controls.SelectionChangedEventHandler(this.comboWeapons_SelectionChanged); #line default #line hidden return; - case 20: + case 26: this.txtResult = ((System.Windows.Controls.TextBlock)(target)); return; - case 21: + case 27: this.txtResultArmor = ((System.Windows.Controls.TextBlock)(target)); return; - case 22: + case 28: this.txtCursorX = ((System.Windows.Controls.TextBlock)(target)); return; - case 23: + case 29: this.txtCursorY = ((System.Windows.Controls.TextBlock)(target)); return; - case 24: + case 30: this.rightGrid = ((System.Windows.Controls.Grid)(target)); return; - case 25: + case 31: this.mapImage = ((System.Windows.Controls.Image)(target)); - #line 88 "..\..\MainWindow.xaml" + #line 96 "..\..\MainWindow.xaml" this.mapImage.MouseLeftButtonUp += new System.Windows.Input.MouseButtonEventHandler(this.mapImage_MouseLeftButtonUp); #line default #line hidden - #line 88 "..\..\MainWindow.xaml" + #line 96 "..\..\MainWindow.xaml" this.mapImage.MouseRightButtonUp += new System.Windows.Input.MouseButtonEventHandler(this.mapImage_MouseRightButtonUp); #line default #line hidden - #line 88 "..\..\MainWindow.xaml" + #line 96 "..\..\MainWindow.xaml" this.mapImage.LayoutUpdated += new System.EventHandler(this.mapImage_LayoutUpdated); #line default #line hidden return; - case 26: + case 32: this.pointsCanvas = ((System.Windows.Controls.Canvas)(target)); return; - case 27: + case 33: this.gridLoading = ((System.Windows.Controls.Grid)(target)); return; } diff --git a/DamageCalculator/DamageCalculator/obj/Debug/Themes/ColourfulDarkTheme.baml b/DamageCalculator/DamageCalculator/obj/Debug/Themes/ColourfulDarkTheme.baml index 7fa35f0..dfbf7bb 100644 Binary files a/DamageCalculator/DamageCalculator/obj/Debug/Themes/ColourfulDarkTheme.baml and b/DamageCalculator/DamageCalculator/obj/Debug/Themes/ColourfulDarkTheme.baml differ diff --git a/DamageCalculator/DamageCalculator/obj/Debug/Themes/ColourfulLightTheme.baml b/DamageCalculator/DamageCalculator/obj/Debug/Themes/ColourfulLightTheme.baml index 8cb5886..e71b432 100644 Binary files a/DamageCalculator/DamageCalculator/obj/Debug/Themes/ColourfulLightTheme.baml and b/DamageCalculator/DamageCalculator/obj/Debug/Themes/ColourfulLightTheme.baml differ diff --git a/DamageCalculator/DamageCalculator/obj/Debug/Themes/DarkTheme.baml b/DamageCalculator/DamageCalculator/obj/Debug/Themes/DarkTheme.baml index 47b5d29..77c1169 100644 Binary files a/DamageCalculator/DamageCalculator/obj/Debug/Themes/DarkTheme.baml and b/DamageCalculator/DamageCalculator/obj/Debug/Themes/DarkTheme.baml differ diff --git a/DamageCalculator/DamageCalculator/obj/Debug/Themes/LightTheme.baml b/DamageCalculator/DamageCalculator/obj/Debug/Themes/LightTheme.baml index 94d1d36..2961098 100644 Binary files a/DamageCalculator/DamageCalculator/obj/Debug/Themes/LightTheme.baml and b/DamageCalculator/DamageCalculator/obj/Debug/Themes/LightTheme.baml differ