public override string ValidateInputs() { string err = Base.ValidateInputs(); err += PassiveEffectAttributes.ValidateInputs(); err += PassiveEffectRates.ValidateInputs(); err += StatMods.ValidateInputs(0, 1000); if (!Utils.PosInt(HPMinInput.Text, 100)) { err += "HP Min % must be an integer between 0 and 100\n"; } if (!Utils.PosInt(HPMaxInput.Text, 100)) { err += "HP Max % must be an integer between 0 and 100\n"; } if (!Utils.PosInt(SPMinInput.Text, 100)) { err += "SP Min % must be an integer between 0 and 100\n"; } if (!Utils.PosInt(SPMaxInput.Text, 100)) { err += "SP Max % must be an integer between 0 and 100\n"; } bool identical = false; int s1 = StateActive1Input.SelectedIndex; int s2 = StateActive2Input.SelectedIndex; int s3 = StateInactive1Input.SelectedIndex; int s4 = StateInactive2Input.SelectedIndex; if (s1 != 0 && (s1 == s2 || s1 == s3 || s1 == s4)) { identical = true; } if (s2 != 0 && (s2 == s3 || s2 == s4)) { identical = true; } if (s3 != 0 && (s3 == s4)) { identical = true; } if (identical) { err += "All State Active/Inactive inputs must be unique from each other\n"; } if (!Utils.PosInt(ExpGainRateInput.Text)) { err += "EXP Gain % must be a positive integer\n"; } if (!Utils.PosInt(GoldGainRateInput.Text)) { err += "Gold Gain % must be a positive integer\n"; } return(err); }
public override string ValidateInputs() { string err = Base.ValidateInputs(); err += PassiveEffectAttributes.ValidateInputs(); err += PassiveEffectRates.ValidateInputs(); err += StatMods.ValidateInputs(0, 1000); if (!Utils.PosInt(MaxStackInput.Text)) { err += "Max Stack must be a positive integer\n"; } if (!Utils.PosInt(StepsToRemoveInput.Text)) { err += "Steps to Remove must be a positive integer\n"; } if (!Utils.PosInt(ContactSpreadRateInput.Text, 100)) { err += "Contact Spread % must be an integer between 0 and 100\n"; } return(err); }
public override string ValidateInputs() { string err = Base.ValidateInputs(); err += PassiveEffectAttributes.ValidateInputs(); err += PassiveEffectRates.ValidateInputs(); if (!Utils.PosInt(AccuracyInput.Text, 1000)) { err += "Accuracy must be an integer between 0 to 1000\n"; } if (!Utils.PosInt(EvasionInput.Text, 1000)) { err += "Evasion must be an integer between 0 to 1000\n"; } if (!Utils.PosInt(CriticalRateInput.Text, 1000)) { err += "Critical Rate must be an integer between 0 and 1000\n"; } if (!Utils.PosInt(CritEvadeRateInput.Text, 1000)) { err += "Crit Evade Rate must be an integer between 0 and 1000\n"; } return(err); }