2024-07-27 14:26:45 +00:00
|
|
|
using PkmnLib.Dynamic.Models;
|
|
|
|
|
|
|
|
namespace PkmnLib.Dynamic.Libraries;
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// A damage library holds the functions related to the calculation of damage.
|
|
|
|
/// </summary>
|
|
|
|
public interface IDamageCalculator
|
|
|
|
{
|
|
|
|
/// <summary>
|
|
|
|
/// Calculate the damage for a given hit on a Pokemon.
|
|
|
|
/// </summary>
|
2024-07-28 08:41:12 +00:00
|
|
|
uint GetDamage(IExecutingMove executingMove, IPokemon target, byte hitNumber, IHitData hitData);
|
2024-07-27 14:26:45 +00:00
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// Calculate the base power for a given hit on a Pokemon.
|
|
|
|
/// </summary>
|
2024-07-28 08:41:12 +00:00
|
|
|
byte GetBasePower(IExecutingMove executingMove, IPokemon target, byte hitNumber, IHitData hitData);
|
2024-07-27 14:26:45 +00:00
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// Returns whether a specified hit should be critical or not.
|
|
|
|
/// </summary>
|
|
|
|
bool IsCritical(IBattle battle, IExecutingMove executingMove, IPokemon target, byte hitNumber);
|
|
|
|
}
|