[HN Gopher] Books for Game Developers
       ___________________________________________________________________
        
       Books for Game Developers
        
       Author : Decabytes
       Score  : 68 points
       Date   : 2023-09-15 19:18 UTC (3 hours ago)
        
 (HTM) web link (mrelusive.com)
 (TXT) w3m dump (mrelusive.com)
        
       | wormius wrote:
       | Huh - went to the main page to see who "Mr Elusive" was and found
       | out that he was a Doom programmer and authored a lot of papers.
       | 
       | https://mrelusive.com/publications/pubs_bytype.html
       | 
       | His ACM contributions: https://dl.acm.org/profile/81504687994
       | 
       | And he died in 2017 :( "Carmack paid tribute to him with the
       | comment that he was "the best developer I ever worked with, my
       | right hand, and a good friend. It was an honor.""
       | 
       | https://www.gamedeveloper.com/programming/obituary-jan-paul-...
        
       | chem83 wrote:
       | Any good books on ECS?
        
         | Dudester230602 wrote:
         | Given that ECS is just procedures (systems) mutating structured
         | state (components, entities) any older book on Pascal
         | programming should do.
        
       | richardjam73 wrote:
       | Some of these are available to be borrowed from the Internet
       | Archive. Some are free to download.
        
       | dang wrote:
       | Related:
       | 
       |  _Books For Game Developers_ -
       | https://news.ycombinator.com/item?id=6309464 - Sept 2013 (32
       | comments)
       | 
       | Normally we downweight lists (see
       | https://news.ycombinator.com/item?id=37518838 from yesterday) but
       | the top comments in this thread are so good, I'm exempting this
       | one.
        
       | i_c_b wrote:
       | Wow. This post gave me emotional whiplash.
       | 
       | I opened the collection of links, which is quite good if a bit
       | old. But then I had a subconscious mental itch, and thought,
       | wait... where had I heard the name mrelusive before? That sounds
       | _really_ familiar.
       | 
       | And then I remembered - oh, right, mrelusive, JP-what's-his-name.
       | I've read a huge amount of his code. When I was working on Quake4
       | as a game programmer and technical designer, he was writing a
       | truly prodigious amount of code in Doom 3 that we kept getting in
       | code updates that I was downstream of.
       | 
       | And he was obviously a terrifically smart guy, that was clear.
       | 
       | But I had cut my teeth on Carmack's style of game code while
       | working in earlier engines. Carmack's style of game code did, and
       | still does, heavily resonate with my personal sensibilities as a
       | game maker. I'm not sure if that particular style of code was
       | influenced by id's time working with Objective-C and NeXTStep in
       | their earlier editors, but I've long suspected it might have been
       | - writing this comment reminds me I'd been meaning to explore
       | that history.
       | 
       | Anyway, idTech4's actual game (non-rendering) code was much less
       | influenced by Carmack, and was written in a distinctly MFC-style
       | of C++, with a giant, brittle, scope-bleeding inheritance
       | hierarchy. And my experience with it was pretty vexed compared to
       | earlier engines. I ultimately left the team for a bunch of
       | different reasons a while before Quake4 shipped, and it's the AAA
       | game I had the least impact on by a wide margin.
       | 
       | I was thinking about all this as I was poking over the website,
       | toying with the idea of writing something longer about the
       | general topics. Might make a good HN comment, I thought...
       | 
       | But then I noticed that everything on his site was frozen in
       | amber sometime around 2015... which made me uneasy. And sure
       | enough, J.M.P. van Waveren died of cancer back in 2017 at age 39.
       | He was a month younger than me.
       | 
       | I didn't really know him except through his code and forwards
       | from other team members who were interacting with id more
       | directly at the time. But what an incredible loss.
        
         | mentos wrote:
         | My biggest takeaway from my time programming in Objective-C was
         | not being afraid to name functions and variables more
         | verbosely.
         | 
         | Curious to hear what aspects of Objective-C you feel influenced
         | id?
        
           | i_c_b wrote:
           | Well, as I say, I'd been meaning to look into this in more
           | detail because it's something I'd been long curious about.
           | But I don't think I have time right now to dig into it.
        
             | dang wrote:
             | If and when you do, I hope you'll write about it and post
             | it to HN!
        
       | meheleventyone wrote:
       | Missing any Game Design books so my picks:
       | 
       | Game Feel - Steve Swink - 2008
       | 
       | The Art of Game Design a Deck of Lenses - Jesse Schell - 2014
       | 
       | 101 Things I Learned in Architecture School - Matthew Frederick -
       | 2007
       | 
       | Writing for Games: Theory & Practice - Hannah Nicklin - 2022
       | 
       | Procedural Generation in Game Design - Tanya Short/Tarn Adams -
       | 2017
       | 
       | Procedural Storytelling in Game Design - Tanya Short/Tarn Adams -
       | 2019
       | 
       | A Theory of Fun - Raph Koster - 2013
        
         | Cognitron wrote:
         | Another good one on the game design side of things:
         | 
         | Designing Games: A Guide to Engineering Experiences by Tynan
         | Sylvester (RimWorld)
        
           | jaaron wrote:
           | Ha! I must have been editing my comment as you were writing
           | yours. I just started into Sylvester's book.
        
         | jaaron wrote:
         | Just want to add a +1 for these, particularly Art of Game
         | Design, A Theory of Fun, and the Tanya Short/Tarn Adams books.
         | 
         | To add to your list: I have a copy of _Designing Games: A Guide
         | to Engineering Experiences_ that I recently started reading.
        
         | mentos wrote:
         | +1 for A Theory of Fun
         | 
         | Raph illuminated things about the psychology of what makes
         | games fun that Id never realized nor seen before.
        
       | tester457 wrote:
       | Good selection of older books.
       | 
       | I didn't see [1] Game Programming Patterns.
       | 
       | [1]: https://gameprogrammingpatterns.com/
        
         | OnlyMortal wrote:
         | I _assume_ , given the headings there, it talks about
         | Model/View/Controller as the way to organise a game (and an
         | application as a whole)?
         | 
         | If you're interested in _how_ to put a game together, MVC is an
         | obvious model to follow.
         | 
         | For those who don't understand what I mean, you firstly worry
         | about data and have a way to represent that. That data _only_
         | been the "actors" state and position in the game. Nothing
         | graphics related. Nothing to do with how they interact. This is
         | the "model".
         | 
         | You then have completely separate code that can move those
         | actors around by changing the values in the model. This will
         | include state changes like collisions. No graphics involved.
         | 
         | You then have separate code that draws the actors in the model
         | based on their state.
         | 
         | It isn't obvious to many but this allows you to concentrate on
         | the various areas that need coding. It also allows you to, say,
         | easily change parts of the code as needs be.
        
       | jessetemp wrote:
       | Circa 90s and early 2000s.
       | 
       | I like how there's a whole book on quaternions. I've never
       | understood them and I'm convinced every definition I've read was
       | written by someone who also didn't understand them. I might try
       | to find a copy if I ever dabble in 3d again
       | 
       | Edit: To clarify, I understand the _need_ for quaternions (to
       | avoid gimbal lock), just not how to use them manually. Euler
       | angles are simple enough, I can change whichever axis by some
       | degrees or radians. But with quaternions I never understood what
       | was going on under the hood
        
         | meheleventyone wrote:
         | Whilst a lot of those books are old, some are covering subjects
         | like Quaternions that have been well understood for hundreds of
         | years if not much longer. They're not necessarily lacking in
         | value. There's a lot there that's pretty evergreen.
        
         | zerr wrote:
         | Instead of Euler angles, you use one axis and one angle,
         | because the former has a limitation named as "gimbal lock".
        
         | hknapp wrote:
         | makes it easier when you understand complex numbers
         | 
         | https://www2.clarku.edu/faculty/djoyce/complex/
        
         | eestrada wrote:
         | My (poor) understanding of quaternions is they are like a
         | vector with a rotation angle around the axis of the vector.
         | This is probably incorrect on many levels. But it was a simple
         | enough explanation that it made sense to my brain why this
         | would work better than simple SRT transform parameters for
         | avoiding gimbal lock. It's been several years since I needed to
         | deal with 3D transformations of any sort, so I'm a bit rusty on
         | all this.
        
           | xeonmc wrote:
           | Ultimately, the "canonical" representation of rotation state
           | is still axis angles, thanks to Euler's theorem (any combo of
           | rotation results in one rotation around some final axis)
           | 
           | (normalized) Quaternions are just the _intermediate
           | representation_ of axis-angles, they describe the component-
           | wise algebra of combining axis-angle rotations.
           | 
           | Game engines just leaves them as quaternions for performance
           | reasons.
           | 
           | A 2D analogy would be                   "angle" <->
           | [quaternion]         "45deg" <-> [sqrt2 , sqrt2]
           | 
           | The [ Re , Im ] form is convenient for manipulating by
           | coordinates, but the "final" succinct representation is still
           | "angle", because the component-wise form has more degrees of
           | freedom than necessary.
           | 
           | Summary:                   Quaternion = sqrt( exp(axis_angle)
           | )                    =       exp(axis_angle/2)
           | 
           | And                   (lw,lx,ly,lz),(rw,rx,ry,rz)->(w,x,y,z):
           | w = ww-xx-yy-zz         x = wx+xw+yz-zy         y = wy-
           | xz+yw+zx         z = wz+xy-yx+zw              where
           | ww,wx,wy,wz = lw*rw,lw*rx,lw*ry,lw*rz          xw,xx,xy,xz =
           | lx*rw,lx*rx,lx*ry,lx*rz         yw,yx,yy,yz =
           | ly*rw,ly*rx,ly*ry,ly*rz         zw,zx,zy,zz =
           | lz*rw,lz*rx,lz*ry,lz*rz
        
         | dragontamer wrote:
         | > quaternions
         | 
         | Instead of representing a rotation by roll, pitch, and yaw...
         | you represent rotations by a 4x4 matrix. As this is a
         | 3-dimension problem being represented in a 4-dimensional
         | matrix, you have some weirdness to the math (IE: you need an
         | additional constraint) but otherwise things get easier.
         | 
         | ---------
         | 
         | "Why is it easier?" Because roll / pitch / yaw systems have
         | Gimbal Lock.
         | 
         | That's... pretty much all you need to know as far as I'm
         | concerned. Its a different system of representing rotations for
         | reasons that the "classic" system messes up in.
         | 
         | ------------
         | 
         | The math for quaternions is hard, but... who uses math these
         | days? Just go into Blender, click the Quaternion button, and
         | click the up/down buttons on the Quaternion matrix to see how
         | the different values rotate the object.
         | 
         | Once you practice both "classic" (pitch/yaw/roll) vs
         | "quaternions" for... I dunno... 10 minutes? It becomes
         | blatantly obvious that quaternions are easier to use. Its not
         | even close. And I'm not sure if anyone has to implement the
         | math of them anymore in any circumstances, so its just a matter
         | of practicing them inside a 3d modeling program to see how to
         | use it.
         | 
         | After you've learned how to use quaternions, then you go back
         | and learn the math behind it. If you care to. Or don't, its not
         | like you need to know what the matrix represents exactly...
         | 
         | ---------
         | 
         | EDIT: Consider animation. If you've got an object that's
         | rotating from (roll: 90-degrees, pitch: 90-degrees, yaw:
         | 0-degrees), into (roll: 0-degrees, pitch: 180-degrees, yaw:
         | 90-degrees), and you change this by going...
         | 
         | (90, 90, 0)
         | 
         | (89, 91, 1)
         | 
         | (88, 92, 2)
         | 
         | ...
         | 
         | (2, 178, 88)
         | 
         | (1, 179, 89)
         | 
         | (0, 180, 90)
         | 
         | Did the object rotate and "look" correct in all frames?
         | 
         | Now do the same with the 4x4 matrix quaternion. This is all
         | just a simple click in Blender + animation keyframes. Does the
         | object look better?
         | 
         | Weird crap happens in the roll/pitch/yaw form. Weird in ways
         | that's difficult to describe in words, but easy as crap to see
         | in 30-seconds of Blender. So just pull out a 3d modeling
         | program and look at the damn thing, its really obvious.
        
           | andersa wrote:
           | A quaternion is not a 4x4 transformation matrix. In game
           | development context, it usually refers to a structure
           | consisting of 4 floats and is always assumed to be
           | normalized.
           | 
           | Maybe reading this comment helps:
           | https://news.ycombinator.com/item?id=37527928#37529562
        
         | smcameron wrote:
         | One thing to know about quaternions is that you do not need to
         | understand them in order to know how to use them, much as you
         | do not need to understand how an automatic transmission works
         | in order to drive a car. The knowledge of how to use them is
         | completely separable from the knowledge of why they work, and
         | if you concentrate on the former, and don't worry about the
         | latter, much progress can be made.
         | 
         | Edit to add: When I say "you don't need to understand how they
         | work to use them", I mean, you can literally implement all the
         | math to multiply, conjugate, scale and invert quaternions from
         | basic math operators and floating point numbers in C, and use
         | those operations to rotate 3d objects around in your program
         | successfully, all without having _any idea_ why they work. I
         | know this, because I have done it.
         | 
         | The basis for my understanding how to use quaternions, and how
         | to build the basic operations on them comes from this site,
         | which is quite concise and dense, but contains the necessary
         | information if you can beat your head against it persistently:
         | http://www.tutis.ca/Rotate/7quaternions.htm
        
         | alex_lav wrote:
         | Sounds like they're the gamedev equivalent of a Monad? Which I
         | only vaguely understand as a result of a poster on this forum's
         | "Everyone explains it wrong" style post. Hoping you get a
         | similar response with this.
        
           | Animats wrote:
           | Quaternions tend to be over-complicated.
           | 
           | Basic concept, 1 dimensional form: you want to represent a
           | direction in a 2D plane. You can use one number, a heading
           | angle, but at some point you reach a full circle and the
           | number has to wrap. This creates annoying special cases. So
           | another approach is to use a 2D vector, a point on a circle.
           | Those are usually normalized so that x^2 + y^2 = 1. No angle
           | is "special". You can average and filter such vectors without
           | problems, for example. This is called a homogeneous
           | representation, because it behaves the same everywhere in its
           | space.
           | 
           | Now upgrade to 2D - latitude and longitude. Near the poles,
           | small positional changes cause huge latitude changes, and
           | computation error increases. This is a serious problem in
           | navigational systems. So it's common to represent latitude
           | and longitude inside of GPS systems as a 3-component vector,
           | a point on a sphere, in what's called "Earth-centered, earth
           | fixed" form. Now you can average or difference measurements
           | without special cases. (Yeah, WGS-84 to compensate for planet
           | not being a perfect sphere, etc.)
           | 
           | Now upgrade to 3D orientation. That's a quaternion. It's a
           | point on a 4-dimensional hypersphere. This can be mapped to a
           | 3D vector pointing in space and a roll around that vector, or
           | to pitch-roll-yaw, etc. As above, a quaternion is a unit
           | vector. It's hard to visualize this, so just shut up and
           | calculate.
        
             | andersa wrote:
             | Wow, I had never seen this explanation before. That makes
             | so much sense! Now I finally understand why we always
             | normalize the quaternions and why that is a sensible
             | operation...
        
       | OCASMv2 wrote:
       | Do magazines count?
       | 
       | https://www.gdcvault.com/gdmag
        
         | pengaru wrote:
         | +1
         | 
         | Many toilet hours were spent reading dead-tree versions gdmag
         | and ddj back in my youth.
        
       ___________________________________________________________________
       (page generated 2023-09-15 23:00 UTC)