Users browsing this thread: 1 Guest(s)
A Tip for Ripping Genesis Sprites
#1
********************* TheouAegis' Useful Genesis Ripping Tip *********************

Alright, well, this morning I decided to try using a tile viewer to rip Urban Strike. I was hoping it would be cut and dry like the GeGeGe no Kitarou game on the SNES which so handily preloaded sprites. Nope, not the case with Urban Strike. What you see on the screen is what you get in the tiles, basically. However, some sprites were actually preloaded, such as the helicopters' rotors and background tiles (the land ones). This gave me an idea.

As anyone that's tried ripping Genesis sprites knows, Genesis programmers loved using full black instead of off-black, which Nintendo I guess encouraged. Coupled with the lack of clearly defined layers in the Genesis, this makes layer ripping impractical due to many sprite outlines being in full black like the delayered background. So, I devised a workaround for this.

What You Will Need:
*A mainstream emulator like Kega Fusion or DGen (or what works best for you)
*YY-CHR (a very nice tile editor)
*a ROM image of the game you want to rip

Optional Components
*Kega Fusion (it has a built-in AVI recorder
*VirtualDub (Kega's AVI's are recorded at 2x size, which isn't submittable here)
*AVI editor preferably with pruning functions (i.e., take non-repeating frames)


WARNING: This will not work with tiles that get reloaded into the video memory. Also, clearing the video memory via actions like bringing up a pause menu can potentially reset tiles you have altered with my method. As such, it is primarily for blocking out background tiles and preloaded or overlapping sprites (such as the rotors in the Strike series).

Load up the game in the emulator and find the spot you want to rip from. Save the state. The file will probably have a .GS* extension, where the asterisk is either an 'x' or a number from 0 to 9, depending on the emulator. Note: Kega Fusion and DGen use the same state format, so you can load a DGen state into Kega Fusion by using the "Load State As..." option in KF.

Now load YY-CHR and open the state file you just saved. Make sure the decoder drop-down menu is set to "4BPP MSX (/Genesis)". Scroll down and find some numbers or letters (or parts of numbers and letters, since some games are programmed to combine tops of some letters and numbers with bottoms of others, like an old analog alarm clock). Press + or - until the numbers/letters become clearly readable and are entirely within their 8x8 box (set the view size to "16x" and click on a tile to zoom in on its 8x8 box).

Once you're sure enough everything's lined up right (easier said than done), scroll through the tiles until you find the background tiles. These are usually clumped together. On a Genesis, these can be hard to distinguish from extra code, especially on games with poor graphics (e.g., Urban Strike, et al). The best advice I can give here is to look for a clump of tiles that don't have big, straight lines running through them. If you haven't already set up your palette, this step will be much more difficult.

Now, here's my trick. Once you found the tiles for the backgrounds, go to the palette picker on the right side. Of the 32 usable colors, left-click on one that's not on the far left (the transparent color). Set your view size to "1x" or "2x" and move the tiles so only the background tiles are in view. Now use the Quadrangle (fill) tool to completely cover the background tiles. You don't want to leave any pixels missed, but don't fret over it as it will be easy to fix.

Once you're done covering the background tiles, click the "Save" icon (the yellow floppy disk). Warning: Make a backup copy of your save states before you save any changes you make in YY-CHR. Go back to your emulator and load the state. If you did everything correctly, the background tiles and only the background tiles should be one uniform, non-black color. If you missed any pixels or tiles, it will be very obvious. In such a case, just go back to YY-CHR and touch-up the tiles (don't forget to save!).

Now when you take screenshots or video screen captures of the game, everything will be on a colored background instead of a black background. For skies and such that are only one or two colors, you don't need to worry about coloring them this way. Basically, you just want to limit your screenshots to the sprite layer and no more than four unused colors.

I took this trick one step further when ripping Urban Strike. While I could easily rip every frame of animation with the helicopter and its rotors, this would take waaaaaaaay too long, make the sprite sheet's file size waaaaaaaay too big, and make using the sprite sheet waaaaaaaaaay too difficult for anyone who wanted to use it. And since Urban Strike's programmers didn't preload sprites, copying from the tile viewer wouldn't be efficient either. So what I did was find the tiles for the helicopter rotors and fill them in (with Quadrangle (fill) tool. Then when I went back to the game, the helicopter no longer had its rotor. I could then use Kega's AVI logger to record every frame of the helicopter's sprite without the rotors getting in the way!

A Note On Deleting and Filling Tiles in YY-CHR: There are two methods I mentioned in this guide, which should be pretty obvious, but I will explain them briefly anyway. You can edit out tiles completely in one of two ways -- either use a (fill) tool on the right half of YY-CHR or select and delete with your DEL key on the left half of YY-CHR. Using a (fill) tool will leave the tile in the game, but as whatever color you picked to fill it with. If you actually delete a tile, it would be treated as using a (fill) tool with the transparent color. As such, tiles that get reloaded automatically (e.g., the helipads in Urban Strike) will always be reset regardless of which method you use. More importantly, deleting a tile will let you see any tiles drawn below it in the game, but deleting a background tile will result in a solid black tile in its place (unless your emulator's set to a different color or you hack the rom).
Thanked by:
#2
I might as well reply to this considering that I ripped a fair few Genesis games in my time and you want to know as well.

Right, tile ripping from the ROM I would use TileMolester since it is quite simple to use and it imports palettes made by DebuGens (the Tile Layer Pro format) or the regular type. However if the game is compressed that is not "Nemesis"* (there are lots of these), stored too weirdly to make out or only half the sprites there, my emulator of choice would be GensKMod using a custom one made by Dazz that uses a pink background. It displays the sprites rather like the OAM viewer of VisualBoyAdvance, it displays the VDP that you can copy and paste since the dump sprite button is broken in every release. Oh and sometimes I use GSavestate if I want to rip a background or in the case of the game uses black for everything.

* - There are some games that use the Nemesis compression dubbed by the discoverer of the format such as Sonic 1 & 2/Castle of Illusion/Mega Modem games/Pulseman/etc, there is an Nemesis Search tool that decompresses all or most of the compressed sprites of that game but you have to know command line to run it.

As for what you're saying about preloaded sprites, some Genesis/Mega Drive games mainly very early games do store all the frames of a boss or an enemy like Revenge of Shinobi, Shadow Dancer, Streets of Rage 2. The savestate format is official known as Genecyst format since it was the first working Genesis emulator and appeared in most emulators (Gens and offshoots like GS, KMod/Kega/Regen/DGen), however it isn't 100% compatible across emulators so you can import one made by Gens into Kega but the opposite may not work depending on game.

Your method is quite good, it seems similar to Maxim's method (except that he used GSavestate) and might even use that in some point but not the FRAPS part.

Also a word of warning, I don't think the Strike series would be easy to rip considering that it is stored weirdly in the ROM. Techokami who is a much better ripper than I'll ever be couldn't do it, he only managed one sprite and he wasn't sure that he did it correctly. I give you good luck though and will look forward to seeing it.
Thanked by:
#3
Hence why I threw in that bit about FRAPS. In both the Genesis and SNES versions of the STrike series, as I said, they're basically straight ports because they're just as crappy. It was also how I was able to locate the background tiles and rotors pretty easily -- once I found them in the SNES port, I could go back and find them in the Genesis port.

I know preloading sprites takes up more memory, but it's to the game's benefit. I mean, I could sense a difference in gameplay between Urban Strike and GeGeGe no Kitarou: Fukkatsu! Tenma Daiou. The latter plays much more smoothly. Why? Because all of Kitarou's sprites are preloaded, all of his helper's sprites are preloaded, and for each stage all of the enemy sprites (typically only 3) are preloaded. The only thing not preloaded, understandably, are the palettes. While Urban Strike, on the other hand, tends to get choppy and have some minor slowdown. Super Metroid preloads the enemy sprites and weapon sprites, but not Samus', I've noticed. So some slowdown when Samus moves, but not as much in a heavy gunfight as in other games. So like I said, I think it's in the game's best interest to preload sprites. That and it makes it easier to rip. Big Grin

I saw that GensKmod or whatever in another post and took a look at it. You said Dazz made a mod of it? Where's that? I'll check them out, see how I like them, cuz my method has some uses but is still fairly tedious. Like I said though, it works for Urban Strike because the backgrounds are clustered neatly together (too neatly >_<).
Thanked by:
#4
I edited my guide somewhat. Now instead of Fraps, which anti-aliases crap for some reason, I suggested using Kega Fusion, which has a built-in AVI recorder that won't anti-alias. The onl,y problem is it records at 2x magnification, so you need VirtualDub to resize it back down to 320x240 resolution.
Thanked by:
#5
camtasia has a solid screen capture codec you might want to try.
Thanked by:
#6
I found a problem with my method. If the game reloads a tile into the CPU (which happens with most animated sprites), the edit gets reset. It works for background tiles and the rotors in the Strike games because they're preloaded, but anything not preloaded will get reset and make this method useless for deleting them. You'd have to hack the actual rom if you wanted some tiles to NEVER appear in the game while you were ripping.

But it's still a handy trick.
Thanked by:
#7
Quote:YY-CHR can only undo up to two steps.
What version of YY-CHR are you using O_o
Thanked by:
#8
Shocked .97 beta 31..... Why? Surprise

.... Wait wtf? I just opened it cuz you made me curious. I tried making lots of doodles. And it let me undo them all. But before it was only giving me two undos. ...... Ok so nevermind about that.

*edits old post*
Thanked by:
#9
Exclamation 
Guys now you don't need even to hack savestates!
The simple LUA script was created to change the canvas color any way you like!
It works only with Gens-rr 11b & Gens11svn296
http://code.google.com/p/gens-rerecordin...loads/list

Code:
gens.registerbefore(function(address,size)
  local p,t=vdp.readpalette(1,1);
  local c=pal.getcolor(t[1],1);
  c.A=255;
  c.B=255;
  c.G=0;
  c.R=255;
  pal.setcolor(t[1],1,c);
  vdp.writepalette(1,t[1]);
end)
Download this script here:
http://feos-theos.narod.ru/Gens11b-Canvas-Color.lua

I don't know what does c.A= do, but the rest are RGB setup for backdrop color.


Attached Files
.zip   Gens11b-Canvas-Color.zip (Size: 285 bytes / Downloads: 264)
Thanked by:
#10
although this rather belongs to the ripping part of this forum, i'd leave a global mod decide if you either want to move it or close it, given the bump provided solid info.
Thanked by: Chris2Balls [:B]
#11
Yeah, I'll move it.
Specs 'n' Headphones has been revamped! Check it, yo.
[Image: 10y3mgj.png][Image: groove-1.gif]
Thanks to Pik and Solink; they are sexy people. Heart
Thanked by:
#12
http://code.google.com/p/gens-rerecordin...1svn306.7z

Quote:* Graphics: Added "Pink Background" option and hotkey.
Flag is stored to config.
Color is "Magic pink", r=max, g=0, b=max.

* Graphics: Toggled layers now are saved to config as well.
TODO: Figure out hex value for pink for mode_555.
TODO: Configurable backdrop color (is it needed?)

This freaking toggle now works for any game, even though Sonic or, say, Tiny Toons, use not zero color as backdrop. Toggled layers now get remembered between sessions.

Plans: add turbo toggle. add "save screen to clipborad".
Thanked by:
#13
Ha, I created the same application about 6 years ago. This will probably work better than mine though Tongue
Tsunami Bomb - The Simple Truth
We could run away
Leave behind anything paper
Not knowing where we're going to stay
When there's no Mondays

You're part of me, it's so easy to see the simple truth
When I'm in your arms, I feel safe from harm and sorrow too
You're part of me, it's so easy to see the simple truth
But most of all, nothing couldn't be solved when I'm with you
Thanked by: Ton


Forum Jump: