Live data from Hacker News

Ask HN: How were video games from the 90s so efficient?

news.ycombinator.com

231–238 of 238 posts

Re: Ask HN: How were video games from the 90s so efficient?

#231
I've been working in games since the early/mid 90's, from before we had 3d accelerators right at the start of my career to today. Many of the comments I've read so far from other devs ring true, but seem to miss an important point.

3D accelerators, to a large extent, changed what we (game developers) needed to focus on. If I'm doing a software rasterization of a bunch of triangles, then the speed at which I sit in that tight loop rendering each pixel is of utmost importance. Getting a texture mapping routine down to 9 clock cycles matters. The moment I worked on a game that used 3d accelerators, that all changed. I submit a list of triangles to the 3D accelerator, and it draws them. It rarely matters how much time I spend getting everything ready for the 3D accelerator, since it is rendering while I am processing, and my processing for all intents and purposes never takes longer than the rendering.

Once we had that architectural paradigm shift, the clock cycles it takes for me to prepare the drawing list are entirely irrelevant. The entire burden of performance is in getting the 3d accelerator to draw faster. This means that optimization is in reducing the work it has to do, either through fancy shading tricks to simplify what it takes to make something look right, or reducing the amount of geometry I send to the 3d accelerator to draw.

The neat thing is that we've gone full circle in a way. When it used to be important to hand optimize the inner loop of a rasterisation function, now we have pixel, vertex, and fragment shaders. The pixel and fragment shaders are getting run millions of times, and we used to have to code shaders in shader assembly. Now they're generally written in higher level shading language, but nonetheless, optimizing shader code often becomes quite important. It feels like the same work as assembly optimization to me.

Re: Ask HN: How were video games from the 90s so efficient?

#233

Earlier quoted context omitted.

Honestly - a lot of the best early games were written in Assembler. C is kinda just one extra layer of abstraction. Even up through the PS1/N64 days there was still a lot of assembly stuff.

I was gonna suggest assembly but modern instruction sets are too complicated nowadays

It’s best if you follow examples for developing for - say - the SEGA Genesis - that’s how I got my start on Assembly. :)

Re: Ask HN: How were video games from the 90s so efficient?

#235

Earlier quoted context omitted.

I was gonna suggest assembly but modern instruction sets are too complicated nowadays

It’s best if you follow examples for developing for - say - the SEGA Genesis - that’s how I got my start on Assembly. :)

For me it was Gameboy

Re: Ask HN: How were video games from the 90s so efficient?

#236

Hard disagree with many comments here. For ennemies AI, ok: we made progress. But for human-vs-human gameplays, we basically had everything in the nineties. Warcraft II over Kali (to simulate a LAN over the Internet for Warcraft II didn't have battle.net) was basically the gameplay of Warcraft III reforged. Half-Life and then it's counterstrike mod were basically the FPS of today. Diablo II (development for Windows 1…

Warcraft II is a bad example here - it's completely unplayable if you're used to any kind of modern RTS. Terrible unit AI (not computer AI), selection limits, no rally points or queuing. It also has just 2 factions. Starcraft, which only came out just over 2 years later, blows it away from gameplay perspective. Warcraft 3 came out in 2002 (6 and half years after Warcraft 2) and represents an even larger improvement i…

Not to mention that Warcraft 3 was Blizzard's first ever 3D engine. It was actually carried over from an engine developed for Descent (https://news.ycombinator.com/item?id=20973306), effectively a simplified perspective shooter. Constraint sometimes bubbles up to the surface the best solutions. A bit late to this thread. I was the QA Graphics Lead for WarCraft 3.

Re: Ask HN: How were video games from the 90s so efficient?

#237

Earlier quoted context omitted.

Descent blew my mind, as well. IIRC it predated Quake and was the first ’true’ 3DoF FPS? The source code has since been released on GitHub, if you’re ever interested in seeing it!

6DoF, as there are six degrees of freedom. Three correspond to rotational movement around the x, y, and z axes, commonly termed pitch, yaw, and roll. The other three correspond to translational movement along those axes, moving forward or backward, left or right, up or down.

Yep close, I think it was even more constrained then that though.. https://news.ycombinator.com/item?id=20973306

Re: Ask HN: How were video games from the 90s so efficient?

#238
post #73

So many great responses in this thread, but I’ll just throw it out there that the original Pokémon games for GameBoy were in hand-written assembly specific to the GameBoy. I would imagine “back then” the programmers had limited memory and thus more obvious constraints. It’s probably possible to recreate this level of efficiency nowadays but both the number of platforms and the expectations of gaming have exploded sin…

Also the gameboy is effectively a game engine in hardware form. It's way easier to write the little bit of code to glue the hardware objects to your internal entities/game logic than to write engines from scratch on modern hardware.

Disagree. The Game Boy will take sections of RAM and render them to backgrounds and/or sprites. That's it.

Any connection between those hardware elements and objects in a game's state, as well as updates to that state, must be maintained and implemented by software, and that software is the game engine.

For example, on the NES, the hardware can display 64 8x8x2bpp sprites, on a roughly 64x64 tile background where 1/4 of it is visible at any given time. Mario Bros' uses the hardware to "draw" Mario as 8 sprites by adjusting registers per frame, but things like what happens when movement commands are received, when Mario hits bricks and other objects, does not involve the PPU at all.

Post reply on HN