• Our software update is now concluded. You will need to reset your password to log in. In order to do this, you will have to click "Log in" in the top right corner and then "Forgot your password?".
  • Forum moderator applications are now open! Click here for details.
  • Welcome to PokéCommunity! Register now and join one of the best fan communities on the 'net to talk Pokémon and more! We are not affiliated with The Pokémon Company or Nintendo.

Indexing and Inserting Sprites

destinedjagold

You can contact me in PC's discord server...
8,593
Posts
16
Years
  • Age 33
  • Seen Dec 23, 2023
destinedjagold's Sprite Indexing and Inserting Tutorial
updated
Before anything else, here's RedYoshi's Indexing Sprites Tutorial, where I based my tutorial.
Oh, and if you find this tutorial difficult to understand, try viewing the video tutorial I have uploaded entitled 'How to Insert Sprites'


Introduction...
Okay, so hi everyone. I am destinedjagold, a ROM hacker/modder who stinks at spriting, but is showing you a spriting tutorial. o.O
Anyways, this thread is updated now since I lost my images. Blame PhotoBucket -__- ...
Anyways, I hope you'll find this tutorial useful, and pardon me for reusing this old thread of mine.
Since I saw this thread's still open, I decided to update it instead of making a new one. Might be a waste of space in the forums.

What You Need...

  • [*]ROM
    [*]Unlz-GBA
    [*]MS Paint
    [*]Your sprite
    [*]IrfanView
    [*]Hex Editor (I'll be using Hex Workshop)

Before Anything Else...
Remember to make a back-up of your ROM. Just in case you messed something up.
Remember the golden rule in ROM-hacking... "SAVE BACK-UP"...


STEPS

Step 1...
1. Open your sprite through MS Paint. Then resize it to 64x64. If it's too big, then you'll have to reduce it. How? It's up to you. :\
2. Pick a colour which is not used by the sprite. Exampe, HAUNTER has a purple pallete, so you have to use Yellow or Orange or Cyan as it's back colour.
Spoiler:


Step 2...
1. After you saved your 64x64 sprite, open it with IfranView (if you don't have one, Google it).
2. Then on the 'Image' tab, click the 'Decrease Color Depth'.
3. A little window will show up. From 256, change it to 16 colors and press 'Ok'.
4. Then go to the 'Image' tab once again, but this time, go to 'Palletes' and click 'Edit Pallete...'.
5. A window will show up. You will see all 16 colours the sprite uses. On the left-most pallete/color, change it to the same color of the background color. Then change the other color which is the same color as your background color to the color you replaced in the left-most pallete/color.
6. Click 'Ok'. Then you'll have to save it. But here's a trick to make things easier. Don't replace your old 64x64 sprite. Save it with a different name.
Spoiler:


Step 3...
1. Open both your sprites;the IrfanView and the MS Paint ones.
2. Press CTRL+A or Select All on your old 64x64 sprite, and then Copy it.
3. Paste it on the MS Paint where you opened the sprite you edited through IrfanView. This will lessen the burden of fixing your sprite, in case it has been pixelized by IrfanView.
4. Save it. In this step, you can now delete the unindexed sprite to avoid confusion.
Spoiler:


Step 4...
1. Open your ROM with Unlz-GBA.
2. Find the old PKMN sprite you want to replace.
3. Click on the 'Import' button and select your newly indexed sprite.
4. Click the 'Write to ROM' button.
5. A window will pop-up. Check the 'Automatically Fix Pointers'.
6. Open your ROM with a Hex Editor and find a free space for your new sprite. You can use FSF as well if you want to. Memorize the free offset.
7. Close your FSF, or any programs that opened your ROM as well, such as A-Text or A-Map and the like.
8. Type the offset on the 'Image Offset' box. Don't remove those two zeros.
9. Click on the OK button and you're done. If a pop-up window appears and states 'Ptr found at <offsets go here>. Changed.'.., then it means that you have successfully inserted a new sprite, or rather replaced an old sprite for a new one! Horay!
10. You can do the same for it's palletes, of if you're too lazy to run a search for free offsets, you can use APE or just check the 'Export Pallete', but remember to uncheck the 'Automatically Fix Pointers'.
11. Test it out on your ROM.
Spoiler:



Continuation...
Indexing the backsprite...
June 4, 2009

Introduction...
Okay... Now you know how to index and insert your new POKéMON's front sprite.
But now you ask, how to do the backsprite?
It's quite simple, actually...
Now, I'm gonna use Stormidran, Samson's fakemon.
33u8u3s.jpg


I am assuming that by this time, you already know how to index your front sprites...
Spoiler:



STEPS

1. Open both your POKéMON's front and back sprites...
Spoiler:

2. Select All, then Copy your back sprite and paste it to your front sprite. Don't forget to make the background the same as your front sprite...
Spoiler:

3. Open the back sprite of the POKéMON that you will replace. In this example, I'll replace Tropius...
Spoiler:

4. Select All, then copy the back sprite of the POKéMON you'll replace and paste it to your back sprite. Notice that both back sprite is 'cut'. If you aren't bothered, put a line starting from the replaced POKéMON's back sprite to your new back sprite...
Spoiler:

5. After doing that, you should put the 'cut' of your new back sprite on the line, so it won't look floating on the game.
Spoiler:

6. After making sure that the new sprite's on the same level of the replaced sprite, turn it back to 64x64 in size, save it, and it should be in .png format...
Spoiler:

7. Then, open your ROM in Unlz-GBA and go to your replace-to-be back sprite. The same to inserting the front sprite, first try if you can insert it by checking both 'Auto abort if new data is bigger' and 'Export Image'...
Spoiler:

8. And if your new sprite's bigger, simply search for free offset, click 'Auto abort if new data is bigger', 'Export Image' and 'Automaticly Fix Pointers'...
Spoiler:


Note...
You might be asking about the back sprite's pallete if it will also be included to export.
Well, since you already inserted the front sprite along with the front sprite's pallete, you need not to export the back sprite's pallete, as long as you copied your back sprite and pasted it on your indexed front sprite.


Message...

Okay. I hope that this will help you all to insert new sprites for your hacks/mods. ;)
I had fun updating this tutorial though.
Thanks for sparing time to read this tutorial. :)
Well, good luck and have fun hacking/modding!
 
Last edited by a moderator:

X-aveon

IS BACK!!!!!!!!!!!!!!!!!!!
233
Posts
16
Years
  • Seen Jun 25, 2012
will this overwrite the oddish sprite? or put this sprite somewhere else in the rom. if you do that, how will you be able to find it to edit the attacks.???
 

Ryousha

Waiting for Gen 4 Remakes
954
Posts
16
Years
will this overwrite the oddish sprite? or put this sprite somewhere else in the rom. if you do that, how will you be able to find it to edit the attacks.???

It repoints the data,

though if u still look in unzl, it's still there, just not useable anymore ;).
 

Lollypop

Member since '07 <300 posts
250
Posts
16
Years
Thanks Alot! I've been waiting for a tutorial like this. I've read red yoshi's tutorial but I couldn't quite understand it. Thx alot!!
 

destinedjagold

You can contact me in PC's discord server...
8,593
Posts
16
Years
  • Age 33
  • Seen Dec 23, 2023
will this overwrite the oddish sprite? or put this sprite somewhere else in the rom. if you do that, how will you be able to find it to edit the attacks.???

it doesn't replace Oddish's sprite. we're telling the ROM that the oddish will have the Giratina sprite located in offset 845000...

also, you can edit Oddish's data/stats/moves/type/etc for your new pokemon inserted. ;)
 

Cy-Chan

GSC Hacker
152
Posts
19
Years
Gosh, is it me, or is pallete editing normal image files a huge pain in the stomach? Either way, this is a great tutorial, and it really gave me some insight.
 

Cura

[color=DarkCyan][i][b]I see nothing! I know nothin
1,101
Posts
15
Years
Honestly, i must THANK YOU! this is the tutorial i needed for spriting... :)
RedYoshi's tutorial was great too. Thank you.
 

Mario_Bones

Lazuli Version Creator
42
Posts
15
Years
Ah, that's how you get free space to work. Thanks a bunch!
EDIT: I tried it, and inserted a sprite over Mudkip in Ruby. When I chose the Pokemon in Birch's bag, the game froze... What do I do?
EDIT2: I used the Free Space you used in your tutorial and it worked fine. I think the Free Space that I got from Free Space Finder may have been wrong or something. How do I use a Hex Editing Program to find free space?
 
Last edited:
23
Posts
16
Years
  • Seen Apr 24, 2011
nice tutorial!, but I have a bit of a problem... when i try to insert a lucario sprite (indexed, 64x64) over the gulpin one in firered, all it changes is the palette, not the actual sprite...any help?
 

destinedjagold

You can contact me in PC's discord server...
8,593
Posts
16
Years
  • Age 33
  • Seen Dec 23, 2023
Ah, that's how you get free space to work. Thanks a bunch!
EDIT: I tried it, and inserted a sprite over Mudkip in Ruby. When I chose the Pokemon in Birch's bag, the game froze... What do I do?
EDIT2: I used the Free Space you used in your tutorial and it worked fine. I think the Free Space that I got from Free Space Finder may have been wrong or something. How do I use a Hex Editing Program to find free space?

no idea why it does that, sorry. :\
Also, I am not using Free Space Finder.
I clearly stated how to use a hex editor in the tutorial.

nice tutorial!, but I have a bit of a problem... when i try to insert a lucario sprite (indexed, 64x64) over the gulpin one in firered, all it changes is the palette, not the actual sprite...any help?

Yes, it doesn't replace the sprite.
Have you tried meeting up with Gulpin(or rather, Lucario) in the game?
 
23
Posts
16
Years
  • Seen Apr 24, 2011
I just tried what you said, and when i got into a wild pokemon battle with gulpin(lucario) and the screen went pitch black. I then went into pokemon editor pro and changed the image offsets for gulpin to the new ones it had in the top right of unlz, and went to meet gulpin again, this time though, it just showed the sprite of the messed up gulpin.

EDIT: I tried it again but with swalot and a darkrai sprite, this is this the result:
http://i240.photobucket.com/albums/ff251/jamieboy30/problem.jpg
 
Last edited:

destinedjagold

You can contact me in PC's discord server...
8,593
Posts
16
Years
  • Age 33
  • Seen Dec 23, 2023
are you sure that the image is 64x64...?
also, is it in .PNG format?

post your sprite here and I will try and fixing it if what I stated above are true in your case. :\
 

destinedjagold

You can contact me in PC's discord server...
8,593
Posts
16
Years
  • Age 33
  • Seen Dec 23, 2023
oh, I see. good to hear.
good luck with your spriting projects! ;)
 
23
Posts
16
Years
  • Seen Apr 24, 2011
are you sure that the image is 64x64...?
also, is it in .PNG format?

post your sprite here and I will try and fixing it if what I stated above are true in your case. :\

Okay, here are the sprites:

DARKRAI.png


LUCARIO.png


I replaced gulpin with lucario, and swalot with darkrai if that helps.

Thanks. :)
 

destinedjagold

You can contact me in PC's discord server...
8,593
Posts
16
Years
  • Age 33
  • Seen Dec 23, 2023
okay... they work pretty fine and perfect in my case. :\
Spoiler:


I really do not know why it doesn't work in your case. however, I am also sure this works in FireRed as well.
I got no time though, busy in real life. :\
but if you wish, I can post some proof that this method does work in FireRed as well. But maybe later. :\

Maybe you have overwritten an offset which was already have been used. :\


EDIT

here's proof that it also works with FireRed. :\
Spoiler:
 
Last edited:
23
Posts
16
Years
  • Seen Apr 24, 2011
thanks alot for the help, I'm gonna try using the program that you're using to find the offsets, I think it may be down to the fact that I'm using FSF, but I may be wrong, but thanks again for all the help you've given me :)
 
55
Posts
15
Years
  • Seen Apr 28, 2009
This probably isn't the right place to post this, but I've been trying to take the hero sprite from one ROM and put it in another. Is there a tutorial/program that would let me do that?
 
Back
Top