Files
PkmnLib.NET/Plugins/PkmnLib.Plugin.Gen7/Scripts/Moves/GyroBall.cs
Deukhoofd d2a82b5fe3
All checks were successful
Build / Build (push) Successful in 3m12s
Many more tests and fixes
2026-08-27 17:11:12 +02:00

16 lines
508 B
C#

namespace PkmnLib.Plugin.Gen7.Scripts.Moves;
[Script(ScriptCategory.Move, "gyro_ball")]
public class GyroBall : Script, IScriptChangeBasePower
{
/// <inheritdoc />
public void ChangeBasePower(IExecutingMove move, IPokemon target, byte hit, ref ushort basePower)
{
if (move.User.BoostedStats.Speed == 0)
{
basePower = 1;
return;
}
basePower = (ushort)Math.Min(150, 25 * target.BoostedStats.Speed / move.User.BoostedStats.Speed + 1);
}
}