Ejemplo n.º 1
0
        /// <summary>
        /// Applies a loaded value
        /// </summary>
        /// <param name="value">value</param>
        public void ApplyValue(Value value)
        {
            if (value.Key.Equals("Particle Amount Base") && value.Number > 0) {
                amountBaseBox.Text = value.Number.ToString();
            }
            else if (value.Key.Equals("Particle Amount Bonus") && value.Number >= 0) {
                amountBonusBox.Text = value.Number.ToString();
            }
            else if (value.Key.Equals("Particle Radius Base") && value.Number > 0) {
                radiusBaseBox.Text = value.Number.ToString();
            }
            else if (value.Key.Equals("Particle Radius Bonus") && value.Number >= 0) {
                RadiusBonusBox.Text = value.Number.ToString();
            }
            else if (value.Key.Equals("Particle Area") && value.Number >= 0 && value.Number < 3) {
                areaBox.SelectedIndex = value.Number;
            }
            else if (value.Key.Equals("Particle") && value.Number >= 0 && value.Number < typeBox.Items.Count) {
                typeBox.SelectedIndex = value.Number;
            }
            else if (value.Key.Equals("Particle Data")) {
                int num = value.Number;

                if (typeBox.SelectedIndex == 3) {
                    if (num > 13) num--;
                    if (num > 11) num--;
                    if (num > 7) num--;
                    num--;
                }

                if (num >= 0 && num < dataBox.Items.Count) {
                    dataBox.SelectedIndex = num;
                }
            }
        }
 /// <summary>
 /// Applies a loaded value
 /// </summary>
 /// <param name="value">value</param>
 public void ApplyValue(Value value)
 {
     if (value.Key.Equals("ManaType")) {
         if (typeBox.Items.Count > value.Number && value.Number >= 0) {
             typeBox.SelectedIndex = value.Number;
         }
     }
 }
 /// <summary>
 /// Applies a loaded value
 /// </summary>
 /// <param name="value">value</param>
 public void ApplyValue(Value value)
 {
     if (value.Key.Equals("ConditionKey")) {
         conditionBox.SelectedIndex = value.Number;
     }
     else if (value.Key.Equals("ConditionType")) {
         comparisonBox.SelectedIndex = value.Number;
     }
     else if (value.Key.Equals("ConditionValue")) {
         valueBox.Text = value.Number.ToString();
     }
 }
Ejemplo n.º 4
0
 /// <summary>
 /// Applies a loaded value
 /// </summary>
 /// <param name="value">value</param>
 public void ApplyValue(Value value)
 {
     if (value.Key.Equals("Cleanse")) {
         int n = value.Number;
         foreach (CheckBox box in optionGrid.Children) {
             if (n == 0) break;
             if (n % 2 == 1) {
                 box.IsChecked = true;
             }
             n /= 2;
         }
     }
 }
Ejemplo n.º 5
0
 /// <summary>
 /// Applies a loaded value
 /// </summary>
 /// <param name="value">value</param>
 public void ApplyValue(Value value)
 {
     if (value.Key.Equals("Sound")) {
         if (value.Number >= 0 && value.Number < typeBox.Items.Count) {
             typeBox.SelectedIndex = value.Number;
         }
     }
     else if (value.Key.Equals("Pitch")) {
         pitchBox.Text = value.Number.ToString();
     }
     else if (value.Key.Equals("Volume")) {
         volumeBox.Text = value.Number.ToString();
     }
 }
 /// <summary>
 /// Applies a loaded value
 /// </summary>
 /// <param name="value">value</param>
 public void ApplyValue(Value value)
 {
     if (value.Key.Equals("Condition")) {
         int n = value.Number;
         condition1.SelectedIndex = n % 256;
         n /= 256;
         operator1.SelectedIndex = n % 16;
         n /= 16;
         condition2.SelectedIndex = n % 256;
         n /= 256;
         operator2.SelectedIndex = n % 16;
         n /= 16;
         condition3.SelectedIndex = n;
     }
 }
 /// <summary>
 /// Applies a loaded value
 /// </summary>
 /// <param name="value">value</param>
 public void ApplyValue(Value value)
 {
     if (value.Key.Equals("Projectile")) {
         if (typeBox.Items.Count > value.Number - 1 && value.Number >= 0) {
             if (value.Number == typeBox.Items.Count) typeBox.SelectedIndex = typeBox.Items.Count - 1;
             else typeBox.SelectedIndex = value.Number;
         }
     }
     if (value.Key.Equals("Spread")) {
         if (typeBox.Items.Count > value.Number && value.Number >= 0) {
             spreadBox.SelectedIndex = value.Number;
         }
     }
     if (value.Key.Equals("Use Arrow")) {
         usedBox.Text = value.Number.ToString();
     }
 }
        /// <summary>
        /// Applies a loaded value
        /// </summary>
        /// <param name="value">value</param>
        public void ApplyValue(Value value)
        {
            if (value.Key.Equals("Spread Type")) {
                if (typeBox.Items.Count > value.Number && value.Number >= 0) {
                    spreadBox.SelectedIndex = value.Number;
                }
            }
            else if (value.Key.Equals("Projectile Particle") && value.Number >= 0 && value.Number < typeBox.Items.Count) {
                typeBox.SelectedIndex = value.Number;
            }
            else if (value.Key.Equals("Projectile Data")) {
                int num = value.Number;
                if (num > 13) num--;
                if (num > 11) num--;
                if (num > 7) num--;
                num--;

                if (num >= 0 && num < dataBox.Items.Count) {
                    dataBox.SelectedIndex = num;
                }
            }
        }
Ejemplo n.º 9
0
 /// <summary>
 /// Applies a loaded value
 /// </summary>
 /// <param name="value">value</param>
 public void ApplyValue(Value value)
 {
     if (value.Key.Equals("Lethal")) {
         lethalBox.SelectedIndex = value.Number;
     }
 }
Ejemplo n.º 10
0
 /// <summary>
 /// Applies a loaded value
 /// </summary>
 /// <param name="value">value</param>
 public void ApplyValue(Value value)
 {
 }
 /// <summary>
 /// Applies a loaded value
 /// </summary>
 /// <param name="value">value</param>
 public void ApplyValue(Value value)
 {
     if (value.Key.Equals("X")) xBox.Text = value.Number.ToString();
     else if (value.Key.Equals("Y")) yBox.Text = value.Number.ToString();
     else if (value.Key.Equals("Z")) zBox.Text = value.Number.ToString();
     else if (value.Key.Equals("Yaw")) {
         yawTextBox.Text = value.Number.ToString();
         if (value.Number == -90) yawBox.SelectedIndex = 0;
         else if (value.Number == -270) yawBox.SelectedIndex = 1;
         else if (value.Number == 0) yawBox.SelectedIndex = 2;
         else if (value.Number == -180) yawBox.SelectedIndex = 3;
         else if (value.Number == -45) yawBox.SelectedIndex = 4;
         else if (value.Number == -135) yawBox.SelectedIndex = 5;
         else if (value.Number == -315) yawBox.SelectedIndex = 6;
         else if (value.Number == -225) yawBox.SelectedIndex = 7;
         else yawBox.SelectedIndex = 8;
     }
     else if (value.Key.Equals("Pitch")) {
         pitchTextBox.Text = value.Number.ToString();
         if (value.Number == 0) pitchBox.SelectedIndex = 0;
         else if (value.Number == -90) pitchBox.SelectedIndex = 1;
         else if (value.Number == 90) pitchBox.SelectedIndex = 2;
         else if (value.Number == -45) pitchBox.SelectedIndex = 3;
         else if (value.Number == 45) pitchBox.SelectedIndex = 4;
         else pitchBox.SelectedIndex = 5;
     }
 }
 /// <summary>
 /// Applies a loaded value
 /// </summary>
 /// <param name="value">value</param>
 public void ApplyValue(Value value)
 {
     if (value.Key.Equals("Attack Type")) {
         typeBox.SelectedIndex = value.Number;
     }
 }
Ejemplo n.º 13
0
 /// <summary>
 /// Applies a loaded value
 /// </summary>
 /// <param name="value">value</param>
 public void ApplyValue(Value value)
 {
     if (value.Key.Equals("Status")) {
         int num = value.Number + 1;
         int box = 0;
         while (num > 0) {
             int index = (num - 1) % 32;
             num /= 32;
             if (box > 0) index++;
             if (typeBoxes[box].Items.Count > index) {
                 typeBoxes[box].SelectedIndex = index;
                 box++;
             }
         }
     }
 }
Ejemplo n.º 14
0
 /// <summary>
 /// Applies a loaded value
 /// </summary>
 /// <param name="value">value</param>
 public void ApplyValue(Value value)
 {
     if (value.Key.Equals("ThroughWalls")) {
         typeBox.SelectedIndex = value.Number;
     }
 }