Homebrew Is converting gameshark codes to gateshark possible?

tomx86

Well-Known Member
OP
Member
Joined
Jun 3, 2015
Messages
778
Trophies
0
Age
38
XP
2,164
Country
Poland
Hi, guys I've go pokemon gold vc and I want "All Room Decorators" gateshark code, because when I do it with a emulator it damages the save (RTC I think), and I need to start the game again, if some one can do it then please do, here are the gameshark codes:
All Room Decorators
Gold & Silver Crystal
Bed 01FF0BD8 91FFC6DA
Carpet & Plant 01FF0CD8 91FFC7DA
Poster & Game Console 01FF0DD8 91FFC8DA
Ornament (1-8 dolls) 01FF0ED8 91FFC9DA
Ornament (9-16 dolls) 01FF0FD8 91FFCADA
Ornament (17-20 dolls & 2 trophys) & Big Doll (Snorlax) 01FF10D8 91FFCBDA
Big Doll (Onix & Lapras) 01FF11D8 91FFCCDA
 

tomx86

Well-Known Member
OP
Member
Joined
Jun 3, 2015
Messages
778
Trophies
0
Age
38
XP
2,164
Country
Poland
no is jnot sorry to say, gamedshark is for very very old and by Codebreaker boys while gateshark is by Gateway boys, different code, cifferent systems and no compatible can be seen.!
So someone must make gateshark codes for "All Room Decorators" from scratch, please someone do:bow::bow::bow::bow::bow::bow:
 

Frezgle

Well-Known Member
Member
Joined
Aug 4, 2016
Messages
168
Trophies
0
Age
30
XP
275
Country
United States
First I should point out that those are codes for Crystal; the Gold Version equivalent codes to have all decorations are:
01FF0BD8
01FF0CD8
01FF0DD8
01FF0ED8
01FF0FD8
01FF10D8
01FF11D8

So it's important to know how Gameshark codes are set up in the first place:
[WW][XX][YY][ZZ]
WW: Specifies the type of code and the VRAM bank; in almost all cases this is 01. Crystal uses 91 sometimes; i'm not 100% sure why but I do know Crystal has some somewhat more complex than average RAM handling (as far as GB games go, anyway)
XX: The value the address is being set to. In all of your examples, this is FF, which would just be a hard "yes, the player owns this decoration/decorations"
YY: First address byte; but it's little-endian so it's switched with the ZZ byte
ZZ: Second address byte, same deal as above. In a code that has, for example, ABCD as its address bytes, that would mean the code is modifying RAM address CDBA.

https://gbatemp.net/threads/guide-how-to-create-gateway-cheat-codes.410926/
Now, from this guide it LOOKS like you would only have to deal with the first types of code listed, i.e., memory writes, specifically 8-bit.
"2XXXXXXX 000000YY – 8bit write to [XXXXXXX + offset]
writes the 8-bit value we specify to the given address. This manipulates a single byte. Two 8-bit writes can replace a 16-bit write, however endianness has to be taken into account. See Note at the end of the tutorial about endianness."

One of the given code examples is:
"23BA110C 00000099 – writes the value 0x99 (153) to the address 0x3BA110C. Manipulates only the byte at address 0x3BA110C."

So...
If we take the first code in the list, 01FF0BD8.
01, I don't think needs to be considered. FF would go at the very end of the Gateshark code, as the value being set. And the address bytes would be put in big endian and put in the address part of the code.
So, and I hope I've done all this right, the finished Gateshark code would be:
2000D80B 000000FF
Rinse and repeat for the rest of them.

2000D80C 000000FF
2000D80D 000000FF
2000D80E 000000FF
2000D80F 000000FF
2000D810 000000FF
2000D811 000000FF

Now, this is all assuming that the Virtual Console doesn't handle RAM in a different way that would make these addresses wrong. If that's the case then... That would be where my educated guesses end :V So I would strongly suggest backing up your save first if possible.
 
Last edited by Frezgle,

tomx86

Well-Known Member
OP
Member
Joined
Jun 3, 2015
Messages
778
Trophies
0
Age
38
XP
2,164
Country
Poland
First I should point out that those are codes for Crystal; the Gold Version equivalent codes to have all decorations are:
01FF0BD8
01FF0CD8
01FF0DD8
01FF0ED8
01FF0FD8
01FF10D8
01FF11D8

So it's important to know how Gameshark codes are set up in the first place:
[WW][XX][YY][ZZ]
WW: Specifies the type of code and the VRAM bank; in almost all cases this is 01. Crystal uses 91 sometimes; i'm not 100% sure why but I do know Crystal has some somewhat more complex than average RAM handling (as far as GB games go, anyway)
XX: The value the address is being set to. In all of your examples, this is FF, which would just be a hard "yes, the player owns this decoration/decorations"
YY: First address byte; but it's little-endian so it's switched with the ZZ byte
ZZ: Second address byte, same deal as above. In a code that has, for example, ABCD as its address bytes, that would mean the code is modifying RAM address CDBA.

https://gbatemp.net/threads/guide-how-to-create-gateway-cheat-codes.410926/
Now, from this guide it LOOKS like you would only have to deal with the first types of code listed, i.e., memory writes, specifically 8-bit.
"2XXXXXXX 000000YY – 8bit write to [XXXXXXX + offset]
writes the 8-bit value we specify to the given address. This manipulates a single byte. Two 8-bit writes can replace a 16-bit write, however endianness has to be taken into account. See Note at the end of the tutorial about endianness."

One of the given code examples is:
"23BA110C 00000099 – writes the value 0x99 (153) to the address 0x3BA110C. Manipulates only the byte at address 0x3BA110C."

So...
If we take the first code in the list, 01FF0BD8.
01, I don't think needs to be considered. FF would go at the very end of the Gateshark code, as the value being set. And the address bytes would be put in big endian and put in the address part of the code.
So, and I hope I've done all this right, the finished Gateshark code would be:
2000D80B 000000FF
Rinse and repeat for the rest of them.

2000D80C 000000FF
2000D80D 000000FF
2000D80E 000000FF
2000D80F 000000FF
2000D810 000000FF
2000D811 000000FF

Now, this is all assuming that the Virtual Console doesn't handle RAM in a different way that would make these addresses wrong. If that's the case then... That would be where my educated guesses end :V So I would strongly suggest backing up your save first if possible.
Thanks for your work but unfortunately the game freezes after activating the codes
 

Ryccardo

Penguin accelerator
Member
Joined
Feb 13, 2015
Messages
7,675
Trophies
1
Age
28
Location
Imola
XP
6,882
Country
Italy
Thanks for your work but unfortunately the game freezes after activating the codes
Well, the addresses in the original codes are relative to the GBC's address space, while the new ones are relative to... something. but something in 3DS mode, which complicates finding the new offset...

For that kind of code, save editing is probably a lot more simple!
 

tomx86

Well-Known Member
OP
Member
Joined
Jun 3, 2015
Messages
778
Trophies
0
Age
38
XP
2,164
Country
Poland
Well, the addresses in the original codes are relative to the GBC's address space, while the new ones are relative to... something. but something in 3DS mode, which complicates finding the new offset...

For that kind of code, save editing is probably a lot more simple!
Yeah, but I've already asked Kaphotics the creator of PKHeX on projectpokemon and he told me:
"I don't do research requests as there's so many possible things to edit and only one of me. This requires research to be done and posted; would have to support all 3 language savefiles. save research forum"
So basically to much work so maybe he will add it or not, I think.
But do you know how to do it in a hex editor?
 

Ryccardo

Penguin accelerator
Member
Joined
Feb 13, 2015
Messages
7,675
Trophies
1
Age
28
Location
Imola
XP
6,882
Country
Italy
Yeah, but I've already asked Kaphotics the creator of PKHeX on projectpokemon and he told me:
"I don't do research requests as there's so many possible things to edit and only one of me. This requires research to be done and posted; would have to support all 3 language savefiles. save research forum"
So basically to much work so maybe he will add it or not, I think.
But do you know how to do it in a hex editor?
Even simpler, emulate the game on PC, use the original codes, save, and copy save to 3DS :)

D811 is an address in the console's RAM, not in the save chip (although it will obviously be saved somewhere, given its function)
 
Last edited by Ryccardo,
  • Like
Reactions: TotalInsanity4

tomx86

Well-Known Member
OP
Member
Joined
Jun 3, 2015
Messages
778
Trophies
0
Age
38
XP
2,164
Country
Poland
Even simpler, emulate the game on PC, use the original codes, save, and copy save to 3DS :)

D811 is an address in the console's RAM, not in the save chip (although it will obviously be saved somewhere, given its function)
Like I said in the 1st post the save gets corrupted after doing it, so that not the way to go.
 

tomx86

Well-Known Member
OP
Member
Joined
Jun 3, 2015
Messages
778
Trophies
0
Age
38
XP
2,164
Country
Poland
Gateway doesn't use little endian, but the 3DS does. If you wanted 1.0 in float, you would simply set the value to 3F800000, not 0000803F or whatever.

Like 01234568 3F800000
So how to correct:
2000D80B 000000FF
2000D80C 000000FF
2000D80D 000000FF
2000D80E 000000FF
2000D80F 000000FF
2000D810 000000FF
2000D811 000000FF
 

tomx86

Well-Known Member
OP
Member
Joined
Jun 3, 2015
Messages
778
Trophies
0
Age
38
XP
2,164
Country
Poland
those addresses are wrong then. nothing is stored in such a low memory region.
Maybe it needs a 1st line code like in pokemon yellow vc:
gameshark for Infinite Money:
019946D3
019947D3
019948D3
gateshark for Infinite Money:
D3000000 08923588
2000D346 00000099
2000D347 00000099
2000D348 00000099
so how to find this code?
when i tried this first line code in gold it stops the game from freezing but it does not add new decorations.
 
Last edited by tomx86,

DarkFlare69

Well-Known Member
Member
Joined
Dec 8, 2014
Messages
5,147
Trophies
2
Location
Chicago
XP
4,736
Country
United States
Maybe it needs a 1st line code like in pokemon yellow vc:
gameshark for Infinite Money:
019946D3
019947D3
019948D3
gateshark for Infinite Money:
D3000000 08923588
2000D346 00000099
2000D347 00000099
2000D348 00000099
so how to find this code?
when i tried this first line code in gold it stops the game from freezing but it does not add new decorations.
Yes, D3000000 xxxxxxx will add xxxxxxxx to all following offsets in that block. 0x0000YYYY is way too low of a memory region to be valid.
 

tomx86

Well-Known Member
OP
Member
Joined
Jun 3, 2015
Messages
778
Trophies
0
Age
38
XP
2,164
Country
Poland
Yes, D3000000 xxxxxxx will add xxxxxxxx to all following offsets in that block. 0x0000YYYY is way too low of a memory region to be valid.
or like other codes:
28A2 at start in pokemon gold geteshark unofficiall vc
shinny gameshark
010719D1
shinny gateshark
28A2D119 00000007
and yes i tried that to it didn't work.
 
Last edited by tomx86,

Dracari

Well-Known Member
Member
Joined
Apr 5, 2009
Messages
1,985
Trophies
1
XP
2,465
Country
United States
now i could be completely talkin out my ass but shouldnt he be running NTR's PC Client for Debugging getting a Snapshot on all addressable Ram from say before getting XX Item, obtain it , take a snaphot again and find whats changed and go from there? something like this as its supposedly has gateshark support. https://github.com/imthe666st/NTRClient/releases/
 

tomx86

Well-Known Member
OP
Member
Joined
Jun 3, 2015
Messages
778
Trophies
0
Age
38
XP
2,164
Country
Poland
I tried with a hex editor found the offsets changed then to FF and the save loaded but when I went to the decorations in my PC, they were not added, after saving and editing the save again the offsets where back to the original values, so wtf?
 

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
  • No one is chatting at the moment.
    SylverReZ @ SylverReZ: @salazarcosplay, Morning