PDA

View Full Version : Tutorial: [Graphics] Editing NCGR files (images) on NDS ROMs



Platinum Lucario
07-28-2012, 06:08 PM
Hey everyone! Davin (aka Platinum Lucario) here.


NOTE: This is an old tutorial that I have made on another forum, but I have indeed copy and pasted it to here, so that others will be able to see, I have fixed it up a bit as well. But the reason I would choose this tutorial than the ones that recommend using Tinke... is because Tinke will change the palette to a palette with less colours than what you need in the picture.

Have any of you been frustrated trying to edit the title screen or any other image that is compressed on an NDS ROM? I'm sure plenty of you have looked through at other tutorials and aren't explained properly, I'll explain it all in full detail. The solution to editing the images on any NDS ROM has finally been revealed! Of course... at first I was frustrated that I had trouble editing the title screen of a Pokémon Black ROM myself. This tutorial will work for any NDS ROM that has NCGR files in it. Alright! Allow me to explain!

Here's what you'll need:


Any NDS ROMs that have NCGR files in them (an .nds file).
An Emulator (I would recommend using the latest version of DeSmuME).
Crystal Tile 2. Which you can download the latest version here (http://filetrip.net/nds-downloads/utilities/download-crystaltile2-20100906-f23649.html)
DSBuff. For unpacking and packing the ROM (if you need to, but will trim the ROM).
Backups! Very important if you make a mistake.
ConsoleTool, Tinke or Tahaxan. For viewing the image, just incase anything goes wrong. [Optional]
ConsoleTool v30. For changing the palette, but you can use CrystalTile by double clicking the colours on the palette tab.

Alright... if you've got those tools, then lets get started!

Step 1: Open up DSBuff and then click the browse icon and search for the ROM. Once it's selected, click on Unpack.
http://img703.imageshack.us/img703/8343/tutorial1k.png

Step 2: A window appears after your ROM has been extracted. Now... open up Crystal Tile 2 and browse the unpacked ROM folder, open up an .narc file or any of the numbered files in those numbered folders in the "a" folder. For this tutorial, I'm using the file in a\0\2\6.
http://img26.imageshack.us/img26/4909/tutorial2xr.png

Step 3: The Sub menu will appear, which contains a list of different files. Then you'll see a verity of files shown there, make sure you export the .NCGR the .NSCR and the .NCLR files when doing so. Just right click the file and click Export. Note that some files may be compressed, the compressed files have the extention .l on them, so they'd be like .NCGR.l, for the compressed files, you will need to Uncompress them by right clicking then clicking "Uncompress".
http://img11.imageshack.us/img11/3738/tutorial3j.png

Step 4: Once the files have been exported or uncompressed, then open up the .NCGR file with Crystal Tile 2, once it's opened, click the picture icon, which is the tile editor. Now... once you've clicked on tile editor, you'll notice there's alot of green and black specs displayed, you'll have to fix it, right? In the properties tab in the tile properties area, where it says "Tile form", change it from solid 1bpp to GBA 8bpp. Now you'll see a scrambled up image looking in some shape. However... there is a problem, the colours are incorrect.

NOTE: Depending on what image you're using, the format may vary. Usually most are GBA 4bpp or GBA 8bpp.
http://img191.imageshack.us/img191/1410/tutorial4a.png

Step 5: Click on the palette tab, then click on the import button and select the .NCLR file that you exported earlier, now you'll see the image in proper colours. But... it's still scrambled, oh dear!
http://img5.imageshack.us/img5/7356/tutorial5x.png

If your image has different colours on it, you might wanna edit the NCLR file with consoleTool_v30 (which I find is easier editing palettes than Crystal Tile 2).

Step 6: To fix up the image... in the tile property area, click the drop down box where it says "image pattern" and change it from Tile to ObjH-1234 or ObjV-1234, depends on what image you're editing. In this tutorial, I'm using ObjH-1234 for editing the title screen. Now... here's the tricky part, you must change the width, height and byte jump numbers in the Tile property area... and sometimes Crystal Tile 2 can crash while you're changing it with the ↑ and ↓ arrow keys while you've got the numbers selected. It's best to make sure there's only one tile in the grid, which can be decreased by making the width and height a pretty large number. For this tutorial, I made the title screen under the byte jump of 48, the width of 256 and the height of 144. Once it's done successfully, you'll notice the image perfectly working.
http://img69.imageshack.us/img69/2523/tutorial6d.png

Step 7: Alright, now that you've got the image fitting perfectly, it's time to insert the image you'd like to replace the image that is currently being used. To do that, click on import button (the button with the page and an arrow going down) or click Edit > Import image. Select the image you'd like to replace, then the image appears on the picture. Double click the image you've imported, if it disappears... you'll need to change the canvas size of your imported image using Paint.NET, change it to a size that fits the same width and hight as the image that is being used in the game. Once it's successfully in, save it!

NOTE: If CrystalTile2 crashes upon importing your file, then you'll have to do it manually. This (http://pokecheats.net/forum/showthread.php?14271-Tutorial-Graphics-Editing-NSCR-files-%28how-to-map-the-graphics-on-NDS-ROMs%29) tutorial explains how to import files manually with a hex editor.
http://img694.imageshack.us/img694/1606/tutorial7.png
http://img11.imageshack.us/img11/5903/tutorial8p.png

Step 8: Now... to test the image, create a folder, but first... copy and paste the folder "NDS_UNPACK" somewhere else. OK and now create a new folder then put in the overlay folder from Pokémon Black/White and all of it's contents in the new folder you created, make sure the arm7, arm9, banner, header, y7 and y9 are placed in the new folder as well and create a folder, name it "data" and put in the NCGR, NSCR and NCLR files in the data folder. Once you've done that, make sure the folder is named "NDS_UNPACK", otherwise DSBuff will not recignise it when you copy and paste the folder to replace the NDS_UNPACK that was there. After that, pack the ROM and name it to anything. I named it "titlescreen-test.nds". After that, open up Tahaxan and open up the ROM and check out the image and see if the .NSCR file is working properly with the other two files.
http://img534.imageshack.us/img534/4781/tutorial10l.png

NOTE: As you can see, I tried inserting a bigger image than the original, so it came out wrong when the NSCR was in effect.

Step 9: If things are working out alright for you, then open up Crystal Tile 2 and open up the .narc file you were using previously. The Sub menu will appear. Now right click the file you wish to replace... and right click and then click import (or Compress if you're importing a file that was once compressed). Now select the NCGR, NSCR and NCLR files and import (or compress if it was compressed before) each one into the NARC file.
http://img28.imageshack.us/img28/8670/tutorial11.png

Step 10: Copy the backed up NDS_UNPACK folder and paste it into the dsbuff folder, which you always will have upon using DSbuff. Open up DSbuff and click "Pack" and save it anywhere you'd like.
http://img51.imageshack.us/img51/9878/tutorial12r.png

Here's how mine turned out at the time. Oh well... that was 2 years ago, but now things have changed. I know how to edit NSCR files now, this (http://www.pokecommunity.com/showthread.php?t=285198) tutorial will explain how to edit NSCR. Anyways, you can still view that screenshot of my failure at the time. lol
http://img842.imageshack.us/img842/3278/tutorial13.png

Anyways, thanks for reading! Hopefully this tutorial will come in handy for anyone who wishes to know how to edit the graphics. ^^

pikalaxalt
10-06-2012, 06:02 PM
Okay, now how did you get the tiles to line up properly? I'm having a lot of trouble with that as there are blank bytes that CrystalTile2 is ignoring.