Skip to content

The PokedexClass

poketypes.dex.pokedex OR directly import from poketypes.dex

Basics

Each PokedexClass is a pydantic BaseModel, holding every possibly-useful attribute sourced directly from pokemon showdown typescript files as the ground truth.

Reference

Provides BaseModels for accessing real information about specific items/pokemon/moves/etc.

All Pokedex{NAME} classes are defined in this module, though you can also import these directly from poketypes.dex.

PokedexMove

Pokedex class for Move information.

ATTRIBUTE DESCRIPTION
name

The friendly string name of this move

TYPE: str

id

The DexMove ID of this move

TYPE: DexMove.ValueType

base_power

The base power of the move

TYPE: int

pp

The pp of this move

TYPE: int

priority

The priority of the move

TYPE: int

crit_ratio

The crit ratio of the move (e.g. 2 = twice the chance to crit)

TYPE: int

category

The move category as a DexMoveCategory

TYPE: DexMoveCategory.ValueType

target

The target type of this move

TYPE: DexMoveTarget.ValueType

mtype

The type of the move

TYPE: DexType.ValueType

breaks_protect

Whether the move breaks target protect

TYPE: bool

ignore_ability

Whether the move ignores target ability

TYPE: bool

ignore_defensive

Whether the move ignores target defensive boosts

TYPE: bool

ignore_evasion

Whether the move ignores target evasion boosts

TYPE: bool

ignore_immunity

Whether the move ignores target immunity to this move type

TYPE: bool

multiaccuracy

Whether the multihit move is all or nothing

TYPE: bool

ohko

Whether the move is a one-hit-ko

TYPE: bool

stalling_move

Whether the move is considered a stalling move

TYPE: bool

will_crit

Whether the move will 100% crit if it lands

TYPE: bool

has_crash_damage

Whether the move does damage to its user on failure

TYPE: bool

has_sheer_force

The move is always boosted by sheer-force without losing benefit

TYPE: bool

selfdestruct_always

Whether this move always causes the user to faint

TYPE: bool

selfdestruct_ifhit

Whether the move causes the user to faint if and only if it hits

TYPE: bool

steals_boosts

Whether the move steals the targets boosts

TYPE: bool

level_damage

Whether the move does damage based on the level of the user

TYPE: bool

force_switch

Whether the move forces the target to switch out

TYPE: bool

mindblown_recoil

Whether the move has special 'Mind Blown' style recoil

TYPE: bool

struggle_recoil

Whether the move has special 'Struggle' style recoil

TYPE: bool

smart_target

Whether the move uses smart targetting

TYPE: bool

thaws_target

Whether the move thaws target as a special effect

TYPE: bool

tracks_target

Whether the move ignores draw-in move/abilities.

TYPE: bool

selfswitch_standard

Whether the move is a typical self-switching move. Teleport/U-Turn/etc

TYPE: bool

selfswitch_volatile

Whether the move is a volatile-keeping self-switching move. Baton Pass

TYPE: bool

selfswitch_shedtail

Whether the move is a substitue creating self-switching move. Shed Tail

TYPE: bool

sleep_usable

Whether the move can be used when sleeping

TYPE: bool

no_metronome

Whether the move can NOT be used as a result of metronome

TYPE: bool

no_sketch

Whether the move can NOT be copied as a result of sketch

TYPE: bool

no_ppboosts

Whether the move can NOT have its pp boosted beyond default

TYPE: bool

accuracy

The accuracy of this move. Optional if the move bypasses accuracy

TYPE: Optional[int]

multihit

The move hits multiple times from slot0 - slot1 times inclusive. Optional

TYPE: Optional[Tuple[int, int]]

drain

The move drains hp: (slot0 / slot1) times damage dealt. Optional

TYPE: Optional[Tuple[int, int]]

heal

The move directly heals hp: (slot0 / slot1) times maximum health. Optional

TYPE: Optional[Tuple[int, int]]

recoil

The move recoils back hp: (slot0 / slot1) times damage dealt. Optional

TYPE: Optional[Tuple[int, int]]

boosts

Any boosts for the target this move provides (100%). Optional

TYPE: Optional[Dict[DexStat.ValueType, int]]

direct_damage

An integer exact amount of damage the move does. Optional

TYPE: Optional[int]

weather

The weather started by this move. Optional

TYPE: Optional[DexWeather.ValueType]

flag_allyanim

MOVE FLAG: allyanim

TYPE: bool

flag_bite

MOVE FLAG: bite

TYPE: bool

flag_bullet

MOVE FLAG: bullet

TYPE: bool

flag_bypasssub

MOVE FLAG: bypasssub

TYPE: bool

flag_cantusetwice

MOVE FLAG: cantusetwice

TYPE: bool

flag_charge

MOVE FLAG: charge

TYPE: bool

flag_contact

MOVE FLAG: contact

TYPE: bool

flag_dance

MOVE FLAG: dance

TYPE: bool

flag_defrost

MOVE FLAG: defrost

TYPE: bool

flag_distance

MOVE FLAG: distance

TYPE: bool

flag_failcopycat

MOVE FLAG: failcopycat

TYPE: bool

flag_failencore

MOVE FLAG: failencore

TYPE: bool

flag_failinstruct

MOVE FLAG: failinstruct

TYPE: bool

flag_failmefirst

MOVE FLAG: failmefirst

TYPE: bool

flag_failmimic

MOVE FLAG: failmimic

TYPE: bool

flag_futuremove

MOVE FLAG: futuremove

TYPE: bool

flag_gravity

MOVE FLAG: gravity

TYPE: bool

flag_heal

MOVE FLAG: heal

TYPE: bool

flag_mirror

MOVE FLAG: mirror

TYPE: bool

flag_mustpressure

MOVE FLAG: mustpressure

TYPE: bool

flag_noassist

MOVE FLAG: noassist

TYPE: bool

flag_nonsky

MOVE FLAG: nonsky

TYPE: bool

flag_noparentalbond

MOVE FLAG: noparentalbond

TYPE: bool

flag_nosleeptalk

MOVE FLAG: nosleeptalk

TYPE: bool

flag_pledgecombo

MOVE FLAG: pledgecombo

TYPE: bool

flag_powder

MOVE FLAG: powder

TYPE: bool

flag_protect

MOVE FLAG: protect

TYPE: bool

flag_pulse

MOVE FLAG: pulse

TYPE: bool

flag_punch

MOVE FLAG: punch

TYPE: bool

flag_recharge

MOVE FLAG: recharge

TYPE: bool

flag_reflectable

MOVE FLAG: reflectable

TYPE: bool

flag_slicing

MOVE FLAG: slicing

TYPE: bool

flag_snatch

MOVE FLAG: snatch

TYPE: bool

flag_sound

MOVE FLAG: sound

TYPE: bool

flag_wind

MOVE FLAG: wind

TYPE: bool

PokedexItem

Pokedex class for Item information.

ATTRIBUTE DESCRIPTION
name

The friendly string name of this item

TYPE: str

id

The DexItem ID of this item

TYPE: DexItem.ValueType

is_gem

Whether the item is a gem or not

TYPE: bool

is_berry

Whether the item is a berry

TYPE: bool

naturalgift_base_power

If this item is usable with Natural Gift, what is the base power

TYPE: Optional[int]

naturalgift_type

If this item is usable with Natural Gift, what is the type

TYPE: Optional[DexType.ValueType]

item_users

A list of intended holders of this item

TYPE: List[DexPokemon.ValueType]

zmove_to

What move this zmove transforms the move into

TYPE: Optional[DexMove.ValueType]

zmove_from

What special move this zmove transforms

TYPE: Optional[DexMove.ValueType]

mega_evolves

Which base-forme pokemon this megastone evolves from. Optional

TYPE: Optional[DexPokemon.ValueType]

mega_forme

Which mega-forme pokemon this megastone evolves into. Optional

TYPE: Optional[DexPokemon.ValueType]

ignore_klutz

Whether the item ignores klutz

TYPE: bool

fling_basepower

The basepower of fling when flinging this item. None if n/a

TYPE: Optional[int]

StatBlock

Helper object for containing base stats information.

ATTRIBUTE DESCRIPTION
hp_stat

The base hp of the pokemon

TYPE: int

atk_stat

The base attack of the pokemon

TYPE: int

def_stat

The base defence of the pokemon

TYPE: int

spa_stat

The base special attack of the pokemon

TYPE: int

spd_stat

The base special defence of the pokemon

TYPE: int

spe_stat

The base speed of the pokemon

TYPE: int

PokedexPokemon

Pokedex class for Pokemon information.

ATTRIBUTE DESCRIPTION
name

The friendly string name of this pokemon

TYPE: str

id

The DexPokemon ID of this pokemon

TYPE: DexPokemon.ValueType

base_name

The friendly string name of this pokemon's base forme

TYPE: str

base_id

The DexPokemon ID of this pokemon's base forme

TYPE: DexPokemon.ValueType

types

The types of this pokemon

TYPE: List[DexType.ValueType]

base_stats

The base stat block of this pokemon

TYPE: StatBlock

abilities

The list of abilities this pokemon can have

TYPE: List[DexAbility.ValueType]