The PokéCommunity Forums

The PokéCommunity Forums (https://www.pokecommunity.com/index.php)
-   Binary Hack Research & Development (https://www.pokecommunity.com/forumdisplay.php?f=195)
-   -   Quick Research & Development Thread (https://www.pokecommunity.com/showthread.php?t=205158)

PurpleOrange February 3rd, 2017 1:28 PM

Quote:

Originally Posted by Deokishisu (Post 9563026)
This has been documented and only works this way for Emerald.

well as i said, i wasn't sure if it was documented :)
regardless i wonder why this only works in emerald, since the pichu can transfer to all main gen iii games (assuming this is the pokemon box pichu) surely this means that there must be a way that RSFRLG do it no?

DizzyEgg February 3rd, 2017 2:07 PM

Quote:

Originally Posted by PurpleOrange (Post 9563263)
well as i said, i wasn't sure if it was documented :)
regardless i wonder why this only works in emerald, since the pichu can transfer to all main gen iii games (assuming this is the pokemon box pichu) surely this means that there must be a way that RSFRLG do it no?

Yeah, that way is using ASM.

PurpleOrange February 4th, 2017 6:18 AM

Quote:

Originally Posted by Deokishisu (Post 9563026)
This has been documented and only works this way for Emerald.

Quote:

Originally Posted by DizzyEgg (Post 9563313)
Yeah, that way is using ASM.

Not sure where you got this info from, but i tested it and it works in both firered and ruby just fine :)

tkim February 10th, 2017 10:26 PM

Anybody interested in finding out the table offset that special 0x158 uses in FireRed? Special 0x158 = opens several different multichoice boxes depending on 0x8004 *key: 0x0 = badge talk; 0x1 = silph-co elevator; 0x2 = rocket elevator; 0x3 = celadon department store elevator; 0x4 = link options; 0x5 = pharmacy options?; 0x6 other elevator; 0x7 and up - return 0x7f to lastresult* (quoted from JPAN's special/special2 research thread)

PurpleOrange February 11th, 2017 7:04 PM

Whilst HERE tells us where the swarm table is in Emerald, the swarm table in Ruby is at 0x3D13F8, and the table in Sapphire is at 0x3D1450 using their formula the swarms are:

Surskit Lv3, Route 102: Bubble, Quick Attack
Surskit Lv15, Route 114: Bubble, Quick Attack
Surskit Lv15, Route 117: Bubble, Quick Attack
Surskit Lv28, Route 120: Bubble, Quick Attack
Skitty Lv15, Route 116: Growl, Tackle

Something to note, some are using lower level movesets than they should, surskit learns sweetscent at level 13, whilst skitty should know tail whip (lv3), attract (lv7), sing (lv13), and double slap (lv15), maybe the movepools were updated after swarms were coded, or the swarm levels were changed but the table not updated to match the new levels

Also as a note the previous table for emerald is a bit wrong, here's the new one:

Seedot Lv3, Route 102: Bide, Harden, Leech Seed
Nuzleaf Lv15, Route 114: Harden, Growth, Nature Power, Leech Seed
Seedot Lv13, Route 117: Harden, Growth, Nature Power, Leech Seed
Seedot Lv25, Route 120: Giga Drain, Frustration, Solarbeam, Leech Seed
Skitty Lv8, Route 116: Growl, Tackle, Tail Whip, Attract

tkim February 12th, 2017 10:16 PM

FIRERED v1.0: Special 0x158 (shows multichoice based on values 0x0-0x6 stored in var 0x8004) uses a table at 0x3F5BCC that is 0x12C bytes long. There are six entries in the table and each starting entry is 0x30 bytes away from each other. Now one can easily extend this table by repointing, but there is probably the question of where the offset for the multichoice box properties table is and/or the limiting byte location.

edit: FBI's scrolling multichoice routine seems to have the offset for the multichoice box properties but I have no idea how to read or understand it. The offset seems to be at 0x0CBA7C.

Le pug February 13th, 2017 4:53 AM

Quote:

Originally Posted by aar2697 (Post 7209316)
What I've noticed is that when you insert a map, you are not able to ride the bicycle on that map even if you edit all of the header settings for the map. The solution to this lies in the string of bytes for the map header.

1. In Advance Map, go to the map header and enter the professional map header settings with CTRL+H.
2. In the string of bytes for the map header under "Map options:," find the first of the last four bytes (byte #25 if that confuses you).
3. Change that byte (byte #25) to 01.
4. You can now ride the bicycle on that map!

To build on to this, this is for FR only.

For Emerald, it is very close in similarity. Follow the below image in order to get bike to work or not work on your inserted maps or maps already created. The byte is the same on all maps. It is the second to last one every time.

https://i.snag.gy/92zqHO.jpg

Also if anyone is curious, yes you can also do this by changing the Show name on entering drop down for that map. 01 is the "Show name [01]" option. This allows you to bike on that map but doesn't show the map's name. If you want to bike AND show the map's name on entering the map, the byte is 0D or you can choose "Show city names [0D]". If you want to show the city name but NOT allow biking, the byte is 0C or just choose ??? [0C]

Squeetz February 22nd, 2017 3:10 AM

Unsure if this has been found or not, but in Firered, Unown encountered outside the Island Chambers crash the game.
To fix that, go to 0x82A10 and put 00 00 00 00, this will also make every Unown encountered random.

Goblin the Cat March 6th, 2017 9:22 AM

Is it possible to have items with multiple effects? Ex. an item that increases the damage of both fire and water type moves.

NewDenverCity March 6th, 2017 8:29 PM

Quote:

Originally Posted by Goblin the Cat (Post 9588448)
Is it possible to have items with multiple effects? Ex. an item that increases the damage of both fire and water type moves.

Yes, you just have to make it.

PufferJumps March 10th, 2017 5:54 PM

Hello. I hope I'm on the right thread.

I just wanna ask if there's a way to decrease the pages of Pokedex.

Like for example; The National Pokedex would be up to Celebi only.

MWisBest March 18th, 2017 11:18 PM

Quote:

Originally Posted by FamiliaWerneck (Post 8895647)
I know it's nothing hard, nothing WOOOOW, but that's something and my first alone-research-area collaboration. This is for Fire Red:

INFINITE SAFARI TIME


Simply go to 0xA0F1A and replace the 01 38 there, for 00 38.

The game will still give you 600 steps, but it won't decrease, so you will be there until you retire or run out of Safari Balls.
When I figure out how to hide the step count in the start menu, I'll edit this post.

The equivalent "Infinite Safari Steps" for Emerald appears to be at 0xFC15E. Again, just replace 01 38 with 00 38.
Emerald doesn't have a visible step counter in the menu to hide either, which is nice I guess.

Quote:

Originally Posted by Shiny Quagsire (Post 7803428)
If you ever feel the urge to stone a Pokemon to death, setting the byte at 080169D4 from 0x6 to 0x0 will make it so Pokemon don't flee after throwing 20 rocks at them in the safari zone in Fire Red. Not sure if anyone will ever actually use this but whatever. :P

If you'd like to "stone Pokemon to death" in Emerald, change the byte at 0x3EF94 from 0x06 to 0x00 as well.

AkameTheBulbasaur March 21st, 2017 4:05 PM

How To Give ?? Pokemon Separate Cries
In between Celebi and Treecko in \FR{FireRed} and \EM{Emerald}, there are 25 empty Pokemon slots. These slots appear to have originally been used for the 25 Unown forms before Game Freak decided to go a different route. These slots are all hard-coded to have the cry of Unown, and there is no way to change this with a regular cry editor (it will just change the cry of all of them at once, and will also change the cry of Unown itself).

So, in order to give these Pokemon separate cries, you must do the following.

Insert 00 00 00 00 00 00 00 00 00 00 at:

FireRed: 0x4330C
Emerald: 0x6D518
Ruby: 0x3F90C

Insert 00 00 00 00 at:

FireRed: 0x43318
Emerald: 0x6D524
Ruby: 0x3F918

Repoint the table at:

FireRed: 0x2539D4
Emerald: 0x31F61C
Ruby: 0x1FDE6A

To make repointing the table easier, here is a table you can copy-paste to free space. The 00 00 entries are the 25 ?? slots. You can replace the 00 00's with whatever index number you need to.

Spoiler:

00 00 01 00 02 00 03 00 04 00 05 00 06 00 07 00
08 00 09 00 0a 00 0b 00 0c 00 0d 00 0e 00 0f 00
10 00 11 00 12 00 13 00 14 00 15 00 16 00 17 00
18 00 19 00 1a 00 1b 00 1c 00 1d 00 1e 00 1f 00
20 00 21 00 22 00 23 00 24 00 25 00 26 00 27 00
28 00 29 00 2a 00 2b 00 2c 00 2d 00 2e 00 2f 00
30 00 31 00 32 00 33 00 34 00 35 00 36 00 37 00
38 00 39 00 3a 00 3b 00 3c 00 3d 00 3e 00 3f 00
40 00 41 00 42 00 43 00 44 00 45 00 46 00 47 00
48 00 49 00 4a 00 4b 00 4c 00 4d 00 4e 00 4f 00
50 00 51 00 52 00 53 00 54 00 55 00 56 00 57 00
58 00 59 00 5a 00 5b 00 5c 00 5d 00 5e 00 5f 00
60 00 61 00 62 00 63 00 64 00 65 00 66 00 67 00
68 00 69 00 6a 00 6b 00 6c 00 6d 00 6e 00 6f 00
70 00 71 00 72 00 73 00 74 00 75 00 76 00 77 00
78 00 79 00 7a 00 7b 00 7c 00 7d 00 7e 00 7f 00
80 00 81 00 82 00 83 00 84 00 85 00 86 00 87 00
88 00 89 00 8a 00 8b 00 8c 00 8d 00 8e 00 8f 00
90 00 91 00 92 00 93 00 94 00 95 00 96 00 97 00
98 00 99 00 9a 00 9b 00 9c 00 9d 00 9e 00 9f 00
a0 00 a1 00 a2 00 a3 00 a4 00 a5 00 a6 00 a7 00
a8 00 a9 00 aa 00 ab 00 ac 00 ad 00 ae 00 af 00
b0 00 b1 00 b2 00 b3 00 b4 00 b5 00 b6 00 b7 00
b8 00 b9 00 ba 00 bb 00 bc 00 bd 00 be 00 bf 00
c0 00 c1 00 c2 00 c3 00 c4 00 c5 00 c6 00 c7 00
c8 00 c9 00 ca 00 cb 00 cc 00 cd 00 ce 00 cf 00
d0 00 d1 00 d2 00 d3 00 d4 00 d5 00 d6 00 d7 00
d8 00 d9 00 da 00 db 00 dc 00 dd 00 de 00 df 00
e0 00 e1 00 e2 00 e3 00 e4 00 e5 00 e6 00 e7 00
e8 00 e9 00 ea 00 eb 00 ec 00 ed 00 ee 00 ef 00
f0 00 f1 00 f2 00 f3 00 f4 00 f5 00 f6 00 f7 00
f8 00 f9 00 fa 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 11 01 12 01 13 01 0e 01
0f 01 10 01 14 01 15 01 16 01 67 01 68 01 7a 01
77 01 22 01 23 01 24 01 25 01 26 01 1b 01 1c 01
1d 01 1e 01 1f 01 20 01 2d 01 2e 01 2f 01 0a 01
0b 01 76 01 75 01 0d 01 18 01 17 01 36 01 37 01
79 01 7d 01 38 01 39 01 fb 00 49 01 4a 01 32 01
fd 00 6a 01 3e 01 3f 01 70 01 40 01 41 01 4d 01
4e 01 21 01 04 01 44 01 45 01 46 01 30 01 31 01
fe 00 ff 00 3c 01 3d 01 52 01 53 01 54 01 47 01
48 01 7f 01 33 01 4b 01 4c 01 06 01 42 01 43 01
34 01 35 01 6b 01 50 01 51 01 07 01 08 01 02 01
00 01 69 01 fc 00 2a 01 2b 01 2c 01 3a 01 3b 01
78 01 7e 01 7c 01 7b 01 55 01 56 01 57 01 4f 01
1a 01 19 01 03 01 05 01 6f 01 6c 01 6d 01 6e 01
64 01 65 01 66 01 58 01 59 01 5a 01 5b 01 27 01
28 01 29 01 5f 01 60 01 74 01 5c 01 5d 01 5e 01
61 01 62 01 63 01 72 01 71 01 73 01 01 01 80 01
81 01 82 01 83 01 83 01


Offsets for FireRed were found by DoesntKnowHowToPlay and ThomasWinwood. Details are in this post.

All I did was find the Emerald and Ruby offsets. (I put the FireRed offsets here too for convenience).

PurpleOrange March 22nd, 2017 2:25 PM

Quote:

Originally Posted by AkameTheBulbasaur (Post 9598162)
To allow the 25 ?? Pokemon (the ones between Celebi and Treecko) to have separate cries:

Insert 00 00 00 00 00 00 00 00 00 00 at:

FireRed: 0x4330C
Emerald: 0x6D518
Ruby: 0x3F90C

Insert 00 00 00 00 at:

FireRed: 0x43318
Emerald: 0x6D524
Ruby: 0x3F918

Repoint the table at:

FireRed: 0x2539D4
Emerald: 0x31F61C
Ruby: 0x1FDE6A

Offsets for FireRed were found by DoesntKnowHowToPlay and ThomasWinwood. Details are in this post.

All I did was find the Emerald and Ruby offsets. (I put the FireRed offsets here too for convenience).

hey so this isn't actually fully complete as I found out when I first did it and ported to emerald, what I worked out is you actually have to manually write the cry table for the gen one and two mons in hex -1 followed by a 00 then followed by 50 00's (the limbo slots) eg bulbasaur is 00 00, ivysaur is 01 00 venusaur is 02 00 as stated in my post HERE. so you have to make sure the pointer of the table is to the start of the gen one mons

MWisBest March 22nd, 2017 7:47 PM

Quote:

Originally Posted by Sky High (Post 8824230)

DPPt Save/Summary Pokedex Seen Count Display into Emerald



For those who want the DPPt Amount Display of Pokedex which displays the seen amount in while saving and in the continue-new game menu into Emerald:

08031F96: 00 20
08031FA4: 00 20
0819A3B0: 00 20
0819A3B8: 00 20

Again, it is really that simple. :)

Credits to Jambo51 for his original routine for FireRed.

Only error though: the Trainer's ID. While these changes, it doesn't show the seen amount. Does it supposedly to happen or not? I'll look into that later.

To fix the Trainer Card to show the "Seen" amount too:
080C3776: 00 20
080C377E: 00 20

MWisBest March 23rd, 2017 11:08 PM

Quote:

Originally Posted by knizz (Post 7529991)
Firered's "wait-for-interrupt"-loop is quite inefficient. Here is my suggested patch. (Experimental, may or may not freeze the game.)
Code:

BEFORE:
080008aa  8b91 ldrh r1, [r2, #0x1c]
080008ac  1c18 add r0, r3, #0x0
080008ae  4008 and r0, r1
080008b0  2800 cmp r0, #0x0
080008b2  d0fa beq $080008aa
080008b4  bc01 pop {r0}
080008b6  4700 bx r0

AFTER:
080008aa  df02 swi $02
080008ac  8b91 ldrh r1, [r2, #0x1c]
080008ae  1c18 add r0, r3, #0x0
080008b0  4008 and r0, r1
080008b2  2800 cmp r0, #0x0
080008b4  d0f9 beq $080008aa
080008b6  bd00 pop {pc}


This should be useful if emulation is slow on your machine. Or if you want to be even faster when holding the space key.

The same improvement can be made to Emerald.

Code:

BEFORE:
080008c6  8b91 ldrh r1, [r2, #0x1c]
080008c8  1c18 add r0, r3, #0x0
080008ca  4008 and r0, r1
080008cc  2800 cmp r0, #0x0
080008ce  d0fa beq $080008c6
080008d0  bc01 pop {r0}
080008d2  4700 bx r0

AFTER:
080008c6  df02 swi $02
080008c8  8b91 ldrh r1, [r2, #0x1c]
080008ca  1c18 add r0, r3, #0x0
080008cc  4008 and r0, r1
080008ce  2800 cmp r0, #0x0
080008d0  d0f9 beq $080008c6
080008d2  bd00 pop {pc}


TL;DR:
At 0x8C6, change:
91 8B 18 1C 08 40 00 28 FA D0 01 BC 00 47
to:
02 DF 91 8B 18 1C 08 40 00 28 F9 D0 00 BD

Squeetz March 24th, 2017 4:19 AM

Toggling "set" battle mode (Firered)

First insert this somewhere:
Code:

29 00 FE F4 03 02 AA 92 87 1D 08 2B 04 D0 3D 02 02 00 00 40 00 92 87 1D 08 28 35 87 1D 08


Then, at 0x1D8727, put:
Code:

28 XX XX XX 08


Where XX is the pointer to the battle script you inserted above.

Usage:
In a script, put this:
Code:

...
writebytetooffset 0xAA 0x203F4FE
...


Make sure you writebytetooffset 0x0 0x203F4FE after the battle(s) and on the whiteout script, so it doesn't get stuck on Set mode forever.

Explanation:
This is a really cheap and inefficient solution that branches off the original script that asks this:
http://i.imgur.com/XOZLhfX.png
And if 0x203F4FE = 0xAA, it won't ask at all regardless of the player's option setting.
This could be useful if you're making a battle facility and don't want them to be able to switch after knocking out a Pokémon.

I colored some of the numbers in red, this is the ram offset 0203F4FE, so if you're using this for something else, find another area. (By default this isn't used).

Credits to Doesnt who made the "forced" version:
Quote:

Originally Posted by DoesntKnowHowToPlay (Post 8538908)
Either turn set mode on in the options, or put 28 92 87 1D 08 at x1D8727. Be warned that the latter approach has a nasty side effect; scrubs will complain about your hack being "bugged" or that you removed a feature that should've stayed.


Megax Rocker March 24th, 2017 9:06 AM

Quote:

Originally Posted by Squeetz (Post 9599936)
Snip

Hi there, do you happen to know how to change battle options for link battles?

for example can i change the battle mode to "shift" in link battles or increase the text speed?

MWisBest March 25th, 2017 3:44 AM

Surprised nobody has posted this before.

Change Daycare XP Amount Per Step (Emerald)

At 0x70AE8, change 01 30 to XX 30, where XX is the amount of XP you want per step. Personally, I think 2 is more reasonable than 1.
At 0x70B04, change 04 39 to 04 31. This fixes the eggs-not-appearing-with-even-xp-amounts thing. This does have one minor side-effect: the first chance for an egg to appear after placing 2 Pokemon in the daycare can take anywhere between 1 and 256 steps instead of a fixed amount of 256 steps. After the first "egg chance" it goes back to the fixed 1 chance per 256 steps as usual.

Edit: Even values may or may not break breeding (eggs won't show up). Looking into this more currently. Fixed.

ghoulslash April 1st, 2017 9:36 AM

Before I start digging much further, has anybody been able to figure out how to increase the maximum number of casino coins beyond 9,999?

I'll post anything I find here. I will begin by looking at the following commands/offsets:
display coins: 0806C258
show coins: 0809B578
get coin amount: 0809BB00
add coins: 0809BB20
hide coins: 0809B5A0
updatecoins: 0809B5B4

MWisBest April 3rd, 2017 8:32 AM

Continuing with my daycare stuff:

Change Daycare Breeding Rate [EM]

For those unaware, the "Breeding Rate" is the chance of receiving an egg after taking 256 steps.

This is just a basic version that requires only small hex edits; I'm planning on trying to create a routine that separates the one 50% value into two separate configurable values as well as hopefully allowing Pokemon from the same evolution chain to count as "same species" instead of different species (that has always bothered me).

Anyway, the default breeding rates work like this:
  • 70%: Same Species, Different OT
  • 50%: Same Species, Same OT, [I]or[/] Different Species, Different OT
  • 20%: Different Species, Same OT

To change the 70% value, the following hex edits are required:
  1. At 0x70E48, change 46 20 to XX 20
  2. At 0x70EAC, change 46 2A to XX 2A
To change the 50% value...:
  1. At 0x70E5A, change 32 20 to XX 20
  2. At 0x70EA6, change 32 28 to XX 28
To change the 20% value...:
  1. At 0x70E56, change 14 20 to XX 20
  2. At 0x70EA0, change 14 28 to XX 28
XX would be the percentage value you'd like (in hex of course), 0(?) to 100. The first edits listed are to the main compatibility check function, the second edits are to the function that determines which message the daycare man displays when spoken to.

Skeli April 3rd, 2017 8:57 AM

I just copied the above post because I'm lazy. Credits go to MWisBest for the format.

Change Daycare Breeding Rate [FR]

To change the 70% value, the following hex edits are required:
  1. At 0x46648, change 46 20 to XX 20
  2. At 0x466A8, change 46 2A to XX 2A
To change the 50% value...:
  1. At 0x4665A, change 32 20 to XX 20
  2. At 0x466A2, change 32 28 to XX 28
To change the 20% value...:
  1. At 0x46656, change 14 20 to XX 20
  2. At 0x4669C, change 14 28 to XX 28
XX would be the percentage value you'd like (in hex of course), 0(?) to 100. The first edits listed are to the main compatibility check function, the second edits are to the function that determines which message the daycare man displays when spoken to.

MWisBest April 3rd, 2017 9:27 AM

Quote:

Originally Posted by Skeli789 (Post 9608853)
I just copied the above post because I'm lazy. Credits go to MWisBest for the format.

Heh, works for me. Thanks for porting it.

C me April 3rd, 2017 11:29 AM

To continue a bit on the cries research from 3 years ago there is a byte at:

Emerald: 0x080626AE - Opponent
Emerald: 0x0805CA30 - Ally


*FireRed: 0x08038C32 - Opponent
*FireRed: 0x08033428 - Ally

This byte controls the pitch of the cry played when a Pokemon faints. It is normally set to 5 which is low pitched but follows the same structure as the cry command seen here.

I tested them from 0x0 to 0x10 and it's the same as previously researched. As far as I know it only affects fainting in battle, it won't affect the lower pitched cries when your Pokemon is sent out with low hp or overworld cries.

Useful if you don't want lower pitched faint cries, maybe you're using separate cries for fainting or maybe you want high pitched cries.

*Not 100% sure on the FireRed offsets since I found these in Emerald but the routines are almost identical so pretty likely to be correct.

DizzyEgg April 3rd, 2017 11:32 AM

Quote:

Originally Posted by C me (Post 9608909)

Emerald: 0x080626AE


This byte controls the pitch of the cry played when a Pokemon faints. It is normally set to 5 which is low pitched but follows the same structure as the cry command seen here.

I tested them from 0x0 to 0x10 and it's the same as previously researched. As far as I know it only affects fainting in battle, it won't affect the lower pitched cries when your Pokemon is sent out with low hp or overworld cries.
.

Actually it just controls the fainting cry of the pokemon's opponent.
Btw, do you know what does the 0x19 before it do? It's an argument too.


All times are GMT -8. The time now is 8:53 AM.


Like our Facebook Page Follow us on Twitter © 2002 - 2018 The PokéCommunity™, pokecommunity.com.
Pokémon characters and images belong to The Pokémon Company International and Nintendo. This website is in no way affiliated with or endorsed by Nintendo, Creatures, GAMEFREAK, The Pokémon Company or The Pokémon Company International. We just love Pokémon.
All forum styles, their images (unless noted otherwise) and site designs are © 2002 - 2016 The PokéCommunity / PokéCommunity.com.
PokéCommunity™ is a trademark of The PokéCommunity. All rights reserved. Sponsor advertisements do not imply our endorsement of that product or service. User generated content remains the property of its creator.

Acknowledgements
Use of PokéCommunity Assets
vB Optimise by DragonByte Technologies Ltd © 2023.