Пример #1
0
 public void Apply()
 {
     foreach (Slot slot in Targets)
     {
         slot.Pokemon.UpdateHP(-(int)Modifiers.Calculate(this[slot]));
     }
 }
Пример #2
0
        public int Accuracy(Slot target)
        {
            if (!Targets.Contains(target))
            {
                throw new ArgumentException("Target was not a target of this move", "target");
            }

            int effectiveStage = Math.Max(Math.Min(Slot.Pokemon.Stats.Stage(Statistic.Accuracy) - target.Pokemon.Stats.Stage(Statistic.Evasiveness), Statistics.MaxStage), Statistics.MinStage);

            return((int)AccuracyModifiers.Calculate(Move.Accuracy * Statistics.Multiplier(Statistic.Accuracy, effectiveStage)));
        }