Add TSDocs

This commit is contained in:
Jakub Hanko 2024-05-18 09:24:16 +02:00
parent 1bac75f29b
commit 53ed8b9f96
No known key found for this signature in database
GPG Key ID: 775D427937A306CC
2 changed files with 16 additions and 0 deletions

View File

@ -2690,8 +2690,16 @@ export class IgnoreTypeStatusEffectImmunityAbAttr extends AbAttr {
}
}
/**
* Abstract class for aura effects. Aura effects apply tags
* to a list of targets and keeps reapplying them as long
* as the aura source is active.
*/
export abstract class AuraAbAttr extends AbAttr { }
/**
* Damage reduction aura triggered by {@linkcode Abilities.FRIEND_GUARD}.
*/
export class FriendGuardAbAttr extends AuraAbAttr {
apply(pokemon: Pokemon, passive: boolean, cancelled: Utils.BooleanHolder, args: any[]): boolean {
const ally = pokemon.getAlly();

View File

@ -1276,6 +1276,11 @@ export class CursedTag extends BattlerTag {
}
}
/**
* Abstract class for aura tag effects. Lapse is triggered
* at the start of move phase. Tag is active as long
* as the its source is active.
*/
export abstract class AuraTag extends BattlerTag {
constructor(tagType: BattlerTagType, sourceId: number) {
super(tagType, BattlerTagLapseType.CUSTOM, 0, undefined, sourceId);
@ -1287,6 +1292,9 @@ export abstract class AuraTag extends BattlerTag {
}
}
/**
* Tag that reduces received damage. Applied during pre-defend.
*/
export class ReceivedMoveDamageMultiplierTag extends AuraTag {
public powerMultiplier: number;