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 = <class 'enum.auto'>
INSOMNIA = 66
IRON_BARBS = 67
LASER_FOCUS = 68
LEECH_SEED = 69
LIGHTNING_ROD = 70
LIMBER = 71
LIQUID_OOZE = 72
LOCK_ON = 73
MAGMA_STORM = 74
MAGNET_RISE = 75
MAGNITUDE = 76
MAT_BLOCK = 77
MAX_GUARD = 78
MIMIC = 79
MIMICRY = 80
MIND_READER = 81
MIRACLE_EYE = 82
MIST = 83
MISTY_TERRAIN = 84
MUMMY = 85
NEUTRALIZING_GAS = 86
NIGHTMARE = 87
NO_RETREAT = 88
OBLIVIOUS = 89
OCTOLOCK = 90
OWN_TEMPO = 91
PASTEL_VEIL = 92
PERISH0 = 93
PERISH1 = 94
PERISH2 = 95
PERISH3 = 96
PHANTOM_FORCE = 97
POLTERGEIST = 98
POWDER = 99
POWER_CONSTRUCT = 100
POWER_SPLIT = 101
POWER_TRICK = 102
PROTECT = 103
PROTECTIVE_PADS = 104
PSYCHIC_TERRAIN = 105
PURSUIT = 106
QUASH = 107
QUICK_CLAW = 108
QUICK_GUARD = 109
REFLECT = 110
RIPEN = 111
ROUGH_SKIN = 112
SAFEGUARD = 113
SAFETY_GOGGLES = 114
SAND_TOMB = 115
SCREEN_CLEANER = 116
SHADOW_FORCE = 117
SHED_SKIN = 118
SKETCH = 119
SKILL_SWAP = 120
SKY_DROP = 121
SLOW_START = 122
SMACK_DOWN = 123
SNAP_TRAP = 124
SNATCH = 125
SPEED_SWAP = 126
SPITE = 127
STICKY_HOLD = 128
STICKY_WEB = 129
STOCKPILE = 130
STOCKPILE1 = 131
STOCKPILE2 = 132
STOCKPILE3 = 133
STORM_DRAIN = 134
STRUGGLE = 135
SUBSTITUTE = 136
SUCTION_CUPS = 137
SWEET_VEIL = 138
SYMBIOSIS = 139
SYNCHRONIZE = 140
TAR_SHOT = 141
TAUNT = 142
TELEKINESIS = 143
TELEPATHY = 144
THROAT_CHOP = 145
THUNDER_CAGE = 146
TORMENT = 147
TRAPPED = 148
TRICK = 149
TYPEADD = 150
TYPECHANGE = 151
TYPE_CHANGE = 152
UPROAR = 153
VITAL_SPIRIT = 154
WANDERING_SPIRIT = 155
WATER_BUBBLE = 156
WATER_VEIL = 157
WHIRLPOOL = 158
WIDE_GUARD = 159
WIMP_OUT = 160
WRAP = 161
YAWN = 162
breaks_protect
Returns:Wheter this effects breaks protect-like states.
Return type:bool
from_showdown_message = <function Effect.from_showdown_message>
is_action_countable
Returns:Wheter it is useful to keep track of the number of times this effect has been activated.
Return type:bool
is_turn_countable
Returns:Wheter 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.