From 3916b2b08baa716551be416edb90b74fd4cf4e32 Mon Sep 17 00:00:00 2001 From: Jakub Hanko <60473007+JakubHanko@users.noreply.github.com> Date: Fri, 17 May 2024 07:28:44 +0200 Subject: [PATCH] Add TSDoc for the new classes --- src/data/move.ts | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/src/data/move.ts b/src/data/move.ts index 388d0496bc1..276069ad8a7 100644 --- a/src/data/move.ts +++ b/src/data/move.ts @@ -2129,7 +2129,21 @@ export class WeightPowerAttr extends VariablePowerAttr { } } +/** + * Attribute used for Electro Ball move. + * @extends VariablePowerAttr + * @see {@linkcode apply} + **/ export class ElectroBallPowerAttr extends VariablePowerAttr { + /** + * Move that deals more damage the faster {@linkcode BattleStat.SPD} + * the user is compared to the target. + * @param user Pokemon that used the move + * @param target The target of the move + * @param move Move with this attribute + * @param args N/A + * @returns true if the function succeeds + */ apply(user: Pokemon, target: Pokemon, move: Move, args: any[]): boolean { const power = args[0] as Utils.NumberHolder; @@ -2148,7 +2162,22 @@ export class ElectroBallPowerAttr extends VariablePowerAttr { } } + +/** + * Attribute used for Gyro Ball move. + * @extends VariablePowerAttr + * @see {@linkcode apply} + **/ export class GyroBallPowerAttr extends VariablePowerAttr { + /** + * Move that deals more damage the slower {@linkcode BattleStat.SPD} + * the user is compared to the target. + * @param user Pokemon that used the move + * @param target The target of the move + * @param move Move with this attribute + * @param args N/A + * @returns true if the function succeeds + */ apply(user: Pokemon, target: Pokemon, move: Move, args: any[]): boolean { const power = args[0] as Utils.NumberHolder; const userSpeed = user.getBattleStat(Stat.SPD);