Hacker News new | ask | show | jobs
by cloudmike 796 days ago
Some friends of mine played Descent competitively, and I was amazed to learn about so-called trichording: to maximize your speed, you need to press multiple keys at the same time to travel along all 3 axes at once, e.g. forward/right/up. The best players zip around the map diagonally.

I always assumed this was a bug-turned-feature, like skiing in Tribes. When I saw the repo just now, I looked for clues, but didn't spot any related comments around the line of code where this ultimately happens:

https://github.com/kevinbentley/Descent3/blob/142052a67d4318...

5 comments

AFAIK a similar thing worked in in lots of shooters: running diagonally by strafing and going forward gave you sqrt(x^2 + y^2) speed probably because of a design oversight (and because running in each direction was equally fast). In Descent you just added up/down for another axis, which gave you a speed of about 1.7x compared to forward only.

In Descent 2 and 3 you also had the "afterburner" which gave a speed boost forward, but it had limited (albeit quickly recharging) energy, and the speed boost it gave you was greatest at 100% energy and effectiveness dropped as remaining energy dropped towards 0%. So people learned to pulsate it multiple times per second so that it would recharge between the fraction-of-a-second uses and keep at ~95% all the time instead of quickly dropping to low figures.

So if you wanted to go really fast you'd both run diagonally in three dimensions and keep pulsating the afterburner multiple times per second.

It wasn't really considered either a bug or a feature by the original designers, it was just not something they put any thought into. After it was discovered, some designers had a negative opinion of it, others had a positive opinion, and it was a point of contention when the team got together to make Overload after years away from Descent. My wife and I tried some alternatives (by modding D1) and flew a demo for Mike/Matt/Luke/Dan and whoever else was in the studio that day, and eventually settled on "vector independence just feels good" which is why Overload has the ability to change from a normalized flight mode with faster 1D flight into the trichording mode.
In 2D, the diagonal across a 1x1 rectangle is longer than just its sides.

A naive implementation of just adding the x and y vectors together will become their sum, totaling up to the diagonal length, 1.41x faster. In 3d even more.

This is a very common bug (feature) in many old games.

Quake famously did consider this bug while walking but not while jumping, leading to a more complicated trick to speed up called strafe-jumping.

In the competitive ladders some of the best used rotation to "steer" in curved paths when trichording.

It made people really difficult to hit when you were behind them.

I played against some ladder players and was amazed at their other order of magnitude skill.

Part of the reason those og games were so compelling to me is because they didn't really have a skill cap.

It would have been amazing to watch some of those matches in a streaming platform.

Yeah looks like the calculation doesn't renormalize the final thrust vector after adding together the component inputs. A simplified example for a 2d game would be like this:

    var playerX_input = Input.GetHorizontal(); // float in range -1 to 1
    var playerY_input = Input.GetVertical(); // float in range -1 to 1

    var playerVelocity = new Vector2(playerX_input, playerY_input);
    // The player can now move 1 unit/frame in X and 1 unit/frame in Y, which means that if they're moving diagonally, the length of their velocity vector is the length of the vector (1,1) which is sqrt(2) (~1.41)

    // This can be corrected by doing something like
    if(playerVelocity.length > 1)
    {
         playerVelocity = playerVelocity.normalized();
    }