Discussion in 'GBA - Game Development, ROM Hacks and Translations' started by mbcrazed, Feb 28, 2013.

2,272 Views

Member
Nov 10, 2012
GBATemp
How can I figure out the hex numbers in Pokemon Emerald? Thanks Tempers!~

2. DiscostewSMGBAtemp Guru

Member
Feb 10, 2009
Sacramento, California
A hex number is simply a counting number using base 16. Much like how we use base 10 for regular counting (0 to 9, then 10 to 19, etc), Hex counts from 0 to F (where A to F represent 10 to 15), then the next count from 10 to 1F, then 20 to 2F, ... , E0 to EF, F0 to FF, 100 to 10F, etc etc.

A representation of a base 10 number separating the digits for say 1569 could be shown as

(1 * 10^3) + (5 * 10^2) + (6 * 10^1) + (9 * 10^0)

So, say we have a hex number like h4EA3. What would it equal as base 10?

(4 * 16^3) + (14 * 16^2) + (10*16^1) + (3 * 16^0) = 16384 + 3584 + 160 + 3 = 20131

Member
Nov 10, 2012
GBATemp
Hmm.... So How can you tell which Pokemon you have? ( Sorry if It's a stupid question, I'm kind of a noob when it comes to this stuff)

4. DiscostewSMGBAtemp Guru

Member
Feb 10, 2009
Sacramento, California
Well, that would require having information about the game on hand, which I do not have. But I'm sure whatever it is will have addresses (location in the file) of what is what, like what pokemon you have, what their level is, etc, and that will likely be held in hex format.

Member
Nov 10, 2012
GBATemp
Thanks for this information! The reason I was needing to know is because I'm working on a, " Project."

6. SnailfaceMy frothing demand for 3ds homebrew is increasing

Member
Sep 20, 2010
Engine Room with Cyan, watching him learn.
Um.. you can play the game of course. But since you are talking about hex numbers, I guess you want a more hacky way.

It'll do the hex number reading for you.

7. ouch123GBAtemp Fan

Member
Aug 2, 2012
He already covered converting from hex to decimal so I'll go over converting from decimal to hex, which I'm assuming is what's confusing you.

Let's take your post count as an example.
15 < 231 < 255. So, we know that your post count can be represented using two hexadecimal digits (hexits).
231 / 16 = 14, Remainder 7.
14 = 0xE
7 = 0x7
Then, 231 = 0xE7.

Edit: Urgh, misinterpreted the source of your confusion. If you want to know what Pokémon is associated with a given hexadecimal value, you will have to either consult a table or make one, in all likelihood.

Member
Nov 10, 2012
GBATemp
I have Pokegen for uploading my shinies to pokecheck! It won't open though, It's a Pokemon Emerald save!

9. SnailfaceMy frothing demand for 3ds homebrew is increasing

Member
Sep 20, 2010
Engine Room with Cyan, watching him learn.