It seems that you're using an outdated browser. Some things may not work as they should (or don't work at all).
We suggest you upgrade newer and better browser like: Chrome, Firefox, Internet Explorer or Opera

×
Something that always annoyed me of quake 1 is when you are walking and press strafe left or right the character starts to move faster like if you were pressing shift...

i've checked the console commands but there's nothing for disabling this

same thing happens in hexen 2
Post edited March 04, 2023 by Matias_Nic
No posts in this topic were marked as the solution yet. If you can help, add your reply
That's just what happens in old games before floating point. X Y and Z weren't treated as equals.
avatar
Darvond: That's just what happens in old games before floating point. X Y and Z weren't treated as equals.
but is the only game that have that
It seems to be something that popped out on Doom and they just left there for Quake.

It seems is among the other "advanced movements" like bunny hoping or that thing the engine does of letting you jump higher/farther when you run towards a slope and jump.
avatar
Darvond: That's just what happens in old games before floating point. X Y and Z weren't treated as equals.
They were treated as equals (well, in Doom there's different side/forward speeds so you get SR40 and SR50 run speeds). It's not a floating point not being used issue. It's that direction buttons were themselves applying accelerations rather than using directional vectors. When you held forward and held strafe left you applied say 1SPD forward and 1SPD sideways... what does that look like on paper. Well, start at zero, draw a line up 1, and one say left 1... now how long is that arrow? it's a hypotenuse of ( (1^2) + (1^2) )^0.5, ^0.5 = square root or (1/2). Normal trig. So... the length of that is 1^2 = 1, thus 1+1=2, so 2^.5 = ~1.414SPD.... which as you might notice is, is faster than 1 SPD forward or 1SPD sideways. Which makes sense because you're applying two forces. This is also... as you might have noticed, floating point numbers for mathing that, or arbitrary decimal in our literal case, floating point would likely be slightly different since floating point numbers have varying accuracy in approximations of decimal numbers. So, 0.4 isn't 0.4 like we read in floating point. In most programming languages 0.1 + 0.2 == 0.3 -> false, because the floating point represenation is 0.30000000000000004, which has to do with more complex truncations on mantissas and stuff.


What you need to offset that is directional vectors that apply to SPD. IE, 1SPD forward, 1SPD sideways, or 1SPD @ 135 degrees (45 degrees left forward) etc... and when you math those out... they're all, 1 SPD, because movement keys would apply a direction to a vector as well as tell it to accelerate but it wouldn't treat them as simple "adding accelerations", you'd have to apply their individual vector components in relation to direction so it'd be like SIN(angle)*SPD, COS(angle)*SPD which would net .707 y axis and .-707 x-axis, which would tally to 1^.0.5 = 1SPD at 45 degrees


The question is, do you care to have accurate vector component input or do you just accelerate and whatever you get is what you get? The latter worked well enough for most games, in fact, most games actually do the former rather than the latter. It's rare to find a game that applies vector movement appropriately rather than strafing. Then there's the whole issue of rotating camera while doing it and how that affects speed.
avatar
Darvond: That's just what happens in old games before floating point. X Y and Z weren't treated as equals.
avatar
Matias_Nic: but is the only game that have that
It's not. See my response the floating point is you want to know why. But it's actually VERY common in 3D games. All half life games have it, they are derivative of Quake's idtech though, so are earlier CoD titles, those all do it as well and Doom 3 / Quake 4. Painkiller has it. Darkforces has it. Duke 3D / Build Engine games do it. Unreal Engine games... I think don't have it for running movement but do for jumping/dodging - you can dodge or dodge jump farther straferunning at an angle than you can normally in UT and UT2K3/4 series and gain significant boosts in the 2K games. Quake 1 does have it as well, but when jumping it does extra stuff so holding strafe slows you down - but it's a common basic technique to start off bunnyhopping with, especially when combined as a "circle strafing" jump. It exists in Goldeneye/PD on the N64. Utilizing the same thing in all three vectors in Descent is called trichording.

Basically, it's in a lot of games. Probably most 3D games really if you have enough speed to tell. Not all though, and in some cases it depends on other movement like jumping.
The answer is vectors. Press W and D at the same time, you move forward and right, each at a speed of 1 unit. Since you're moving forward at one unit, and right at one unit, you multiply those together, and you get 2 units. You then find the square root, you have 1.41 (roughly). What you've really done is a² * b² = c². Shooters of this era, even as recent as Morrowind, did this, because it was easier than methods that can balance movement speeds, since mathematically all you're doing is incrementing two numbers.