Live data from Hacker News

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

news.ycombinator.com

101–110 of 238 posts

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

#101

I built games in the 90s. Graphics was obviously the hardest part. We thought about things in terms of how many instructions per pixel per frame we could afford to spend. Before the 90s it was hard to even update all pixels on a 320x200x8bit (i.e. mode 13h) display at 30 fps. So you had to do stuff like only redraw the part of the screen that moved. The led to games like donkey kong where there was a static world and…

Agree with everything you said. We used x87 though and paid extreme attention to fpu stalls to ensure nothing wasted clocks. As developers, we were also forced to give the graphics guys a really hard time: "no that texture is too big! 128x128" & "you need to do it again with less polygons". We used various level of detail in textures and models to minimise calcs and rendering issues. Eg. A tank with only 12 vertices…

Ha. Yeah, there was not a lot of memory. The toolchain we built at the the time automatically packed all individual game texture maps into a single 256x256 texture (IIRC). If the artists made too many textures, everything started to look bad because everything got downsampled too much.

Any yeah, the design of the game content was absolutely affected by things like polygon count concerns: "Say, wouldn't it be cool to have a ship that shaped like a torus with a bunch of fins sticking out? Actually, on second thought... How about one that looks like a big spike? :)"

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

#102
post #19

The source code for Doom is available, and much has been written about how it works.[1] Go look. [1] https://doomwiki.org/wiki/Doom_source_code

For Doom, I’ve heard this book is highly recommended: https://fabiensanglard.net/gebbdoom/

Most of his books I say. Him and Holm I buy whatever they produce.

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

#103

I think the games that are pushing graphical boundaries today are prob just as efficient relative to how high fidelity they are and (have to) use just as many clever optimization tricks. It's just that there's so much room now to make something compelling from a gameplay and/or aesthetics POV but that is technically basic / cookie cutter / off the shelf

For modern-ish examples of very smart optimization-minded programmers still having to work to fit exceptional experiences into hardware limitations, I recommend Jonathan Blow’s talk about fitting Braid’s time rewind system onto the XBox, Natalya Tatarchuk’s talk on Destiny’s architecture, and Factorio’s blog posts on optimization.

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

#104

This is probably an unsatisfying answer, but simply put, a lot of systems these days are just bloated. I'm not only talking about the OS/programs running (though it often contributes), but rather the creature comforts developers have taken on over the years in the name of productivity. In fairness, the scale of recent games wouldn't be quite so possible without our superfluous tooling, but it definitely comes at a co…

> Java...a great tool for prototyping, but when it came to delivering a high-performance product it often fell short. I think this only been said in the context of games.

We used to prototype game ideas in Java and I know a large embedded software firm who uses Java for prototyping. After it has been shown to work, they port to c/asm.

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

#105

I’ve created a 4k UHD video editor for Haiku OS ( https://github.com/smallstepforman/Medo ), it’s a C++17 native app, with over 30 OpenGL GLSL effect plugins and addons, multi threaded Actor model, over 10 user languages, and the entire package file fits on a 1.44Mb floppy disk with space to spare. If I was really concerned about space, I could probably replace all .png resources with WebP and save another 200kb. How…

This looks amazing. Thank you for sharing.

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

#106

I built games in the 90s. Graphics was obviously the hardest part. We thought about things in terms of how many instructions per pixel per frame we could afford to spend. Before the 90s it was hard to even update all pixels on a 320x200x8bit (i.e. mode 13h) display at 30 fps. So you had to do stuff like only redraw the part of the screen that moved. The led to games like donkey kong where there was a static world and…

Out of curiosity, How did you know how many clock cycles your rendering code took?

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

#107
post #5

https://www.quora.com/Why-was-Roller-Coaster-Tycoon-written-... Funny you should mention Rollercoaster Tycoon because it was actually written in Assembly for performance reasons.

For a rube like me who views assembly coders as masters of occult incantations, this is incredibly impressive

Assembly language is actually much simpler than even C, much less Lua or JS or Python. It just takes a lot more work to get anything done: five times as much code that's twice as hard to debug per line. Roller Coaster Tycoon is an incredibly impressive achievement, but not because writing it required memorizing a lot of occult trivia. It didn't. It just required effectively using the stuff you have available.

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

#108

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…

As far as I remember, Pokemon Gold/Silver were given to some special assembly optimization guru after the game was pretty much finished. He was able to squeeze out so much memory that the Kanto region of the original games was more or less added as an afterthought. And it was totally worth it, having the entire first game available in the sequel, just set a couple of years in the future, seeing how the world changed…

Wow, thank you for this info, I didn’t know that. It’s fascinating what they did back then.

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

#109

I built games in the 90s. Graphics was obviously the hardest part. We thought about things in terms of how many instructions per pixel per frame we could afford to spend. Before the 90s it was hard to even update all pixels on a 320x200x8bit (i.e. mode 13h) display at 30 fps. So you had to do stuff like only redraw the part of the screen that moved. The led to games like donkey kong where there was a static world and…

Out of curiosity, How did you know how many clock cycles your rendering code took?

You could just measure the isolated inner loop with accurate timers and figure out down to the clock how many cycles it was taking.

You also basically knew how many cycles each instruction took (add, multiply, bit shift, memory reference, etc.) so you just added up the clock counts. (Though things got a bit harder to predict starting with Pentium as it had separate pipelines called U and V that could sometimes overlap instructions.)

Post reply on HN