Live data from Hacker News

Source code for Quake 2 rerelease

github.com

21–30 of 232 posts

Re: Source code for Quake 2 rerelease

#21
post #15

What are people's thoughts on using "_t" as a suffix for types in C/C++, as this source does? My understanding is that it is technically reserved for language defined types, but I haven't come across a reasonable alternative (and having no suffix makes for odd code, for example a custom type for a "viewport" is better imo as "viewport_t viewport;" than "viewport viewport;")

I don’t believe that’s a c language thing, but a posix thing. anyway, in my own code for myself I do it, but it is frequently forbidden in coding standards I’ve worked under (even in a non posix environment) and it doesn’t rise to the level of pushing back on it usually, I’ll name types however the style guide wants, even if it’s worse. t prefix, worse. The whole word typedef, worse.

Re: Source code for Quake 2 rerelease

#22
post #5

I saw grumbling elsewhere about how the re-release doesn't include a Linux version, but here they are with the source and it claims to be tested with clang. Big props to iD for sticking to their principles.

I wonder why they released the source code for this one. Is it purely because of the principles, or did they have a legal requirement since the old one is also GPL licensed? I'm assuming they don't have legal requirements since they owned the old code anyway.

John Carmack has been fairly vocal about releasing the source code for his games, particularly the Quake/Doom series for as long as I can remember, going back to at least Quakecon 2004 during one of his keynotes there. I think at the keynote when they announced Doom 3, he even talked at length about eventually releasing that engine as open source, I think in 7 years (which eventually did happen). He is not the flag carrier for open source games, but he may be one of the most consistent at following through on open sourcing their base engine over the last 20 years. Before leaving Meta as CTO he was speaking about making sure the GO and Quest 1 were usable in offline mode with sideload capability when they become EOL'd. In my view this release of code is not at all surprising in the least.

Re: Source code for Quake 2 rerelease

#23
post #15

What are people's thoughts on using "_t" as a suffix for types in C/C++, as this source does? My understanding is that it is technically reserved for language defined types, but I haven't come across a reasonable alternative (and having no suffix makes for odd code, for example a custom type for a "viewport" is better imo as "viewport_t viewport;" than "viewport viewport;")

Recently I was musing to myself about adopting the convention `func_r`, to denote "the thing that the function `func` returns".

Why spend the energy trying to think up two names (one for the function you're writing and one for what you should call the type of its result)? It's also amenable to preprocessor macros, if you're so inclined.

Re: Source code for Quake 2 rerelease

#24
post #3

Quake II soundtrack is still in some sort of copyright limbo. It's easy enough to find on Youtube, but it's not on streaming services as far as I know. EDIT: maybe it's getting sorted out, there's even a fricking vinyl release https://www.lacedrecords.com/products/quake-2-limited-editio...

Quake always had amazing soundtracks. Nine Inch Nails "nailed" it on Quake 1. Quake 3 soundtrack is dope as well, but my all time favorite is the Quake 3 Rocket Arena vibes: https://youtu.be/clkOT6vRKDg

Re: Source code for Quake 2 rerelease

#26
post #3

Quake II soundtrack is still in some sort of copyright limbo. It's easy enough to find on Youtube, but it's not on streaming services as far as I know. EDIT: maybe it's getting sorted out, there's even a fricking vinyl release https://www.lacedrecords.com/products/quake-2-limited-editio...

It was so good that I would sometimes put the game disc in a CD player just to vibe. Unfortunately that CD cracked, so I no longer have access to the music nor the game.

I think Sonic Mayhem did QII. NIN did Quake I (or maybe just Trent). I remember the ammo boxes for the nailgun had the NIN logo.

Re: Source code for Quake 2 rerelease

#27
post #15

What are people's thoughts on using "_t" as a suffix for types in C/C++, as this source does? My understanding is that it is technically reserved for language defined types, but I haven't come across a reasonable alternative (and having no suffix makes for odd code, for example a custom type for a "viewport" is better imo as "viewport_t viewport;" than "viewport viewport;")

Where I work the style guidelines for C specify to use "_type". Interestingly enough, the huge code base for embedded products with a custom OS does not rely on types for fixed-width integer types: "uint32_t", for example. Instead, a company-wide header defines "uint32" etc. without the "_t" suffix. I don't know what guided that decision.

Re: Source code for Quake 2 rerelease

#29
post #2

Oh man! Memories. Back in 1999, Quake II was the game I played (like, literally the only one). I sunk so much time in QII and I wrote my very first code building a Mod. I think it's fair to say, Quake II turned me from a computer user into a computer programmer. And set the course for my entire adult life and career. From my original mod, I learned how to calculate vectors, learn an existing code base, integrate auto…

Discovering the drop down console was a revelation. An homage: http://guake-project.org/

The Windows terminal now has a quake-style dropdown mode by default.
Post reply on HN