News: 11 March 2016 - Forum Rules
Current Moderators - DarkSol, KingMike, MathOnNapkins, Azkadellia, Danke

Author Topic: Help with editing complex NES sprites / tilesets?  (Read 1583 times)

thetreezy

  • Newbie
  • *
  • Posts: 3
    • View Profile
Help with editing complex NES sprites / tilesets?
« on: August 16, 2019, 07:22:07 pm »
So I want to completely edit the SCARABEUS title but the tileset looks like this in Tile Layer Pro:



Is there another program that will allow me to see the tileset WYSIWIG style? What is the process of editing complex sprites like this?

Thanks!

FAST6191

  • Hero Member
  • *****
  • Posts: 2593
    • View Profile
Re: Help with editing complex NES sprites / tilesets?
« Reply #1 on: August 17, 2019, 08:09:44 am »
At this point I don't know if that is just jumbled or tile map "compression" (you have two S characters, and most of the curved tops and mid sections are common to multiple characters -- no sense putting multiple copies of the same thing in memory).

If it is just jumbled then rebuild it (probably would do manually for a basic title screen affair) in whatever your tile editor of choice has as such a thing (I tend to use tiled2002 which has a nice double click to take it to an editor).
If it is a tile map then find the mapping algorithm (I am less familiar with NES stuff ( https://wiki.nesdev.com/w/index.php/Tile_compression https://wiki.nesdev.com/w/index.php/Level_compression#Compressed_tilemaps ) than I am later stuff where it was part of the hardware, but it is still the same idea of get some extra stuff in there and the map, or hope you can either make use of the existing tiles to make what you need or you get to have fun cramming more in there when there might not be much space.


nesrocks

  • Hero Member
  • *****
  • Posts: 596
    • View Profile
    • nesrocks.com
Re: Help with editing complex NES sprites / tilesets?
« Reply #2 on: August 17, 2019, 09:30:28 am »
For uncompressed screens I use a dump of PPU memory and yy-chr for this kind of thing. Open the game on fceux, get to the screen, look in the nametable viewer in the debugger to make sure it doesn't use mid frame changes (so that this method works), then open the hex editor, dump the ppu memory to a file. Then open the file using PPU-SPLIT, it will generate a CHR, a NAM and a PAL. Rename the PAL to DAT, then open the rom on yy-chr, open the DAT. Then open the nametable editor, load the nam, and done! Sounds more complicated than it is, but now you have it so you can edit tiles and see what they do, or right click the nam editor to find a tile in the chr table.

Chicken Knife

  • Sr. Member
  • ****
  • Posts: 296
    • View Profile
Re: Help with editing complex NES sprites / tilesets?
« Reply #3 on: August 19, 2019, 03:38:54 pm »
For uncompressed screens I use a dump of PPU memory and yy-chr for this kind of thing. Open the game on fceux, get to the screen, look in the nametable viewer in the debugger to make sure it doesn't use mid frame changes (so that this method works), then open the hex editor, dump the ppu memory to a file. Then open the file using PPU-SPLIT, it will generate a CHR, a NAM and a PAL. Rename the PAL to DAT, then open the rom on yy-chr, open the DAT. Then open the nametable editor, load the nam, and done! Sounds more complicated than it is, but now you have it so you can edit tiles and see what they do, or right click the nam editor to find a tile in the chr table.
I'm interested in trying this method also. I'm curious to learn more about the advantages it yields. Also, what is the nametable editor? I'm not familiar with this.

nesrocks

  • Hero Member
  • *****
  • Posts: 596
    • View Profile
    • nesrocks.com
Re: Help with editing complex NES sprites / tilesets?
« Reply #4 on: August 19, 2019, 06:03:41 pm »
It's yy-chr's nam editor (it's the BG Set button). This method's main advantage is that you can edit existing game's background graphics without having to work the CHR like a puzzle. The dumped nametable data helps you find in the CHR where each tile is.

This is the result after you do all the steps I described. Right click any tile and it will locate the tile on the CHR table. And you can also quickly see results when you edit the CHR by looking at the nam editor.


I don't recall seeing anyone use this for hacking. I discovered PPUSplit when hacking Super Pitfall and I use it all the time.
Note that this is only for help on editing the CHR. You can edit the nametable on yy-chr but it is for previews only, there's no easy way to put that into the game unless the game uses a full screen of uncompressed nametable data which is rare.
« Last Edit: August 19, 2019, 06:12:00 pm by nesrocks »

Cyneprepou4uk

  • Full Member
  • ***
  • Posts: 176
  • Самый лысый ромхакер
    • View Profile
Re: Help with editing complex NES sprites / tilesets?
« Reply #5 on: August 19, 2019, 07:13:56 pm »
Cool, it actually worked. Thanks for the tip, nesrocks. Sadly YY-CHR.NET doesn't have a nametable editor, I hate that old version.
I am the baldest romhacker
NES Romhacking Guide

abw

  • Sr. Member
  • ****
  • Posts: 288
    • View Profile
Re: Help with editing complex NES sprites / tilesets?
« Reply #6 on: August 19, 2019, 09:42:04 pm »
*upgrades to latest version of yy-chr hosted here*
*is amazed*
*searches for more recent versions*
*sees that the yy-chr homepage is a dead geocities.jp site*
*is sad*

Wow, I wish this had been a thing a dozen years ago. It even looks like the copy/paste has been improved since the 2006 version! I remember being moderately unhappy about Zelda II's CHR layout back when I was still new to this ROM hacking thing and working on editing the title screen. Now if only you could draw on the nametable screen and have that translated back to the CHR screen... hmm, what's this, user-definable patterns (CHR screen layouts)? Looks like they come from yychr.adf, 32 bytes for the name to show in the select list and then 256 bytes for the actual layout... a little bit of hex editing should do the trick there, I think :).

A :cookie: for you, nesrocks!

Pluvius

  • RHDN Patreon Supporter!
  • Jr. Member
  • *****
  • Posts: 47
    • View Profile
Re: Help with editing complex NES sprites / tilesets?
« Reply #7 on: August 19, 2019, 10:43:58 pm »
Wish I'd known about this before I went through the trouble of extracting about half of Hokkaido Rensa Satsujin's untranslated graphics into a less useful ADF+DAT format.  At least I got compressed and uncompressed CHR data from it so it's not a total loss...

nesrocks

  • Hero Member
  • *****
  • Posts: 596
    • View Profile
    • nesrocks.com
Re: Help with editing complex NES sprites / tilesets?
« Reply #8 on: August 19, 2019, 11:41:49 pm »
Glad that people are finding it useful!
But yes, abw, I wished so much for a real time nametable drawing tool that I started to develop my own. I had to stop so I can finish my PC game, but I will probably work on it after it's done. I got to the point where I can import the PPU dump from fceux and it will load it all automatically (no need to split). I even made a change to fceux to export OAM in the same file so I can import sprites too! That way they come assembled and it should be easier to edit the CHR graphics. It also has a rudimentary 2x2 metatile generator from NAM with automatic no repeats (no export yet).
https://twitter.com/bitinkstudios/status/1066312452806197249

edit: I wanted to contact the yy-chr's developer for improvements to yy-chr but he seems to not want contact regarding that tool (due to his dead page and no contact links), so one more reason I started writing my own.
« Last Edit: August 19, 2019, 11:47:10 pm by nesrocks »

sics

  • Full Member
  • ***
  • Posts: 217
  • Contact me!
    • View Profile
    • Deviantart: Terwilf
Re: Help with editing complex NES sprites / tilesets?
« Reply #9 on: August 25, 2019, 08:26:11 am »
 For this type of tasks, a tool that helps me a lot is DjinnMapper v1.5.0.0 which, although it does not always give as good results as in this case, allows you to analyze and edit the data directly.



 This program is a hexadecimal editor that is characterized by using the graphics contained in the games to represent the data of a file, to achieve this it is necessary to navigate in the "Tile Map" section as follows:



 In this way and identified all the data it is possible to make a total edition of the title screen :thumbsup:
« Last Edit: September 02, 2019, 02:13:51 pm by danke »

nesrocks

  • Hero Member
  • *****
  • Posts: 596
    • View Profile
    • nesrocks.com
Re: Help with editing complex NES sprites / tilesets?
« Reply #10 on: August 25, 2019, 09:29:19 am »
For this type of tasks, a tool that helps me a lot is DjinnMapper v1.5.0.0

Hummm, it looks like yy-chr.net's prg editor. I'll check it out!

edit: the link you provided has a rar inside a zip that asks for a password. This link
edit2: yep, it is better than prgeditor! For one it auto loads the chr from the rom itself, among other useful features. Nice, thanks! :)
« Last Edit: September 02, 2019, 02:13:15 pm by danke »

sics

  • Full Member
  • ***
  • Posts: 217
  • Contact me!
    • View Profile
    • Deviantart: Terwilf
Re: Help with editing complex NES sprites / tilesets?
« Reply #11 on: August 25, 2019, 12:27:39 pm »
 It makes me happy to have been useful :thumbsup:

 The same thing happened to me, so I modified my version of YY-CHR to make it more similar to the .NET distribution, at the same time I took the opportunity to translate it and expand the CHR file.



 I have never shared it because I really did not know if this was legal, but considering that the official site died I could finish translating and publishing it.
« Last Edit: August 25, 2019, 12:49:27 pm by sics »

Cyneprepou4uk

  • Full Member
  • ***
  • Posts: 176
  • Самый лысый ромхакер
    • View Profile
Re: Help with editing complex NES sprites / tilesets?
« Reply #12 on: August 25, 2019, 01:14:17 pm »
sics, do you know how to edit plugins for net version?

Nevermind that now. I wanted a plugin to display tiles in 8x16 sprite mode for nes. Thanks to this guide now I know that I simply need to change "Pattern" option to "FC/NES x16"
« Last Edit: August 25, 2019, 04:30:26 pm by Cyneprepou4uk »
I am the baldest romhacker
NES Romhacking Guide

sics

  • Full Member
  • ***
  • Posts: 217
  • Contact me!
    • View Profile
    • Deviantart: Terwilf
Re: Help with editing complex NES sprites / tilesets?
« Reply #13 on: August 25, 2019, 02:00:44 pm »
 I'm sorry, it's not my area ;)

nesrocks

  • Hero Member
  • *****
  • Posts: 596
    • View Profile
    • nesrocks.com
Re: Help with editing complex NES sprites / tilesets?
« Reply #14 on: August 25, 2019, 03:18:26 pm »
That's incredible how did you mofidy it?

Cyneprepou4uk

  • Full Member
  • ***
  • Posts: 176
  • Самый лысый ромхакер
    • View Profile
Re: Help with editing complex NES sprites / tilesets?
« Reply #15 on: August 25, 2019, 04:19:24 pm »
It appears that our japanese dude is still working on his net version. Program was updated 2019-07-19 (happy birthday to me  ;D)

sics, just checked that tile editor. Holy crap, it is amazing, at least for a noobie quick search of wanted data
« Last Edit: August 25, 2019, 06:03:08 pm by Cyneprepou4uk »
I am the baldest romhacker
NES Romhacking Guide

nesrocks

  • Hero Member
  • *****
  • Posts: 596
    • View Profile
    • nesrocks.com
Re: Help with editing complex NES sprites / tilesets?
« Reply #16 on: August 25, 2019, 05:44:12 pm »
Link please? Geocities has ended. http://www.geocities.jp/yy_6502/yychr/index.html

Cyneprepou4uk

  • Full Member
  • ***
  • Posts: 176
  • Самый лысый ромхакер
    • View Profile
Re: Help with editing complex NES sprites / tilesets?
« Reply #17 on: August 25, 2019, 05:57:20 pm »
Made it bolder in the previous post so you can see it better

This one is a direct for downloading
I am the baldest romhacker
NES Romhacking Guide

nesrocks

  • Hero Member
  • *****
  • Posts: 596
    • View Profile
    • nesrocks.com
Re: Help with editing complex NES sprites / tilesets?
« Reply #18 on: August 25, 2019, 06:29:16 pm »
Sorry, hadn't seen it. :) Wow, now you can zoom the entire program! Finally!

Cyneprepou4uk

  • Full Member
  • ***
  • Posts: 176
  • Самый лысый ромхакер
    • View Profile
Re: Help with editing complex NES sprites / tilesets?
« Reply #19 on: August 25, 2019, 06:42:23 pm »
Well, duh, you could do it in the previous net version also  :police:
I am the baldest romhacker
NES Romhacking Guide