TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Street Fighter II paper trails – allocating sprite space by hand

554 pointsby krajzegover 3 years ago

22 comments

allenuover 3 years ago
I love Fabien Sanglard&#x27;s work. I&#x27;ve read through his books on Doom and Wolfenstein and never would&#x27;ve imagined he&#x27;d start looking at sprites for Street Fighter II.<p>This is really great stuff and I think important as &quot;developer archaeology&quot;. The 80s and 90s don&#x27;t seem that long ago (to those of us who were around), but it&#x27;s easy to forget people back then didn&#x27;t have the sophisticated tools we have today. That said, people <i>did</i> have tools, so it&#x27;s awesome to be able to get a glimpse into the workflow of folks back then.
评论 #29661699 未加载
im_down_w_otpover 3 years ago
I absolutely love learning about the clever tricks and their long-tail effects that came out of dealing with incredibly resource constrained computing environments and&#x2F;or where some quirk of hardware ended up inspiring a lot of fabulous creative misuse.<p>This is a fantastic article!
kingcharlesover 3 years ago
I was one of the developers on this game in the 90s:<p><a href="https:&#x2F;&#x2F;www.youtube.com&#x2F;watch?v=lubyi79e6SY" rel="nofollow">https:&#x2F;&#x2F;www.youtube.com&#x2F;watch?v=lubyi79e6SY</a><p>It was meant to be 100% 2D, and the programming and art went down that path for a few months before it was realized that there just wasn&#x27;t enough RAM on PCs of the time to store all the possible sprites for the characters in every rotation. The numbers get out of hand very quickly when you have four main characters, each of which can walk in 8 or 16 directions, can also run, walk up stairs, climb ladders, crawl, fire one of 20 different guns etc. The isometric backgrounds are all sheets of 2D tiles, laid out just like in Street Fighter and every other sprite based game.<p>So, several months into development it was decided to change all the characters to 3D to save RAM. I switched the entire game over in two weeks, including creating all the tooling to convert from 3D Studio to.. whatever the fuck, because there were no rules in those days. When that game was started there were almost no 3D accelerators, and I don&#x27;t remember if you needed specific SDK for them. I seem to remember our game couldn&#x27;t use them, perhaps because of the way the 3D and 2D were composited in the frame, which was very unusual - most games were either 2D or 3D, not a combination.<p>Are there any easter eggs hidden in the sprites for SFII? There were various ones in Abomination, mainly written in the graffiti around the cities.<p>And then there are ones like this (TFT) that we can&#x27;t talk about: <a href="https:&#x2F;&#x2F;www.reddit.com&#x2F;r&#x2F;gaming&#x2F;comments&#x2F;3ylmm4&#x2F;a_staggering_127mb_san_andreas_bridge_facts&#x2F;cyethcv&#x2F;" rel="nofollow">https:&#x2F;&#x2F;www.reddit.com&#x2F;r&#x2F;gaming&#x2F;comments&#x2F;3ylmm4&#x2F;a_staggering...</a>
评论 #29716960 未加载
评论 #29659449 未加载
Waterluvianover 3 years ago
When writing a DMG emulator I thought about how these tiny sprites are often similar. A sprite will be a series of bytes with an address to the beginning.<p>It got me thinking about a kind of compression algorithm could find byte overlaps and re-pack the sprites, and then adjust the addresses.<p>This got me thinking: are there any compression algorithms that do not require decompression? You pack them once and then just point at slices.<p>Then this got me thinking: is that just what unzipping is doing, just eagerly?
评论 #29659202 未加载
评论 #29658997 未加载
评论 #29659861 未加载
评论 #29658861 未加载
评论 #29659062 未加载
评论 #29660190 未加载
评论 #29660928 未加载
rmetzlerover 3 years ago
I remember another article where the main developer set aside a big chunk of memory right when they started coding. When they had issues fitting everything in memory shortly before the deadline, he deleted this chunk and had no issue to deliver the project.<p>I think this is something we should do more today. Defining a memory budget, and staying inside.
评论 #29662851 未加载
评论 #29661768 未加载
评论 #29660958 未加载
评论 #29668114 未加载
mewse-hnover 3 years ago
I love that we can dig into rom images from 30 years ago and recreate sprite sheets that were originally hand drawn for something that was an important part of our culture. What more I love that Fabien <i>actually does it</i> and shows us how it&#x27;s done.
评论 #29660607 未加载
ben7799over 3 years ago
Loved this article. SFII was so huge when I was about 13-20... that game had such a long tail. I remember seeing it for the first time and being blown away, it was rather amazing when all you&#x27;d seen up to that point was NES and PC games on a 286 or so.<p>Funny thing is I&#x27;m pretty darn sure I have no desire to work in commercial game development these days, but would have loved to back then. The creativity around limitations was amazing back then and it seemed like so much care was put into making games fun. These days it seems like addiction mechanisms, getting people to spend more money, obsessiveness with graphics over gameplay, etc.. are ruining everything.
评论 #29663377 未加载
blondinover 3 years ago
would be truly amazing if Fabien can pull it off.<p>there is so much secrecy surrounding video game development in japan. especially the 8 and 16-bit era. i was very interested in how they did pixel art back then. they supposedly drew them using special keyboards and CRT monitors.<p>there is one page on the whole internet that briefly mentioned the process.
评论 #29658431 未加载
评论 #29659060 未加载
评论 #29662872 未加载
ggambettaover 3 years ago
Another excellent article by Fabien :)<p>One thing that surprises me is that in such a ROM-constrained context, the artists weren&#x27;t asked to save some more. There&#x27;s some tiles that are empty except for a handful of corner or side pixels; I could imagine going to the artists and asking them to tweak the pose a tiny bit to save a tile.<p>Or maybe what we&#x27;re seeing in these sheets is the result of doing that <i>just enough</i> to fit their game into the available ROM, at which point they didn&#x27;t need to free any more tiles?
评论 #29662896 未加载
评论 #29660072 未加载
phkahlerover 3 years ago
&gt;&gt; Notice how Ruy&#x27;s top hair for 0x69&#x2F;0x6A was placed at 0x6F&#x2F;0x9F in order to not disturb the layout. Why the hair of the top left pose is offsetted is unknown. Could it be that GFX ROM address 0x0000 could not be used? Analyzing other games also showed that tile 0x0000 was never used.<p>My guess is that it was easier to encode and use a blank tile than to specify those strange shapes where sprites are non-rectangular. Just tell the hardware the size in tiles and then offer a set of tiles that includes blanks. This could be confirmed or refuted once they find the area in ROM that specifies how to put the tiles together to form a sprite.<p>It sounds like a complete sprite had to be entirely on one page, so there must be a list of tile numbers to compose a sprite and they would be 1 byte each. since they know the tile layout for some of the poses, they should be able to write down that sequence of bytes and look for it in the ROM, then check if there are zero tiles in there. Or just check the MAME source code since that level of detail was probably all figured out a long time ago for that project :-)
评论 #29662495 未加载
city41over 3 years ago
I&#x27;m currently writing a tool to package up sprite tiles for the Neo Geo[1], which handles graphics in a very similar manner as the CPS1. I can&#x27;t imagine composing these tiles manually, what a monumental task.<p>The Neo Geo&#x27;s hardware offers a few graphical features that work by assuming the tiles are ordered in a certain way. It&#x27;s an interesting challenge to meet those requirements.<p>[1] <a href="https:&#x2F;&#x2F;github.com&#x2F;city41&#x2F;sromcrom" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;city41&#x2F;sromcrom</a>
评论 #29672403 未加载
thrdbndndnover 3 years ago
Fascinating read, one question though:<p>If they can split an image into multiple tiles at different addresses (as they did in some examples shown in the article), shouldn&#x27;t they only need to care about the total tile number? Why did they bother to try to fit these postures (more or less) as whole on sheet, or making these sheets at all?
评论 #29659534 未加载
hariswillover 3 years ago
Steet Fighter II, the game I mostly played in my childhood. Always been a big fan of this amazing game.
评论 #29659466 未加载
评论 #29659398 未加载
malkiaover 3 years ago
I could be mistaken, if it was SF II or some other similar game, but for PC (back in the DOS game, the sprites for these were not stored rectangular (with transparency) but rather a run-length of here is a line of pixels that starts from here to here. Hence your code can just &quot;movsb&quot; instead of checking (expensive) for transparency).<p>... Could&#x27;ve been another game, but it was fun trying to decode the images :)<p>(I think it also makes pixel to pixel collision easier to tackle, but don&#x27;t remember the details - this might&#x27;ve been Star Control II thing, another game we used (as kids) to decode images&#x2F;mods)
评论 #29660237 未加载
评论 #29659483 未加载
paulryanrogersover 3 years ago
Reminds me of doing unwrapping of custom models for Quake. After a bit of practice I realized it came out much better if I made the face, head, and front parts larger so they contained more details. Then other bits could be squeezed in or mirrored to maximize those 256x256 pixel skins.
aelphssssover 3 years ago
Reminded me of this link - <a href="https:&#x2F;&#x2F;www.criticalhit.net&#x2F;gaming&#x2F;street-fighter-iii-will-always-have-the-best-animation&#x2F;" rel="nofollow">https:&#x2F;&#x2F;www.criticalhit.net&#x2F;gaming&#x2F;street-fighter-iii-will-a...</a>
teloliover 3 years ago
What a game they made out of those 6MiB. Constraints foster creativity rather than limiting it.
bluedinoover 3 years ago
The sheer amount of sprites caused it to be the biggest ROM at the time on the Super NES. 16 megabits! That also caused the game to be priced at something ridiculous like $75 US<p>I wonder if they used this same method on the SNES or not.
HeckFeckover 3 years ago
I just wanted to note this website is very well-presented. It mimics the simplicity of a sheet produced by an old typewriter.<p>Eye pleasing and no distraction from the text, as a web page should be.
评论 #29660554 未加载
评论 #29660599 未加载
snarfyover 3 years ago
I recall seeing a video of their software setup, where they would use the console controllers instead of a mouse to draw the sprites.
ZeroGravitasover 3 years ago
Topically, some of these would make for extrmely geeky wrapping paper.
authedover 3 years ago
Street Fighter is one of the the only game that I ever bought... Kali was another one (game related app).