# BattlerTag | pokemon-rogue-battle
Documentation for pokemon-rogue-battle

# Class BattlerTag

#### Hierarchy (View Summary)

- BattlerTag
  - MoveRestrictionBattlerTag
  - RechargingTag
  - BeakBlastChargingTag
  - ShellTrapTag
  - TrappedTag
  - FlinchedTag
  - InterruptedTag
  - ConfusedTag
  - DestinyBondTag
  - InfatuatedTag
  - SeedTag
  - PowderTag
  - NightmareTag
  - FrenzyTag
  - HelpingHandTag
  - AquaRingTag
  - MinimizeTag
  - DrowsyTag
  - ProtectedTag
  - EnduringTag
  - SturdyTag
  - PerishSongTag
  - CenterOfAttentionTag
  - AbilityBattlerTag
  - SemiInvulnerableTag
  - TypeImmuneTag
  - TypeBoostTag
  - CritBoostTag
  - SaltCuredTag
  - CursedTag
  - RemovedTypeTag
  - GroundedTag
  - RoostedTag
  - FormBlockDamageTag
  - CommandedTag
  - StockpilingTag
  - GulpMissileTag
  - ExposedTag
  - TarShotTag
  - ElectrifiedTag
  - AutotomizedTag
  - SubstituteTag
  - MysteryEncounterPostSummonTag
  - SyrupBombTag
  - TelekinesisTag
  - PowerTrickTag
  - GrudgeTag
  - PsychoShiftTag
  - MagicCoatTag

- Defined in src/data/battler-tags.ts:59

##### Index

### Constructors

constructor

### Properties

isBatonPassable
lapseTypes
sourceId?
sourceMove
tagType
turnCount

### Methods

canAdd
getDescriptor
getMoveName
getSourcePokemon
isSourceLinked
lapse
loadTag
onAdd
onOverlap
onRemove

## Constructors

### constructor

- new BattlerTag(
  tagType: BattlerTagType ,
  lapseType: BattlerTagLapseType | BattlerTagLapseType [],
  turnCount: number,
  sourceMove?: Moves ,
  sourceId?: number,
  isBatonPassable?: boolean,
  ): BattlerTag

  #### Parameters

  - tagType: BattlerTagType
  - lapseType: BattlerTagLapseType | BattlerTagLapseType []
  - turnCount: number
  - `Optional` sourceMove: Moves
  - `Optional` sourceId: number
  - isBatonPassable: boolean = false

  #### Returns BattlerTag

  - Defined in src/data/battler-tags.ts:67

## Properties

### isBatonPassable

isBatonPassable: boolean

- Defined in src/data/battler-tags.ts:65

### lapseTypes

lapseTypes: BattlerTagLapseType []

- Defined in src/data/battler-tags.ts:61

### `Optional` sourceId

sourceId?: number

- Defined in src/data/battler-tags.ts:64

### sourceMove

sourceMove: Moves

- Defined in src/data/battler-tags.ts:63

### tagType

tagType: BattlerTagType

- Defined in src/data/battler-tags.ts:60

### turnCount

turnCount: number

- Defined in src/data/battler-tags.ts:62

## Methods

### canAdd

- canAdd(_pokemon: default ): boolean

  #### Parameters

  - _pokemon: default

  #### Returns boolean

  - Defined in src/data/battler-tags.ts:83

### getDescriptor

- getDescriptor(): string

  #### Returns string

  - Defined in src/data/battler-tags.ts:97

### getMoveName

- getMoveName(): null | string

  #### Returns null | string

  - Defined in src/data/battler-tags.ts:105

### getSourcePokemon

- getSourcePokemon(): null | default

  Helper function that retrieves the source Pokemon object

  #### Returns null | default

  The source `Pokemon` or `null` if none is found

  - Defined in src/data/battler-tags.ts:124

### isSourceLinked

- isSourceLinked(): boolean

  #### Returns boolean

  - Defined in src/data/battler-tags.ts:101

### lapse

- lapse(_pokemon: default , _lapseType: BattlerTagLapseType ): boolean

  #### Parameters

  - _pokemon: default
  - _lapseType: BattlerTagLapseType

  #### Returns boolean

  - Defined in src/data/battler-tags.ts:93

### loadTag

- loadTag(source: any): void

  When given a battler tag or json representing one, load the data for it. This is meant to be inherited from by any battler tag with custom attributes

  #### Parameters

  - source: any

    A battler tag

  #### Returns void

  - Defined in src/data/battler-tags.ts:114

### onAdd

- onAdd(_pokemon: default ): void

  #### Parameters

  - _pokemon: default

  #### Returns void

  - Defined in src/data/battler-tags.ts:87

### onOverlap

- onOverlap(_pokemon: default ): void

  #### Parameters

  - _pokemon: default

  #### Returns void

  - Defined in src/data/battler-tags.ts:91

### onRemove

- onRemove(_pokemon: default ): void

  #### Parameters

  - _pokemon: default

  #### Returns void

  - Defined in src/data/battler-tags.ts:89