ShyRayq
Unprofessional Unprofessional
- 1,856
- Posts
- 17
- Years
- Seen Aug 9, 2024
Hello Gentlemans and Ladywomans! I am here to bring you this very special tutorial.
With a new type being added in Gen VI, hackers want to stay up to date and add this new type. However, they usually just replace the ??? type but this messes up Struggle and eggs. So, here I am with this tutorial, complementing DestinedJagold's and MrDollSteak's tutorials. Check them out if you're using Ruby or Emerald respectively.
For this tutorial, you need:
1. NSE 2.X
2. A hex editor, I have HxD
3. A Fire Red 1.0 rom
4. Paint XP/Vista
The photos are borked, I'll get to fixing them soon.
This comes in 3 parts, The Icon, The Chart and The Name.
HERE WE GO! LETS'A GO!
PART 1: THE ICON
First, open up your Fire Red rom in NSE 2.X
Now, press navigate and a window will pop up. On the right, press the + next to "Pokemon", then "BPRE" which the code for Fire Red, then "Hud", then "PKMN" then finally, click "Status"
You'll get something like this:
Now, the palette is wierd as, so in the Palette section, type in E95DBC. Now press Open, and close the small window as you'll no longer need it.
Now export it. Go to "File", "Export" then "Export Bitmap" or just press "Ctrl + Shift + E"
Save it somewhere, then edit.
Now when you edit your image, only edit the height if you're changing dimension, also if you do edit it, THE DIMENSIONS MUST BE DIVISIBLE BY 8, IF NOT YOU WILL MESS UP THE ICONS. Also, it's suggested that you do not change the colour scheme as it'll make the process easier, but if you have to, be warned that it'll mess up the palette of a couple of other things.
So open up NSE 2.X again, and go to the image but this time, change the "Height" to however tall your image is, divided by 8.
Now, click "File", "Import", "Import Sprite Data" or just press "Ctrl + I".
Press "Load Sprite", click your sprite now.
In this example, I added 3 types, but theoretically, you could add up to ~250 types, but you'd be a mad man if you did.
Now, if you changed the palette, you have to change the dropbox to "Image+Palette". Otherwise, just press 'Save'
Now, you have to insert it into a different part of the rom, as it is now bigger than the original image.
So go to "Insert" than "Image Data". You'll get this window.
Now, if its a new rom, you'll probably get the same offset as me, but if not, it doesn't matter anyway. This offset will be the pointer to the image data. Once you have an offset you're okay with, press Save.
If you changed the Palette, do the same thing for the "Palette Data"
Close NSE and open up the rom in a hex editor.
Now find DC5DE908 by using Ctrl + F or whatever your program uses.
Press okay, then you get it. Now replace it with your pointer. But first, we need it in a format the game understands. Don't know how to change it? Look below!
First, take any offset > ABCDEF
Split it into sections of 2 > AB CD EF
Reverse the 3 sections > EF CD AB
Then slap 08 on the end of it > EF CD AB 08
There ya go!
So in my case, I've got 00 00 80 08, which is quite bland. Anyway, now replace the original pointer with the new one. There's only 1 case so that's the only one.
Then, find the palette pointer, which is BC5DE908, and replace it with the reformatted pointer of your palette data.
Anyway, you may think you're done, but now the hardest part comes.
Go to the offset 452C94 using the Ctrl + G or Go to option.
You'll come to a bunch of hex. You need to copy 0x60 bytes.
Go and paste that into free space, preferably right under the image data. You can use a paste-insert option like the one in HxD.
Make a note of the offset. Now, what exactly is this?
This is actually code that assigns a type to an icon. It uses the type icon image, and using a co-ordinate, links a type to its icon. The way this works is complicated so I made a simple image that should help.
Here's how to find the co-ordinate of an icon.
1. Go from left to right. Which column is it in? Look at the top and assign your icon the number of the column, either 0, 4, 8 or C.
2. Go from top to bottom. Which row is it in? Look at the side and assign your icon the number of the row, from 0, 20, 40, 60, 80, A0 and onwards.
3. Take those two numbers and add them together. That's your co-ordinate!
E.g./ In my image, the Fajro Icon is in the column labeled 4 and the row labeled 20.
20+4 > 24. Fajro's co-ordinate is 0x24. Why 0x? Because this is all in hex.
Now what's the co-ordinate of my new icon, Lumo? It's in column 0 and row 100. Therefore, it's co-ordinate is 0x100.
Now how do we add this to the table? The table is made up of 4 bytes.
Byte 1 is the width of the icon. Type icons have width 0x20 which the other icons are width 0x28.
Byte 2 is the height of the icon. All icons have height 0x0C.
Byte 3 and 4 are the co-ordinate, but flipped similarly to the pointer.
E.g/ Take Fajro's co-ordinate. First make it 4 digits by adding 00s to the front if you have to:
24 > 0024. Split it into groups of 2.
0024 > 00 24. Now flip the order around.
00 24 > 24 00. This is the final co-ordinate of Fajro's icon.
For Lumo, it would be 100 > 0100 > 01 00 > 00 01.
Using these rules, we can now add in the co-ordinates of our new icons. Go to the end of the table and add them in: The height, the width, and the formatted co-ordinate. Here's mine for my 3 new icons.
**The third icon should have a width of 0x20 not 0x28**
Now we have to repoint. Search for 942C4508 in your hex editor.
Replace it with the reformatted pointer to your new co-ordination table. In my case, it'd be 00 24 80 08.
There's only 1 case so just replace that one.
Now to test it out ingame! You can use a hex editor by going to 0x254784 and editing the type byte of a pokemon. But, what's the type byte of your new type?
In your co-ordinate table, the first NEW entry would be 0x17, the next entry would be 0x18 and so on.
In my case, Lumo would be 0x17 as it is the first new entry in my table.
Success! The Icon has now been added!
Make sure to test out all of your new icons.
PART 2: THE CHART
Now we come to the hardest part: changing the type effectiveness of your new type.
Okay, we're gonna need to open up our hex editor.
Now go to your "Goto" function and type in 24F050
You'll have a bunch of hex here. Copy 150 bytes.
Now move all this data into freespace. You can put it after the co-ordinate table if you want, as its space-saving. So go there, select 150 bytes and paste.
Hooray! Now, it is time to edit in our new type effectiveness.
First let's examine this data. Take the first entry:
00 05 05
Type effectiveness is placed in 3 bytes.
The first byte is the attacking type, the second the defending type, and the third, the effectiveness.
The types in hex are :
Normal = 00
Fighting = 01
Flying = 02
Poison = 03
Ground = 04
Rock = 05
Bug = 06
Ghost = 07
Steel = 08
??? = 09
Fire = 0A
Water = 0B
Grass = 0C
Electric = 0D
Psychic = 0E
Ice = 0F
Dragon = 10
Dark = 11
The new type is 0x17 (In my case Lumo)
Any new type after this begins at 0x18 and onwards...
Now using this data, you can see that 00 05 05 translates into Normal, Rock, 05.
If you know pokemon, you'll know that the 05 represents 0.5x damage as Normal is not very effective against Rock.
The other damage multipliers are:
05 = 0.5x
00 = 0x
14 = 2.0x
But you're not restrictly stuck with these. You can go all the way FE or 25.4x damage which is insane! How to figure out new damage multipliers?
Take your multipler, e.g. 5.6x
Multiply by 10 e.g. 56x
Now convert into HEX e.g. 0x38
Be warned as doing this won't bring up a 'It's not very effective!' or 'It's super effective' message. You need ASM for this. Unfortunately, I'm not sure how to do this.
Okay, so you've figured out the way the chart works, now to edit right? Before that...
Let's look at this piece of data at the end.
FE FE 00 00 07 00 01 07 00 FF FF 00
Now the "FE FE 00" signifies that anything after this point is affected by Foresight.
So the 00 07 00 which is Normal Ghost 0x and 01 07 00 Fighting Ghost 0x are affected by Foresight.
Then we have FF FF 00 which signifies the end of the chart.
WE HAVE TO KEEP THESE PARTS AT THE END.
Okay, so to add a new effectiveness, just copy that piece of code, and move it down however many new effectivesnesses you'll add x3. For an example, I'll only move them down 3 spaces.
Now the actually adding. Using the info above, I'm sure you can make your own weaknesses and strengths on your own.
But here's an example.
I want Lumo to hit Super Effectivie on Fire
Okay so this new type is 0x17 and Fire is 0A and 2x/Super Effective Hit is 14.
So my code is 17 0A 14. Insert it into the new space and done!
Hooray!
Now if you want you're new effecvtiness to be affect by Foresight, just move the FF FF 00 at the end 3 bits and add it in.
But make sure the damage multiplier is 0x, which is 00.
Okay save your rom and you're finally done....kinda.
We're gonna have to repoint the chart.
So now, find the pointer: 50 F0 24 08
Now, replace it with your pointer, in my case: 70 24 80 08
There's a 5 occurrences, so keep finding the old pointers and replacing them.
Okay. Once you've replaced all of the pointers. You're done! Now to test it in game. You first have to change a move into your new type. You can go to 0x250C04 and change the type byte of one of the moves.
In this case, I made Tackle into a Lumo type move.
Now to test:
Success! We're now done with the second part!
PART 3: THE NAME
Now what we're editing here is hard to explain. So here's an Image.
Here, you can see a bunch of gibberish in the corner, even though the move Tackle is now Lumo type. We're gonna change this.
So open up your hex editor again and go to the "Go To" function. Go to 24F1A0
The data we're concerned with is here:
As before, you're gonna have to move this to free space. Again, putting it under the previous data can save space, so do that.
Okay, so now we've got a bundle of random hex. Except that it isn't. It's actually letters.
Using this reference:
A = bb
B = bc
C = bd
D = be
E = bf
F = c0
G = c1
H = c2
I = c3
J = c4
K = c5
L = c6
M = c7
N = c8
O = c9
P = ca
Q = cb
R = cc
S = cd
T = ce
U = cf
V = d0
W = d1
X = d2
Y = d3
Z = d4
We can see that these are the names of the types. In this order:
NORMAL, FIGHT, FLYING, POISON, GROUND, ROCK, BUG, GHOST, STEEL, ???, FIRE, WATER, GRASS, ELECTR, PSYCHC, ICE, DRAGON, DARK.
The "FF"s represent the end of the name and the "00"s are for alignment.
Now what happens next is that, Dark is type 0x11, and Lumo is type 0x17, so we need some space between the entries. This is because the "Type", "Power", "PP", "Accuracy" and"Effect" icons are technically types as well, but they don't get used in battle so they don't need names. So, what you need to know is that each entry is 7 bytes long. So, just create a string of 7 bytes that contain 6 00s and 1 FF and that will be alright. Do this 4 more times.
Now add in the new name. Use the hex values for the letters in the spoiler above.
Now, we have to repoint. The original pointer is A0F12408, and replace it.
My new pointer is D0258008 by the way. There are 5 cases so its a short task.
Now to see the results:
Success!
You've now successfully added a new type!
If you wanna edit pokemon or moves using programs, you're gonna have to edit the inis.
There should be 2 things you want to edit.
1. typenames or typenameoffset or something along those lines.
Change the address in this line to the address of where the name table is.
2. number of types.
To change this, first take 22 and add the number of new types you added. In my case, I added 3 new types, so I would change this to 25.
And that's it. If you read all of this, you should be able to create many new types, if you leave enough space. If you see any mistakes, please post it in the thread. Or just comment.
Credit:
coolboyman for the original thread on the type chart
MrDollSteak for his patch that includes the new Fairy type added in, and allowing me to look through the rom.
destinedjagold for his thread, which kind of convinced me to make my thread
With a new type being added in Gen VI, hackers want to stay up to date and add this new type. However, they usually just replace the ??? type but this messes up Struggle and eggs. So, here I am with this tutorial, complementing DestinedJagold's and MrDollSteak's tutorials. Check them out if you're using Ruby or Emerald respectively.
For this tutorial, you need:
1. NSE 2.X
2. A hex editor, I have HxD
3. A Fire Red 1.0 rom
4. Paint XP/Vista
The photos are borked, I'll get to fixing them soon.
This comes in 3 parts, The Icon, The Chart and The Name.
HERE WE GO! LETS'A GO!
PART 1: THE ICON
Spoiler:
First, open up your Fire Red rom in NSE 2.X
Now, press navigate and a window will pop up. On the right, press the + next to "Pokemon", then "BPRE" which the code for Fire Red, then "Hud", then "PKMN" then finally, click "Status"
You'll get something like this:
Now, the palette is wierd as, so in the Palette section, type in E95DBC. Now press Open, and close the small window as you'll no longer need it.
Now export it. Go to "File", "Export" then "Export Bitmap" or just press "Ctrl + Shift + E"
Save it somewhere, then edit.
Now when you edit your image, only edit the height if you're changing dimension, also if you do edit it, THE DIMENSIONS MUST BE DIVISIBLE BY 8, IF NOT YOU WILL MESS UP THE ICONS. Also, it's suggested that you do not change the colour scheme as it'll make the process easier, but if you have to, be warned that it'll mess up the palette of a couple of other things.
So open up NSE 2.X again, and go to the image but this time, change the "Height" to however tall your image is, divided by 8.
Now, click "File", "Import", "Import Sprite Data" or just press "Ctrl + I".
Press "Load Sprite", click your sprite now.
In this example, I added 3 types, but theoretically, you could add up to ~250 types, but you'd be a mad man if you did.
Now, if you changed the palette, you have to change the dropbox to "Image+Palette". Otherwise, just press 'Save'
Now, you have to insert it into a different part of the rom, as it is now bigger than the original image.
So go to "Insert" than "Image Data". You'll get this window.
Now, if its a new rom, you'll probably get the same offset as me, but if not, it doesn't matter anyway. This offset will be the pointer to the image data. Once you have an offset you're okay with, press Save.
If you changed the Palette, do the same thing for the "Palette Data"
Close NSE and open up the rom in a hex editor.
Now find DC5DE908 by using Ctrl + F or whatever your program uses.
Press okay, then you get it. Now replace it with your pointer. But first, we need it in a format the game understands. Don't know how to change it? Look below!
Spoiler:
First, take any offset > ABCDEF
Split it into sections of 2 > AB CD EF
Reverse the 3 sections > EF CD AB
Then slap 08 on the end of it > EF CD AB 08
There ya go!
So in my case, I've got 00 00 80 08, which is quite bland. Anyway, now replace the original pointer with the new one. There's only 1 case so that's the only one.
Then, find the palette pointer, which is BC5DE908, and replace it with the reformatted pointer of your palette data.
Anyway, you may think you're done, but now the hardest part comes.
Go to the offset 452C94 using the Ctrl + G or Go to option.
You'll come to a bunch of hex. You need to copy 0x60 bytes.
Go and paste that into free space, preferably right under the image data. You can use a paste-insert option like the one in HxD.
Make a note of the offset. Now, what exactly is this?
This is actually code that assigns a type to an icon. It uses the type icon image, and using a co-ordinate, links a type to its icon. The way this works is complicated so I made a simple image that should help.
Here's how to find the co-ordinate of an icon.
1. Go from left to right. Which column is it in? Look at the top and assign your icon the number of the column, either 0, 4, 8 or C.
2. Go from top to bottom. Which row is it in? Look at the side and assign your icon the number of the row, from 0, 20, 40, 60, 80, A0 and onwards.
3. Take those two numbers and add them together. That's your co-ordinate!
E.g./ In my image, the Fajro Icon is in the column labeled 4 and the row labeled 20.
20+4 > 24. Fajro's co-ordinate is 0x24. Why 0x? Because this is all in hex.
Now what's the co-ordinate of my new icon, Lumo? It's in column 0 and row 100. Therefore, it's co-ordinate is 0x100.
Now how do we add this to the table? The table is made up of 4 bytes.
Byte 1 is the width of the icon. Type icons have width 0x20 which the other icons are width 0x28.
Byte 2 is the height of the icon. All icons have height 0x0C.
Byte 3 and 4 are the co-ordinate, but flipped similarly to the pointer.
E.g/ Take Fajro's co-ordinate. First make it 4 digits by adding 00s to the front if you have to:
24 > 0024. Split it into groups of 2.
0024 > 00 24. Now flip the order around.
00 24 > 24 00. This is the final co-ordinate of Fajro's icon.
For Lumo, it would be 100 > 0100 > 01 00 > 00 01.
Using these rules, we can now add in the co-ordinates of our new icons. Go to the end of the table and add them in: The height, the width, and the formatted co-ordinate. Here's mine for my 3 new icons.
**The third icon should have a width of 0x20 not 0x28**
Now we have to repoint. Search for 942C4508 in your hex editor.
Replace it with the reformatted pointer to your new co-ordination table. In my case, it'd be 00 24 80 08.
There's only 1 case so just replace that one.
Now to test it out ingame! You can use a hex editor by going to 0x254784 and editing the type byte of a pokemon. But, what's the type byte of your new type?
In your co-ordinate table, the first NEW entry would be 0x17, the next entry would be 0x18 and so on.
In my case, Lumo would be 0x17 as it is the first new entry in my table.
Success! The Icon has now been added!
Make sure to test out all of your new icons.
PART 2: THE CHART
Spoiler:
Now we come to the hardest part: changing the type effectiveness of your new type.
Okay, we're gonna need to open up our hex editor.
Now go to your "Goto" function and type in 24F050
You'll have a bunch of hex here. Copy 150 bytes.
Now move all this data into freespace. You can put it after the co-ordinate table if you want, as its space-saving. So go there, select 150 bytes and paste.
Hooray! Now, it is time to edit in our new type effectiveness.
First let's examine this data. Take the first entry:
00 05 05
Type effectiveness is placed in 3 bytes.
The first byte is the attacking type, the second the defending type, and the third, the effectiveness.
The types in hex are :
Spoiler:
Normal = 00
Fighting = 01
Flying = 02
Poison = 03
Ground = 04
Rock = 05
Bug = 06
Ghost = 07
Steel = 08
??? = 09
Fire = 0A
Water = 0B
Grass = 0C
Electric = 0D
Psychic = 0E
Ice = 0F
Dragon = 10
Dark = 11
The new type is 0x17 (In my case Lumo)
Any new type after this begins at 0x18 and onwards...
Now using this data, you can see that 00 05 05 translates into Normal, Rock, 05.
If you know pokemon, you'll know that the 05 represents 0.5x damage as Normal is not very effective against Rock.
The other damage multipliers are:
05 = 0.5x
00 = 0x
14 = 2.0x
But you're not restrictly stuck with these. You can go all the way FE or 25.4x damage which is insane! How to figure out new damage multipliers?
Take your multipler, e.g. 5.6x
Multiply by 10 e.g. 56x
Now convert into HEX e.g. 0x38
Be warned as doing this won't bring up a 'It's not very effective!' or 'It's super effective' message. You need ASM for this. Unfortunately, I'm not sure how to do this.
Okay, so you've figured out the way the chart works, now to edit right? Before that...
Let's look at this piece of data at the end.
FE FE 00 00 07 00 01 07 00 FF FF 00
Now the "FE FE 00" signifies that anything after this point is affected by Foresight.
So the 00 07 00 which is Normal Ghost 0x and 01 07 00 Fighting Ghost 0x are affected by Foresight.
Then we have FF FF 00 which signifies the end of the chart.
WE HAVE TO KEEP THESE PARTS AT THE END.
Okay, so to add a new effectiveness, just copy that piece of code, and move it down however many new effectivesnesses you'll add x3. For an example, I'll only move them down 3 spaces.
Now the actually adding. Using the info above, I'm sure you can make your own weaknesses and strengths on your own.
But here's an example.
I want Lumo to hit Super Effectivie on Fire
Okay so this new type is 0x17 and Fire is 0A and 2x/Super Effective Hit is 14.
So my code is 17 0A 14. Insert it into the new space and done!
Hooray!
Now if you want you're new effecvtiness to be affect by Foresight, just move the FF FF 00 at the end 3 bits and add it in.
But make sure the damage multiplier is 0x, which is 00.
Okay save your rom and you're finally done....kinda.
We're gonna have to repoint the chart.
So now, find the pointer: 50 F0 24 08
Now, replace it with your pointer, in my case: 70 24 80 08
There's a 5 occurrences, so keep finding the old pointers and replacing them.
Okay. Once you've replaced all of the pointers. You're done! Now to test it in game. You first have to change a move into your new type. You can go to 0x250C04 and change the type byte of one of the moves.
In this case, I made Tackle into a Lumo type move.
Now to test:
Success! We're now done with the second part!
PART 3: THE NAME
Spoiler:
Now what we're editing here is hard to explain. So here's an Image.
Here, you can see a bunch of gibberish in the corner, even though the move Tackle is now Lumo type. We're gonna change this.
So open up your hex editor again and go to the "Go To" function. Go to 24F1A0
The data we're concerned with is here:
As before, you're gonna have to move this to free space. Again, putting it under the previous data can save space, so do that.
Okay, so now we've got a bundle of random hex. Except that it isn't. It's actually letters.
Using this reference:
Spoiler:
A = bb
B = bc
C = bd
D = be
E = bf
F = c0
G = c1
H = c2
I = c3
J = c4
K = c5
L = c6
M = c7
N = c8
O = c9
P = ca
Q = cb
R = cc
S = cd
T = ce
U = cf
V = d0
W = d1
X = d2
Y = d3
Z = d4
We can see that these are the names of the types. In this order:
NORMAL, FIGHT, FLYING, POISON, GROUND, ROCK, BUG, GHOST, STEEL, ???, FIRE, WATER, GRASS, ELECTR, PSYCHC, ICE, DRAGON, DARK.
The "FF"s represent the end of the name and the "00"s are for alignment.
Now what happens next is that, Dark is type 0x11, and Lumo is type 0x17, so we need some space between the entries. This is because the "Type", "Power", "PP", "Accuracy" and"Effect" icons are technically types as well, but they don't get used in battle so they don't need names. So, what you need to know is that each entry is 7 bytes long. So, just create a string of 7 bytes that contain 6 00s and 1 FF and that will be alright. Do this 4 more times.
Now add in the new name. Use the hex values for the letters in the spoiler above.
Now, we have to repoint. The original pointer is A0F12408, and replace it.
My new pointer is D0258008 by the way. There are 5 cases so its a short task.
Now to see the results:
Success!
You've now successfully added a new type!
If you wanna edit pokemon or moves using programs, you're gonna have to edit the inis.
There should be 2 things you want to edit.
1. typenames or typenameoffset or something along those lines.
Change the address in this line to the address of where the name table is.
2. number of types.
To change this, first take 22 and add the number of new types you added. In my case, I added 3 new types, so I would change this to 25.
And that's it. If you read all of this, you should be able to create many new types, if you leave enough space. If you see any mistakes, please post it in the thread. Or just comment.
Credit:
coolboyman for the original thread on the type chart
MrDollSteak for his patch that includes the new Fairy type added in, and allowing me to look through the rom.
destinedjagold for his thread, which kind of convinced me to make my thread
Last edited: