Other environment objects

Effect

This module defines the Effect class, which represents in-game effects.

class poke_env.environment.effect.Effect

Bases: enum.Enum

Enumeration, represent an effect a Pokemon can be affected by.

AFTERMATH = 3
AFTER_YOU = 2
AQUA_RING = 4
AROMATHERAPY = 5
AROMA_VEIL = 6
ATTRACT = 7
AUTOTOMIZE = 8
BAD_DREAMS = 9
BANEFUL_BUNKER = 10
BATTLE_BOND = 11
BIDE = 12
BIND = 13
BURN_UP = 14
CELEBRATE = 15
CHARGE = 16
CLAMP = 17
CONFUSION = 18
COURT_CHANGE = 19
CRAFTY_SHIELD = 20
CURSE = 21
CUSTAP_BERRY = 22
DANCER = 23
DESTINY_BOND = 24
DISABLE = 25
DISGUISE = 26
DOOM_DESIRE = 27
DYNAMAX = 28
EERIE_SPELL = 29
ELECTRIC_TERRAIN = 30
EMBARGO = 31
EMERGENCY_EXIT = 32
ENCORE = 33
ENDURE = 34
FAIRY_LOCK = 35
FEINT = 36
FIRE_SPIN = 37
FLASH_FIRE = 38
FLOWER_VEIL = 39
FOCUS_BAND = 40
FOCUS_ENERGY = 41
FORESIGHT = 42
FOREWARN = 43
FUTURE_SIGHT = 44
GRAVITY = 50
GRUDGE = 51
GUARD_SPLIT = 52
GULP_MISSILE = 53
G_MAX_CENTIFERNO = 45
G_MAX_CHI_STRIKE = 46
G_MAX_ONE_BLOW = 47
G_MAX_RAPID_FLOW = 48
G_MAX_SANDBLAST = 49
HEALER = 56
HEAL_BELL = 54
HEAL_BLOCK = 55
HYDRATION = 57
HYPERSPACE_FURY = 58
HYPERSPACE_HOLE = 59
ICE_FACE = 60
ILLUSION = 61
IMMUNITY = 62
IMPRISON = 63
INFESTATION = 64
INGRAIN = 65
INNARDS_OUT = 66
INSOMNIA = 67
IRON_BARBS = 68
LASER_FOCUS = 69
LEECH_SEED = 70
LIGHTNING_ROD = 71
LIMBER = 72
LIQUID_OOZE = 73
LOCK_ON = 74
MAGMA_STORM = 75
MAGNET_RISE = 76
MAGNITUDE = 77
MAT_BLOCK = 78
MAX_GUARD = 79
MIMIC = 80
MIMICRY = 81
MIND_READER = 82
MINIMIZE = 83
MIRACLE_EYE = 84
MIST = 85
MISTY_TERRAIN = 86
MUMMY = 87
NEUTRALIZING_GAS = 88
NIGHTMARE = 89
NO_RETREAT = 90
OBLIVIOUS = 91
OCTOLOCK = 92
OWN_TEMPO = 93
PASTEL_VEIL = 94
PERISH0 = 95
PERISH1 = 96
PERISH2 = 97
PERISH3 = 98
PHANTOM_FORCE = 99
POLTERGEIST = 100
POWDER = 101
POWER_CONSTRUCT = 102
POWER_SPLIT = 103
POWER_TRICK = 104
PROTECT = 105
PROTECTIVE_PADS = 106
PSYCHIC_TERRAIN = 107
PURSUIT = 108
QUASH = 109
QUICK_CLAW = 110
QUICK_GUARD = 111
REFLECT = 112
RIPEN = 113
ROUGH_SKIN = 114
SAFEGUARD = 115
SAFETY_GOGGLES = 116
SAND_TOMB = 117
SCREEN_CLEANER = 118
SHADOW_FORCE = 119
SHED_SKIN = 120
SKETCH = 121
SKILL_SWAP = 122
SKY_DROP = 123
SLOW_START = 124
SMACK_DOWN = 125
SNAP_TRAP = 126
SNATCH = 127
SPEED_SWAP = 128
SPITE = 129
STICKY_HOLD = 130
STICKY_WEB = 131
STOCKPILE = 132
STOCKPILE1 = 133
STOCKPILE2 = 134
STOCKPILE3 = 135
STORM_DRAIN = 136
STRUGGLE = 137
SUBSTITUTE = 138
SUCTION_CUPS = 139
SWEET_VEIL = 140
SYMBIOSIS = 141
SYNCHRONIZE = 142
TAR_SHOT = 143
TAUNT = 144
TELEKINESIS = 145
TELEPATHY = 146
THROAT_CHOP = 147
THUNDER_CAGE = 148
TORMENT = 149
TRAPPED = 150
TRICK = 151
TYPEADD = 152
TYPECHANGE = 153
TYPE_CHANGE = 154
UPROAR = 155
VITAL_SPIRIT = 156
WANDERING_SPIRIT = 157
WATER_BUBBLE = 158
WATER_VEIL = 159
WHIRLPOOL = 160
WIDE_GUARD = 161
WIMP_OUT = 162
WRAP = 163
YAWN = 164
breaks_protect
Returns:Whether this effect breaks protect-like states.
Return type:bool
from_showdown_message = <function Effect.from_showdown_message>
is_action_countable
Returns:Whether it is useful to keep track of the number of times this effect has been activated.
Return type:bool
is_turn_countable
Returns:Whether it is useful to keep track of the number of turns this effect has been active for.
Return type:bool

Field

This module defines the Field class, which represents a battle field.

class poke_env.environment.field.Field

Bases: enum.Enum

Enumeration, represent a non null field in a battle.

ELECTRIC_TERRAIN = 2
GRASSY_TERRAIN = 3
GRAVITY = 4
HEAL_BLOCK = 5
MAGIC_ROOM = 6
MISTY_TERRAIN = 7
MUD_SPORT = 8
MUD_SPOT = 9
PSYCHIC_TERRAIN = 10
TRICK_ROOM = 11
WATER_SPORT = 12
WONDER_ROOM = 13
from_showdown_message = <function Field.from_showdown_message>
is_terrain

Wheter this field is a terrain.

Move category

This module defines the MoveCategory class, which represents a move category.

class poke_env.environment.move_category.MoveCategory

Bases: enum.Enum

Enumeration, represent a move category.

PHYSICAL = 1
SPECIAL = 2
STATUS = 3

Pokemon gender

This module defines the PokemonGender class, which represents the gender of a Pokemon.

class poke_env.environment.pokemon_gender.PokemonGender

Bases: enum.Enum

Enumeration, represent a pokemon’s gender.

FEMALE = 1
MALE = 2
NEUTRAL = 3
from_request_details = <function PokemonGender.from_request_details>

Pokemon Type

This module defines the PokemonType class, which represents a Pokemon type. PokemonTypes are mainly associated with Pokemons and moves.

class poke_env.environment.pokemon_type.PokemonType

Bases: enum.Enum

A Pokemon type

This enumeration represents pokemon types. Each type is an instance of this class, whose name corresponds to the upper case spelling of its english name (ie. FIRE).

BUG = 1
DARK = 2
DRAGON = 3
ELECTRIC = 4
FAIRY = 5
FIGHTING = 6
FIRE = 7
FLYING = 8
GHOST = 9
GRASS = 10
GROUND = 11
ICE = 12
NORMAL = 13
POISON = 14
PSYCHIC = 15
ROCK = 16
STEEL = 17
WATER = 18
damage_multiplier(type_1: poke_env.environment.pokemon_type.PokemonType, type_2: Optional[PokemonType] = None) → float

Computes the damage multiplier from this type on a pokemon with types type_1 and, optionally, type_2.

Parameters:
  • type_1 (PokemonType) – The first type of the target.
  • type_2 (PokemonType, optional) – The second type of the target. Defaults to None.
Returns:

The damage multiplier from this type on a pokemon with types type_1 and, optionally, type_2.

Return type:

float

from_name = <function PokemonType.from_name>

Side condition

This module defines the SideCondition class, which represents a in-battle side condition.

class poke_env.environment.side_condition.SideCondition

Bases: enum.Enum

Enumeration, represent a in-battle side condition.

AURORA_VEIL = 2
FIRE_PLEDGE = 3
GRASS_PLEDGE = 9
G_MAX_CANNONADE = 4
G_MAX_STEELSURGE = 5
G_MAX_VINE_LASH = 6
G_MAX_VOLCALITH = 7
G_MAX_WILDFIRE = 8
LIGHT_SCREEN = 10
LUCKY_CHANT = 11
MIST = 12
REFLECT = 13
SAFEGUARD = 14
SPIKES = 15
STEALTH_ROCK = 16
STICKY_WEB = 17
TAILWIND = 18
TOXIC_SPIKES = 19
WATER_PLEDGE = 20
from_showdown_message = <function SideCondition.from_showdown_message>

Status

This module defines the Status class, which represents statuses a pokemon can be afflicted with.

class poke_env.environment.status.Status

Bases: enum.Enum

Enumeration, represent a status a pokemon can be afflicted with.

BRN = 1
FNT = 2
FRZ = 3
PAR = 4
PSN = 5
SLP = 6
TOX = 7

Weather

This module defines the Weather class, which represents a in-battle weather.

class poke_env.environment.weather.Weather

Bases: enum.Enum

Enumeration, represent a non null weather in a battle.

DELTASTREAM = 3
DESOLATELAND = 2
HAIL = 4
PRIMORDIALSEA = 5
RAINDANCE = 6
SANDSTORM = 7
SUNNYDAY = 8
from_showdown_message = <function Weather.from_showdown_message>

Z Crystal

This module contains objects related ot z-crystal management. It should not be used directly.