Just a reminder that providing specifics on, sharing links to, or naming websites where ROMs can be accessed is against the rules. If your post has any of this information it will be removed.
Ever thought it'd be cool to have your art, writing, or challenge runs featured on PokéCommunity? Click here for info - we'd love to spotlight your work!
Welcome to PokéCommunity! Register now and join one of the best fan communities on the 'net to talk Pokémon and more! We are not affiliated with The Pokémon Company or Nintendo.
daniilS, since you're looking into this, do you know how can I change weather effects?
Which types get hurt by a sandstorm, or which attack types get reduced when a certain weather is up (for example, Fire-type moves getting reduced in the rain), adding the damage to rain for ground and rock Pokémon...
Do you know where in the game is listed this kind of stuff?
daniilS, since you're looking into this, do you know how can I change weather effects?
Which types get hurt by a sandstorm, or which attack types get reduced when a certain weather is up (for example, Fire-type moves getting reduced in the rain), adding the damage to rain for ground and rock Pokémon...
Do you know where in the game is listed this kind of stuff?
If you look at the ability resource thread, I posted a routine for sand force which contain both damamge-boost and prevent-damage from sandstorm regardless of the type.
The area I hooked is where the damage-weather are effective, but it's ASM code so you'll have to learn.
For the damage based on weather, there's MANY places to look into. You can start by some of the places I hooked in Delta stream/desolate/primordial routines, look at the last part, the Air lock/Cloud nine checks are a good start I think
If you look at the ability resource thread, I posted a routine for sand force which contain both damamge-boost and prevent-damage from sandstorm regardless of the type.
The area I hooked is where the damage-weather are effective, but it's ASM code so you'll have to learn.
For the damage based on weather, there's MANY places to look into. You can start by some of the places I hooked in Delta stream/desolate/primordial routines, look at the last part, the Air lock/Cloud nine checks are a good start I think
You'll have to use a free ram location I think. And everytime a damaging weather is set, you'll have to use that free ram to know from what side the weather has been activated.
Then in the damaging weather routine you'll have to use the bank user (or target, depending on how work the routine), to decide wether the poke has to take the damage or not
For the bankuser/target, look at some routine in the ability resource thread
The free ram loc should be a unused ram location of course, again look at the ability resource thread. The delta stream routine, the setword routine etc use freeramloc, there's a ton like that around those location
Not sure if that's the good place to talk about it. Daniils tell us if you want we move around
I had a semi-relevant question, and didn't come across an adequate answer elsewhere:
What exactly ties the overworld weather to in-battle weather in Ruby, Sapphire, and Emerald?
And as a follow up, how feasible would it be to import that into FireRed?
Hello, Daniils, do you know how to add the hail effect in battle when the weather is snow flake on map? If yes, can you teach me how to add this feature by Winhex? I don't know how to use ASM, I know how to use winhex only, thank you very much. In gen 4 and gen 5, when the weather is snow on map, the battle will become hail weather. It is for Emerald.
Hello, every body, who does know how to add the hail effect in battle when the weather is snow flake on map? If someone knows, can someone teach me how to add this feature by Winhex? I don't know how to use ASM, I know how to use winhex only, thanks lot. In gen 4 and gen 5, when the weather is snow on map, the battle will become hail weather. It is for Emerald.
Hello, Artemis 64, do you know how to add the hail effect in battle when the weather is three snow flakes on the Map? In Rainy weather, the battle will happen rainy; in Underground flashes, the battle will happen sunny; In Sandstorm weather, the battle will happen sandstorm. So how to let in Three snow flakes, the battle will happen hail in Emerald? Thank you very much.
I got sunny weather working in FR absolutely fine. I was wondering if it is possible to slow down the animation speed of the effect though? I've never really liked how sunny weather looked in gen III - it looks more like the screen is flashing than sunny weather and looks too distracting to use for a large area in a hack IMO.
I think it would look a lot better if the screen would get brighter and darker again more slowly, maybe at half the speed it is now. Is this possible? Could anyone better at ASM than me give me an idea where to look? Lol
a lot of people have always seemed to want this smh
the video of this image took like 5 years to upload ok i just ripped the tiles from neti's rombase and did the tiles in like 5 minutes because i had to have a pretty gif for this <3
MAKING WEATHERS OUTSIDE CORRESPOND TO THOSE IN-BATTLE specifically hail
This table of pointers' entries each correspond to a weather value from 0x3 to 0xD (Rainy weather to Underground flashes [sic]/Extreme sun).
Weather values (taken from AMap .ini):
Spoiler:
Code:
[Wetter]
00=In-house weather
01=Sunny weather with clouds in water
02=Regular weather
03=Rainy weather
04=Three snow flakes
05=Rain with thunder storm
06=Steady mist
07=Steady snowing
08=Sand storm
09=Mist from top right corner
0A=Dense bright mist
0B=Cloudy
0C=Underground flashes
0D=Heavy rain with thunder storm
0E=Underwater mist
We'll go into adjusting the maximum and minimum values later (if for whatever reason you want to).
So, what do you want to do?
"Steady snowing" is entry 0x7 in the list. Since we start counting at 0x3, it is the 5th entry in the table. "Three snow flakes" is entry 0x4. Since we start counting at 0x3, it is the 2nd entry in the table.
Hopefully, the pattern here is clear.
So "Steady snowing"'s entry is at 0x01A1C8; "Three snow flakes"'s is at 0x01A1BC.
Place a pointer to the routine (NOT +1) at its entry in the table, and voila. Hail happens when snow is present in the overworld.
NOTE: It MAY not be permanent! I have absolutely no idea and didn't test permanence because battles against level 2/3/4 Pokémon with level 2/3/4 Pokémon never last that long.
ONE LAST PART (displaying the correct message):
To make the correct battle message display at the start of battle, put F3 00 at 0x3FE602 (three snow flakes) and 0x3FE608 (steady snowing).
Shoutouts to pokemontutorialTV for informing me that this did not work on clean ROMs and for finding the fix!
If you want it for Emerald (Shoutouts to Panda Face!):
And then F3 00 at both 5CC922 (three snow flakes) and 5CC928 (steady snowing).
EXPANDING YOUR TABLE
0x01A1A2 - minimum weather value (currently 0x3)
0x01A1A4 - [maximum weather value - minimum weather value] (currently 0xD - 0x3 = 0xA)
Why is this, one may ask?
Code:
ROM:0801A1A2 SUBS R0, #3 @ subtract current weather value by three
ROM:0801A1A4 CMP R0, #0xA @ compare the new weather value to 0xA
ROM:0801A1A6 BHI def_801A1B0 @ if the new weather value is higher, go to the default case; no weather in-battle
There is a pointer to the table at 0x01A1B4.
And... that's it (probably)! Just repoint the table and adjust as necessary in order to expand beyond that.
The byte for weather in-battle:
Spoiler:
While doing this, I had to do some more research as well, but this is probably common knowledge for most of the upper hackers maybe possibly theoretically.
0x02023F1C - battle_weather
It's labelled as a halfword but I don't think ever uses the second byte? Anyways...
Bitmask to decide weathers:
Structure:
[bit - hail] [2 bits - sun] [2 bits - sandstorm] [3 bits - rain]
Any one of the bits can be used to activate the desired weather. The middle bit of rain activates a different message ("The downpour continues." instead of "Rain continues to fall.")
Best part? Multiple weathers are supported at once!
Set it to FF and you get this!
"The downpour continues. [rain animation]
The sandstorm rages. [sandstorm buffeting after animation]
The sunlight is strong. [sunlight animation]
Hail continues to fall. [hail pelting after animation]"
So, the rationale, then, of adding new weathers in-battle (i.e. fog and the terrains and pledges)? We have another byte which we can use for this, and I'd actually like to take a stab at doing that sometime eventually theoretically.
a lot of people have always seemed to want this smh
the video of this image took like 5 years to upload ok i just ripped the tiles from neti's rombase and did the tiles in like 5 minutes because i had to have a pretty gif for this <3
MAKING WEATHERS OUTSIDE CORRESPOND TO THOSE IN-BATTLE specifically hail
This table of pointers' entries each correspond to a weather value from 0x3 to 0xD (Rainy weather to Underground flashes [sic]/Extreme sun).
Weather values (taken from AMap .ini):
Spoiler:
Code:
[Wetter]
00=In-house weather
01=Sunny weather with clouds in water
02=Regular weather
03=Rainy weather
04=Three snow flakes
05=Rain with thunder storm
06=Steady mist
07=Steady snowing
08=Sand storm
09=Mist from top right corner
0A=Dense bright mist
0B=Cloudy
0C=Underground flashes
0D=Heavy rain with thunder storm
0E=Underwater mist
We'll go into adjusting the maximum and minimum values later (if for whatever reason you want to).
So, what do you want to do?
"Steady snowing" is entry 0x7 in the list. Since we start counting at 0x3, it is the 5th entry in the table. "Three snow flakes" is entry 0x4. Since we start counting at 0x3, it is the 2nd entry in the table.
Hopefully, the pattern here is clear.
So "Steady snowing"'s entry is at 0x01A1C8; "Three snow flakes"'s is at 0x01A1BC.
Place a pointer to the routine (NOT +1) at its entry in the table, and voila. Hail happens when snow is present in the overworld.
NOTE: It MAY not be permanent! I have absolutely no idea and didn't test permanence because battles against level 2/3/4 Pokémon with level 2/3/4 Pokémon never last that long.
EXPANDING YOUR TABLE
0x01A1A2 - minimum weather value (currently 0x3)
0x01A1A4 - [maximum weather value - minimum weather value] (currently 0xD - 0x3 = 0xA)
Why is this, one may ask?
Code:
ROM:0801A1A2 SUBS R0, #3 @ subtract current weather value by three
ROM:0801A1A4 CMP R0, #0xA @ compare the new weather value to 0xA
ROM:0801A1A6 BHI def_801A1B0 @ if the new weather value is higher, go to the default case; no weather in-battle
There is a pointer to the table at 0x01A1B4.
And... that's it (probably)! Just repoint the table and adjust as necessary in order to expand beyond that.
The byte for weather in-battle:
Spoiler:
While doing this, I had to do some more research as well, but this is probably common knowledge for most of the upper hackers maybe possibly theoretically.
0x02023F1C - battle_weather
It's labelled as a halfword but I don't think ever uses the second byte? Anyways...
Bitmask to decide weathers:
Structure:
[bit - hail] [2 bits - sun] [2 bits - sandstorm] [3 bits - rain]
Any one of the bits can be used to activate the desired weather. The middle bit of rain activates a different message ("The downpour continues." instead of "Rain continues to fall.")
Best part? Multiple weathers are supported at once!
Set it to FF and you get this!
"The downpour continues. [rain animation]
The sandstorm rages. [sandstorm buffeting after animation]
The sunlight is strong. [sunlight animation]
Hail continues to fall. [hail pelting after animation]"
So, the rationale, then, of adding new weathers in-battle (i.e. fog and the terrains and pledges)? We have another byte which we can use for this, and I'd actually like to take a stab at doing that sometime eventually theoretically.
a lot of people have always seemed to want this smh
the video of this image took like 5 years to upload ok i just ripped the tiles from neti's rombase and did the tiles in like 5 minutes because i had to have a pretty gif for this <3
MAKING WEATHERS OUTSIDE CORRESPOND TO THOSE IN-BATTLE specifically hail
This table of pointers' entries each correspond to a weather value from 0x3 to 0xD (Rainy weather to Underground flashes [sic]/Extreme sun).
Weather values (taken from AMap .ini):
Spoiler:
Code:
[Wetter]
00=In-house weather
01=Sunny weather with clouds in water
02=Regular weather
03=Rainy weather
04=Three snow flakes
05=Rain with thunder storm
06=Steady mist
07=Steady snowing
08=Sand storm
09=Mist from top right corner
0A=Dense bright mist
0B=Cloudy
0C=Underground flashes
0D=Heavy rain with thunder storm
0E=Underwater mist
We'll go into adjusting the maximum and minimum values later (if for whatever reason you want to).
So, what do you want to do?
"Steady snowing" is entry 0x7 in the list. Since we start counting at 0x3, it is the 5th entry in the table. "Three snow flakes" is entry 0x4. Since we start counting at 0x3, it is the 2nd entry in the table.
Hopefully, the pattern here is clear.
So "Steady snowing"'s entry is at 0x01A1C8; "Three snow flakes"'s is at 0x01A1BC.
Place a pointer to the routine (NOT +1) at its entry in the table, and voila. Hail happens when snow is present in the overworld.
NOTE: It MAY not be permanent! I have absolutely no idea and didn't test permanence because battles against level 2/3/4 Pok?mon with level 2/3/4 Pok?mon never last that long.
ONE LAST PART (displaying the correct message):
To make the correct battle message display at the start of battle, put F3 00 at 0x3FE602 (three snow flakes) and 0x3FE608 (steady snowing).
Shoutouts to pokemontutorialTV for informing me that this did not work on clean ROMs and for finding the fix!
If you want it for Emerald (Shoutouts to Panda Face!):
Spoiler:
And then F3 00 at both 5CC922 (three snow flakes) and 5CC928 (steady snowing).
EXPANDING YOUR TABLE
0x01A1A2 - minimum weather value (currently 0x3)
0x01A1A4 - [maximum weather value - minimum weather value] (currently 0xD - 0x3 = 0xA)
Why is this, one may ask?
Code:
ROM:0801A1A2 SUBS R0, #3 @ subtract current weather value by three
ROM:0801A1A4 CMP R0, #0xA @ compare the new weather value to 0xA
ROM:0801A1A6 BHI def_801A1B0 @ if the new weather value is higher, go to the default case; no weather in-battle
There is a pointer to the table at 0x01A1B4.
And... that's it (probably)! Just repoint the table and adjust as necessary in order to expand beyond that.
The byte for weather in-battle:
Spoiler:
While doing this, I had to do some more research as well, but this is probably common knowledge for most of the upper hackers maybe possibly theoretically.
0x02023F1C - battle_weather
It's labelled as a halfword but I don't think ever uses the second byte? Anyways...
Bitmask to decide weathers:
Structure:
[bit - hail] [2 bits - sun] [2 bits - sandstorm] [3 bits - rain]
Any one of the bits can be used to activate the desired weather. The middle bit of rain activates a different message ("The downpour continues." instead of "Rain continues to fall.")
Best part? Multiple weathers are supported at once!
Set it to FF and you get this!
"The downpour continues. [rain animation]
The sandstorm rages. [sandstorm buffeting after animation]
The sunlight is strong. [sunlight animation]
Hail continues to fall. [hail pelting after animation]"
So, the rationale, then, of adding new weathers in-battle (i.e. fog and the terrains and pledges)? We have another byte which we can use for this, and I'd actually like to take a stab at doing that sometime eventually theoretically.