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

# Class MoveAttr`Abstract`

Base class defining all `Move` Attributes

#### See

`apply`

#### Hierarchy (View Summary)

- MoveAttr
  - MoveEffectAttr
  - MoveHeaderAttr
  - PreMoveMessageAttr
  - PreUseInterruptAttr
  - RespectAttackTypeImmunityAttr
  - IgnoreOpponentStatStagesAttr
  - HighCritAttr
  - CritOnlyAttr
  - FixedDamageAttr
  - ModifiedDamageAttr
  - IgnoreWeatherTypeDebuffAttr
  - IncrementMovePriorityAttr
  - MultiHitAttr
  - ChangeMultiHitTypeAttr
  - BypassSleepAttr
  - BypassBurnDamageReductionAttr
  - OneHitKOAttr
  - InstantChargeAttr
  - OverrideMoveEffectAttr
  - PostVictoryStatStageChangeAttr
  - VariablePowerAttr
  - CombinedPledgeStabBoostAttr
  - StatChangeBeforeDmgCalcAttr
  - VariableAtkAttr
  - VariableDefAttr
  - VariableAccuracyAttr
  - VariableMoveCategoryAttr
  - VariableMoveTypeAttr
  - VariableMoveTypeMultiplierAttr
  - VariableMoveTypeChartAttr
  - MissEffectAttr
  - NoEffectAttr
  - TypelessAttr
  - BypassRedirectAttr
  - HitsTagAttr
  - DiscourageFrequentUseAttr
  - LastResortAttr
  - VariableTargetAttr

- Defined in src/data/moves/move.ts:1069

##### Index

### Constructors

constructor

### Properties

selfTarget

### Methods

apply
getCondition
getFailedText
getTargetBenefitScore
getUserBenefitScore

## Constructors

### constructor

- new MoveAttr(selfTarget?: boolean): MoveAttr

  #### Parameters

  - selfTarget: boolean = false

  #### Returns MoveAttr

  - Defined in src/data/moves/move.ts:1073

## Properties

### selfTarget

selfTarget: boolean

Should this `Move` target the user?

- Defined in src/data/moves/move.ts:1071

## Methods

### apply

- apply(
  user: null | default ,
  target: null | default ,
  move: default ,
  args: any[],
  ): boolean

  Applies move attributes

  #### Parameters

  - user: null | default

    `Pokemon` using the move

  - target: null | default

    `Pokemon` target of the move

  - move: default

    `Move` with this attribute

  - args: any[]

    Set of unique arguments needed by this attribute

  #### Returns boolean

  true if application of the ability succeeds

  #### See

  applyMoveAttrsInternal

  - Defined in src/data/moves/move.ts:1087

### getCondition

- getCondition(): null | MoveCondition | MoveConditionFunc

  #### Returns null | MoveCondition | MoveConditionFunc

  the `MoveCondition` or MoveConditionFunc for this `Move`

  - Defined in src/data/moves/move.ts:1095

### getFailedText

- getFailedText(user: default , target: default , move: default ): undefined | string

  #### Parameters

  - user: default

    `Pokemon` using the move

  - target: default

    `Pokemon` target of the move

  - move: default

    `Move` with this attribute

  #### Returns undefined | string

  the string representing failure of this `Move`

  - Defined in src/data/moves/move.ts:1106

### getTargetBenefitScore

- getTargetBenefitScore(user: default , target: default , move: default ): number

  Used by the Enemy AI to rank an attack based on a given target

  #### Parameters

  - user: default
  - target: default
  - move: default

  #### Returns number

  #### See

  `EnemyPokemon.getNextMove`

  - Defined in src/data/moves/move.ts:1124

### getUserBenefitScore

- getUserBenefitScore(user: default , target: default , move: default ): number

  Used by the Enemy AI to rank an attack based on a given user

  #### Parameters

  - user: default
  - target: default
  - move: default

  #### Returns number

  #### See

  `EnemyPokemon.getNextMove`

  - Defined in src/data/moves/move.ts:1115