I'm also curious to what that 5かい item is supposed to be... with the "5" in it, it doesn't look like anything I've seen from the English version, and I couldn't find the item here, either.
"5かい" is Red and Green's equivalent of the "5F" glitch item (0x5A). It apparently reads data based on some of the party Pokémon data starting from 0xD123 (number of Pokémon), before you select 'USE' as if it was assembly code for the item. There is a page explaining
explaining 5かい here in detail here, (edit: sorry I got the link wrong) probably written by
k(ry, the author of this website. Unfortunately, I don't know understand ASM.
I once tried 5かい when making a list of interesting
glitch items in Pokémon Red and Green, but since I had a random party, all the item did was hang the game after choosing 'USE' so I didn't think of it as having any significance. I don't know for sure how you could obtain it, perhaps you can get it with item mutation, but you can't use
this glitch because the 0x5A character is invalid.
The page tells you how to use 5かい to trigger an 'instant encounter Pokémon' when using the item to change WRAM address 0xD036 (our equivalent of 0xD059). This is the same address used for legendary Pokémon and other Pokémon like Snorlax and the Lavender Town ghost, and it's also what is changed when you abuse Trainer-Fly glitches (e.g. Mew/Ditto glitch) to instantly encounter a wild Pokémon or Trainer.
Using it to encounter an instant encounter Pokémon:They provide this assembly code:
D123 06 xx ;ld B,xx
D125 18 4D ;jr D174
D174 18 56 ;jr D1CC
D1CC 18 56 ;jr D224
D224 18 4F ;jr D275
D275 C3 A4 D2 ;jp D2A4
D2A4 FA A3 D2 ;ld A,(D2A3) D2A3,道具1番目の個数です。
D2A7 EA 36 D0 ;ld (D036),A それを出現するポケモンに対応させます。
D2AA C9 ;ret
From what I can understand from the page,
this example activates an instant encounter Pokémon based on the index number of the first Pokémon, provided you have six Pokémon. I'm also assuming that you must have the other WRAM values in your party (e.g. D125 = 0x18, D126 = 0x4D) so that the game runs the right assembly code for you. I might be wrong though.
So for this example, you'll need:
1) 06h: 6 Pokémon (0xD123)
2) xxh: Any first Pokémon (0xD124)
3) 18h: Tentacool as the second Pokémon (0xD125)
4) 4Dh: Meowth as the third Pokémon (0xD126)
5) 18h: 24 PP left on the second Pokémon's first move (0xD174)
6) 56h: 86 PP left on the second Pokémon's second move (0xD175) - I don't know if this is possible with how PP Ups work in the data structure
7) 18h: 24 PP left on the 4th Pokémon's first move (0xD1CC)
8) 56h: 86 PP left on the 4th Pokémon's second move (0xD1CD)
9) 18h: 24 PP left on the 6th Pokémon's first move (0xD224)
10) 4Fh: 79 PP left on the 6th Pokémon's second move (0xD225) - Again is this possible?
11) C3h, A4h, D2h: The 6th Pokémon's nickname begins with "てヨめ" (0xD275-0xD277)
12) FAh: The second item is TM50 (0xD2A4)
13) A3h: The second item quantity is 163 (0xD2A5)
14) D2h: The third item is TM10 (0xD2A6)
15) EAh: The third item quantity is 234 (0xD2A7)
16) 36h: The fourth item is (0xD2A8)
17) D0h: The fourth item quantity is 208 (0xD2A9)
18) C9h: The fifth item is TM01 (0xD2AA)
These requirements above should activate that ASM code when you use 5かい. See also
here.
That's ridiculous, so not worth it for this particular 'constructed glitch' when you could use Trainer-Fly :(.
Actually, I think the same page tells you how to get around the 86 PP problem with a slightly different set-up (highlighted in blue). Those steps would make you think this sounds pretty much like a crazy PokéGod cheat don't they? I'm going to try to cheat that set-up and test this in concept.
So in concept, you could let this do 'almost anything' you want as long as its possible to get the set-up?
Edit: Completed the requirements list.
Edit2: The website tells you the requirements for other glitches using 5かい, including a glitch PokéMart, a music modifier, fly anywhere, a player name modifier and glitched Pokédex (see
here).
Others: Make a Pokémon evolve into your first Pokémon, another wild encounter modifier.
...Wow, thats interesting. Are the requirements just a little simpler? Did they cause a debug menu to come up?!!Oh, wow they made assembly code for their own debug menu...