Essentials Docs Wiki

The Essentials wiki has moved and is now at: Essentials Engine wiki

This wiki will no longer be updated.

READ MORE

Essentials Docs Wiki
Advertisement
Weather

This article describes weather, conditions that alter the appearance of the game and which can have other effects too. It also describes fogs, which are transparent pictures overlaid on the screen to depict fog, mist, etc.

See also

Time

  • This describes how the screen is tinted to show different times of day. It is another way of altering the appearance of the game.

Overworld weather

Overworld weather is weather that appears in the game as the player walks around maps, as in the picture above. There are five kinds of weather, plus the generic "no weather" type. These are defined in the script section PField_FieldWeather as follows:

Number Overworld weather Description In-battle equivalent
0 none No effects. none
1 Rain Light rain falls down the screen. The screen is slightly darker. RAINDANCE
2 Storm Heavier rain falls at a greater angle (i.e. more sideways). The screen is darker, and flashes sporadically with lightning.

Occurs in Pokémon Sapphire while Kyogre is loose.

RAINDANCE
3 Snow Snow falls down the screen. The screen is lighter. HAIL
4 Blizzard Snow billows across the screen. The screen is lighter (moreso than in snow). HAIL
5 Sandstorm A lot of sand billows across the screen. SANDSTORM
6 HeavyRain Heavier rain falls at a greater angle (i.e. more sideways). The screen is darker. This weather is the same as Storm, but without the lightning. RAINDANCE
7 Sun The screen is brighter, and throbs a little brighter and dimmer.

Occurs in Pokémon Ruby while Groudon is loose.

You may not want to use this overworld weather, as its effect will also occur at night.

SUNNYDAY

Overworld weather is only referred to by name for the purpose of defining it in the PBS file "metadata.txt". Everywhere else in the script, the weather is a numerical value (the number in the table above) stored in the variable $game_screen.weather_type.

Each weather type has its own animation, as described above. These animations are defined in the script section PField_FieldWeather.

Overworld weather has no effect except to influence the in-battle weather for battles taking place there. In the script section PField_Field is the def pbPrepareBattle, which sets the in-battle weather to something depending on the overworld weather. The table above shows these relations. The in-battle weather will be permanent, and will not disappear after 5 turns like weather created by various moves does.

Setting weather for a map

Main article: Metadata

Each map has its own metadata, defined in the PBS file "metadata.txt". There is one metadata called "Weather", which defines the weather for that map. This metadata has two fields: the weather type, and the probability of it occurring (out of 100). For example:

Weather=Snow,50

This means that, when the map is entered, there is a 50% chance that it will start to snow.

In-battle weather

In-battle weather is no different to any other lingering lingering move effect (e.g. Spikes, Stealth Rock), at least in how it is active during the battle (the effects vary, of course).

There are three ways to have in-battle weather:

  • Use a move that induces the weather (lasts for 5 turns).
  • Have a Pokémon in battle with a weather-inducing ability (lasts until that Pokémon is switched out).
  • Enter a battle on a map where there is overworld weather (lasts indefinitely).

The types of in-battle weather are defined in the script section PBWeather. The weather types are as follows:

In-battle weather Effects in Essentials Inducing ability
SUNNYDAY
  • Ups the damage inflicted by Fire moves by 50%, and halves the damage inflicted by Water moves.
  • Pokémon cannot be frozen.
Drought
RAINDANCE
  • Ups the damage inflicted by Water moves by 50%, and halves the damage inflicted by Fire moves.
Drizzle
SANDSTORM
  • Damages non-Ground, non-Rock and non-Steel Pokémon by 1/16 of their max HP at the end of each turn.
  • Ups Special Defense of Rock Pokémon by 50%.
Sand Stream
HAIL
  • Damages non-Ice Pokémon by 1/16 of their max HP at the end of each turn.
Snow Warning

These in-battle weather types are named after the moves that induce that weather. They are always referred to in the scripts as "PBWeather::SUNNYDAY" and so on.

Note that some moves and abilities are affected by the weather (e.g. the move Moonlight restores 2/3 of the max HP in SUNNYDAY, not 1/2). These extra effects are not listed in the table above. To find all the things affected by a weather effect, simply search the scripts for the in-battle weather name.

Creating new weather

Creating a new type of weather is relatively straightforward, although creating an overworld animation can be quite tricky.

Firstly, find the line that lists the overworld weather names (as shown above) and add the name of your new weather to it.

Secondly, you should create an animation for your new weather type in the script section PokemonFieldWeather. As mentioned, this can be very tricky to do. If the weather effect you want is similar to an existing weather type (e.g. micro-meteors are similar to rain), then try to copy that. In any case, you will need to know how to script reasonably well before attempting anything.


If your weather exists in-battle as well as in the overworld, add the in-battle weather type into the script section PBWeather (you can name it whatever you like, just as long as you consistently call it that elsewhere). Then look in the script section PokeBattle_Battle and, wherever messages show up about the other in-battle weather types, insert something similar for your new one. There should be four places to modify in total.

Then, if your new in-battle weather will have any effects (including on existing moves/abilities), add them in.


Finally, consider creating a move and ability that induce your new weather, and perhaps some other new moves/abilities that are affected by it (like how the ability Swift Swim ups the user's Speed only in rain).

Fogs

Fogs are semi-transparent images that are overlaid on the screen to give the impression of a fog, mist, cloud shadows, beams of sunlight, etc. filling the map.

These fog images are stored in the folder "Graphics/Fogs". The image will be tiled, so you don't need an image as big as the map.

To display the fog for a map, you will need to use the event command "Change Map Settings" (choosing "Fog Graphic"). The event that contains this command should have a trigger of Parallel Process, which means that the event will run (and the fog appear) as soon as the player enters the map.

Advertisement