Ejemplo n.º 1
0
 private void character_CalculationsInvalidated(object sender, EventArgs e)
 {
     if (BossOptions == null)
     {
         return;
     }
     TB_BossInfo.Text = BossOptions.GenInfoString(Character);
 }
Ejemplo n.º 2
0
 public void bossOpts_PropertyChanged(object sender, PropertyChangedEventArgs e)
 {
     if (isLoading)
     {
         return;
     }
     isLoading = true;
     // Basics
     CB_Level.SelectedItem          = BossOptions.Level;
     CB_Armor.SelectedItem          = BossOptions.Armor;
     NUD_Duration.Value             = BossOptions.BerserkTimer;
     NUD_DurationSpeed.Value        = BossOptions.SpeedKillTimer;
     NUD_TargHP.Value               = BossOptions.Health;
     NUD_Under35Perc.Value          = BossOptions.Under35Perc * 100;
     NUD_Under20Perc.Value          = BossOptions.Under20Perc * 100;
     CB_InBackPerc_Melee.IsEnabled  = (bool)(CK_InBack.IsChecked = BossOptions.InBack);
     CB_InBackPerc_Melee.Value      = BossOptions.InBackPerc_Melee * 100d;
     CB_InBackPerc_Ranged.IsEnabled = (bool)(CK_InBack.IsChecked = BossOptions.InBack);
     CB_InBackPerc_Ranged.Value     = BossOptions.InBackPerc_Ranged * 100d;
     CB_MaxPlayers.SelectedItem     = BossOptions.Max_Players;
     CB_MinTanks.SelectedItem       = BossOptions.Min_Tanks;
     CB_MinHealers.SelectedItem     = BossOptions.Min_Healers;
     // Offensive
     BT_MultiTargs.IsEnabled = (bool)(CK_MultiTargs.IsChecked = BossOptions.MultiTargs);
     BT_MultiTargs.Content   = BossOptions.DynamicCompiler_MultiTargs.ToString();
     BT_Attacks.IsEnabled    = (bool)(CK_Attacks.IsChecked = BossOptions.DamagingTargs);
     BT_Attacks.Content      = BossOptions.DynamicCompiler_Attacks.ToString();
     // Defensive
     NUD_Resist_Physical.Value = BossOptions.Resist_Physical * 100d;
     NUD_Resist_Frost.Value    = BossOptions.Resist_Frost * 100d;
     NUD_Resist_Fire.Value     = BossOptions.Resist_Fire * 100d;
     NUD_Resist_Nature.Value   = BossOptions.Resist_Nature * 100d;
     NUD_Resist_Arcane.Value   = BossOptions.Resist_Arcane * 100d;
     NUD_Resist_Shadow.Value   = BossOptions.Resist_Shadow * 100d;
     NUD_Resist_Holy.Value     = BossOptions.Resist_Holy * 100d;
     // The Impedance Checks
     BT_Moves.IsEnabled   = (bool)(CK_MovingTargs.IsChecked = BossOptions.MovingTargs);
     BT_Stuns.IsEnabled   = (bool)(CK_StunningTargs.IsChecked = BossOptions.StunningTargs);
     BT_Fears.IsEnabled   = (bool)(CK_FearingTargs.IsChecked = BossOptions.FearingTargs);
     BT_Roots.IsEnabled   = (bool)(CK_RootingTargs.IsChecked = BossOptions.RootingTargs);
     BT_Disarms.IsEnabled = (bool)(CK_DisarmTargs.IsChecked = BossOptions.DisarmingTargs);
     // The Impedance Buttons
     BT_Stuns.Content   = BossOptions.DynamicCompiler_Stun.ToString();
     BT_Moves.Content   = BossOptions.DynamicCompiler_Move.ToString();
     BT_Fears.Content   = BossOptions.DynamicCompiler_Fear.ToString();
     BT_Roots.Content   = BossOptions.DynamicCompiler_Root.ToString();
     BT_Disarms.Content = BossOptions.DynamicCompiler_Disarm.ToString();
     // Summary
     TB_BossInfo.Text = BossOptions.GenInfoString(Character);
     //
     if (CB_BossList.SelectedIndex == -1)
     {
         CB_BossList.SelectedIndex = 0;
     }                                                                       // Sets it to Custom
     isLoading = false;
     //
     Character.OnCalculationsInvalidated();
 }
Ejemplo n.º 3
0
 public void bossOpts_PropertyChanged(object sender, PropertyChangedEventArgs e)
 {
     if (isLoading)
     {
         return;
     }
     isLoading = true;
     // Basics
     CB_Level.SelectedItem          = BossOptions.Level;
     CB_Armor.SelectedItem          = BossOptions.Armor;
     CB_MobType.SelectedIndex       = BossOptions.MobType;
     NUD_Duration.Value             = BossOptions.BerserkTimer;
     NUD_DurationSpeed.Value        = BossOptions.SpeedKillTimer;
     NUD_TargHP.Value               = BossOptions.Health;
     NUD_Under35Perc.Value          = BossOptions.Under35Perc * 100;
     NUD_Under20Perc.Value          = BossOptions.Under20Perc * 100;
     CB_InBackPerc_Melee.IsEnabled  = (bool)(CK_InBack.IsChecked = BossOptions.InBack);
     CB_InBackPerc_Melee.Value      = BossOptions.InBackPerc_Melee * 100d;
     CB_InBackPerc_Ranged.IsEnabled = (bool)(CK_InBack.IsChecked = BossOptions.InBack);
     CB_InBackPerc_Ranged.Value     = BossOptions.InBackPerc_Ranged * 100d;
     CB_MaxPlayers.SelectedItem     = BossOptions.Max_Players;
     CB_MinTanks.SelectedItem       = BossOptions.Min_Tanks;
     CB_MinHealers.SelectedItem     = BossOptions.Min_Healers;
     // Offensive
     BT_MultiTargs.IsEnabled = /*LB_MultiTargs.IsEnabled =*/ (bool)(CK_MultiTargs.IsChecked = (bool?)BossOptions.MultiTargs);
     BT_Attacks.IsEnabled    = /*LB_Attacks.IsEnabled =*/ (bool)(CK_Attacks.IsChecked = (bool?)BossOptions.DamagingTargs);
     BT_BuffStates.IsEnabled = /*LB_BuffStates.IsEnabled =*/ (bool)(CK_BuffStates.IsChecked = (bool?)BossOptions.HasBuffStates);
     LB_MultiTargs.Text      = BossOptions.DynamicString_MultiTargs.ToString();
     LB_Attacks.Text         = BossOptions.DynamicString_Attacks.ToString();
     LB_BuffStates.Text      = BossOptions.DynamicString_BuffStates.ToString();
     // Defensive
     NUD_Resist_Physical.Value = BossOptions.Resist_Physical * 100d;
     NUD_Resist_Frost.Value    = BossOptions.Resist_Frost * 100d;
     NUD_Resist_Fire.Value     = BossOptions.Resist_Fire * 100d;
     NUD_Resist_Nature.Value   = BossOptions.Resist_Nature * 100d;
     NUD_Resist_Arcane.Value   = BossOptions.Resist_Arcane * 100d;
     NUD_Resist_Shadow.Value   = BossOptions.Resist_Shadow * 100d;
     NUD_Resist_Holy.Value     = BossOptions.Resist_Holy * 100d;
     // The Impedance Checks
     BT_Stuns.IsEnabled = /*LB_Stuns.IsEnabled =*/ (bool)(CK_Stuns.IsChecked = BossOptions.StunningTargs);
     BT_Moves.IsEnabled = /*LB_Moves.IsEnabled =*/ (bool)(CK_Moves.IsChecked = BossOptions.MovingTargs);
     BT_Fears.IsEnabled = /*LB_Fears.IsEnabled =*/ (bool)(CK_Fears.IsChecked = BossOptions.FearingTargs);
     BT_Roots.IsEnabled = /*LB_Roots.IsEnabled =*/ (bool)(CK_Roots.IsChecked = BossOptions.RootingTargs);
     BT_Slncs.IsEnabled = /*LB_Slncs.IsEnabled =*/ (bool)(CK_Slncs.IsChecked = BossOptions.SilencingTargs);
     BT_Dsrms.IsEnabled = /*LB_Dsrms.IsEnabled =*/ (bool)(CK_Dsrms.IsChecked = BossOptions.DisarmingTargs);
     // The Impedance Buttons
     LB_Stuns.Text = BossOptions.DynamicString_Stun.ToString();
     LB_Moves.Text = BossOptions.DynamicString_Move.ToString();
     LB_Fears.Text = BossOptions.DynamicString_Fear.ToString();
     LB_Roots.Text = BossOptions.DynamicString_Root.ToString();
     LB_Slncs.Text = BossOptions.DynamicString_Slnc.ToString();
     LB_Dsrms.Text = BossOptions.DynamicString_Dsrm.ToString();
     // Summary
     TB_BossInfo.Text = BossOptions.GenInfoString(Character);
     if (origbrush == null)
     {
         origbrush = TB_BossInfo.Foreground;
     }
     if (TB_BossInfo.Text.Contains("ALERT"))
     {
         TB_BossInfo.Foreground = new SolidColorBrush(Colors.Red);
     }
     else
     {
         TB_BossInfo.Foreground = origbrush;
     }
     //
     if (CB_BossList.SelectedIndex == -1)
     {
         CB_BossList.SelectedIndex = 0;
     }                                                                       // Sets it to Custom
     isLoading = false;
     //
     Character.OnCalculationsInvalidated();
 }