QuakeC from Scratch tutorials

Scratch Tutorials, Version 2 | Recreate Quake from scratch

Preface: Why? - Why this exercise of friviolty?

Chapter 1: These worldly gifts... - Wherein Ender doth demonstrate how to play god, and create a world.

Chapter 2: Let there be light... - And thus on the second day he created the sun

Chapter 3: And all was quiet... - Roll your own Ambient sounds, and other useful effects.

Chapter 4: The golden mirror... - Scared what you will see if you look in a mirror? You should be.



Why this exercise of friviolty?

"Why?" - If ever mankind had a more commonly uttered word (Other than various four lettered words like... frag.. :) I would be suprised. Of course, you can always reply: "Why Not?", and that's basically my excuse for coding this. But not the only one.
After working on QuakeMovie, I realised how damn hard it was to second guess ID's own QuakeC code. Every time I tried to do something with a Camera or an Actor, some nasty bit of ID's code would interfere, and crash or do really wierd stuff. After commented out huge lumps of code that was rather useless anyway, I decided "There must be a better way!". So I junked everything. Kept the bits of defs.qc that I had to, and tried to rewrite the QuakeC from scratch. It's nothing unusual, it's been done before. And it's not really a hard thing to do.

But the hard thing, was I decided to document it.. and write.. a TUTORIAL! :) Now for me, this isn't easy. But I wanted to share the things I have picked up along the way. I still havn't been able to teach my mother how to use Word, so my tutorial skills are somewhat lacking.
In the course of this rather large set of tutorials, you'll probably notice some of my quirks. Firstly, I like using directorys to keep things organised. Tux, my fellow coder on QuakeMovie and a few other things, has killed me once for doing this to one of his project's. I acually converted it to a early form of scratch. I think he's forgiven me, and even finds it easier now. :) I also like comments. Well, no. I hate comments. But I used them a lot in Scratch, for obvious reasons. These are just a few of my strange habits. You'll probably pick up some more as this goes on.

At the end, you should have a almost functionally equivient game core as the normal V1.06 QuakeC, but it should be smaller, a bit faster, and a hell of a lot neater - ID thought a few people would write mods for Quake, but I doubt they suspected QuakeC to be as popular as it is, so they still had rather messy code :)
At various times in these Tutorial's I will offer a 'snapshot' of my own version of code at the time. You'll find the first one at the end of Tutorial 3. But do try to type it up yourself.

Also, -please- -please- -please- send me E-mail and feedback about these tutorials, including what you would like to see in future chapter.
I've only recently rewritten these in responce to several E-mail's, but I'll stop again if I don't hear back again. :) Ender@admdev.com people, Remember it.
Ender@admdev.com