ROM Hack Editing AR Code

marliaths

Member
OP
Newcomer
Joined
May 31, 2010
Messages
6
Trophies
0
XP
11
Country
United States
Hello, I am trying to add an On/Off button for an AR code for Pokemon Heart Gold. The code is to make shiny pokemon appear. I got the cheat database from gbatemp and the original code is as follows:

621D1584 00000000
0206DEFC 47004800
0206DF00 02000001
E2000000 0000003C
6800480D 490B6840
88011808 9C0D8842
40510C24 20074061
04244041 940D430C
21001C28 F06EAA0D
4801FEA3 46C04700
0206DF05 000000DC
021D1584 00000000
D2000000 00000000


I managed to put a ON switch, as in when I press R+B then the shiny pokemon code is activated inside the game. The code after that was this:

94000130 FCFC0201
621D1584 00000000
0206DEFC 47004800
0206DF00 02000001
E2000000 0000003C
6800480D 490B6840
88011808 9C0D8842
40510C24 20074061
04244041 940D430C
21001C28 F06EAA0D
4801FEA3 46C04700
0206DF05 000000DC
021D1584 00000000
D2000000 00000000


I figured that the code at the top was the ON button which is this code : 94000130 FCFC0201 I used R4cce for this and I tried unchecking L+A but it still didn't create it as an OFF button. So my question is this: how do I add an off button so when I click a combination, say L+A, it would turn off the shiny pokemon code off and allow normal pokemon to appear?
 

Dr Pikachu

Well-Known Member
Newcomer
Joined
May 30, 2010
Messages
89
Trophies
0
XP
146
Country
United States
Well "On" and "off" are called Jokers for one and it mainly comprises of finding which addresses are the jokers. Most of the time in PS2 coding they are very similar. The jokers are either this set
0206DEFC 47004800
0206DF00 02000001
or you didn't add an Off joker to it.
 

marliaths

Member
OP
Newcomer
Joined
May 31, 2010
Messages
6
Trophies
0
XP
11
Country
United States
I didn't know they were called jokers, I don't really have much knowledge about codes but I was just messing around. I didn't add an off button (joker) yet, I am wondering how to actually add it to the code so it turns off the code when I press a button combination.

The only piece of code I actually added at all was this line:

94000130 FCFC0201

And that allows me to press R+B which in turns on the code inside the game. Would someone create for me this shiny code with both an On/Off button or show me what code to add to the mix that would allow me to turn it off when I want to?
 

elixirdream

Well-Known Member
Member
Joined
May 27, 2008
Messages
10,007
Trophies
0
Location
6th Dimention
Website
Visit site
XP
114
Country
Malaysia
you require another few lines of codes to turn it off
when turning the code on it writes whatever you want to the ram
however, letting go your activator doesn't mean it will turn off the code
a few more lines that is to restore the original value is what you need
 

marliaths

Member
OP
Newcomer
Joined
May 31, 2010
Messages
6
Trophies
0
XP
11
Country
United States
That makes sense, instead of using the original data, it is substituting the code instead. What code would I need to add to this particular code in order to turn it off? The help would be appreciated
 

elixirdream

Well-Known Member
Member
Joined
May 27, 2008
Messages
10,007
Trophies
0
Location
6th Dimention
Website
Visit site
XP
114
Country
Malaysia
0206DEFC 47004800
0206DF00 02000001

i guess is these two lines
smile.gif
 

marliaths

Member
OP
Newcomer
Joined
May 31, 2010
Messages
6
Trophies
0
XP
11
Country
United States
Oh, I see. Where do I add these two lines, at the beginning, at the end, or in between somewhere? And correct me if I am wrong but aren't these two lines already in the code?
 

Dr Pikachu

Well-Known Member
Newcomer
Joined
May 30, 2010
Messages
89
Trophies
0
XP
146
Country
United States
marliaths said:
Oh, I see. Where do I add these two lines, at the beginning, at the end, or in between somewhere? And correct me if I am wrong but aren't these two lines already in the code?
well most codes end in the traditional d2000000 00000000 so the bottom says no
 

marliaths

Member
OP
Newcomer
Joined
May 31, 2010
Messages
6
Trophies
0
XP
11
Country
United States
So does it go at the top or does it go in between some of the lines? I'm guessing its not the top because that is where the ON code is right?
 

Dr Pikachu

Well-Known Member
Newcomer
Joined
May 30, 2010
Messages
89
Trophies
0
XP
146
Country
United States
marliaths said:
So does it go at the top or does it go in between some of the lines? I'm guessing its not the top because that is where the ON code is right?
Yes you're right. this is just a hunch and I would say it goes like this
621D1584 00000000
0206DEFC 47004800
0206DF00 02000001
E2000000 0000003C
6800480D 490B6840
88011808 9C0D8842
40510C24 20074061
04244041 940D430C
21001C28 F06EAA0D
4801FEA3 46C04700
0206DF05 000000DC
021D1584 00000000
0206DEFC 47004800
0206DF00 02000001

D2000000 00000000
 

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
    Materia_tofu @ Materia_tofu: this is true! i learned how to make soundfont remixes from a friend back in 2021 +1