The code behind Quake 3's overbounce bug

Поділитися
Вставка
  • Опубліковано 10 чер 2024
  • An exploration of the code that gives rise to overbouncing in Quake 3, including variations, and tools that can be used to assist the player in performing this trick.
    Chapters
    00:00 Introduction
    00:35 What is an overbounce?
    01:01 Normal overbounces
    05:22 Visualization tool
    05:43 Sticky overbounces
    06:45 Horizontal overbounces
    07:33 Diagonal overbounces
    09:25 Outro
  • Ігри

КОМЕНТАРІ • 83

  • @chosen_none
    @chosen_none 2 роки тому +43

    Having played Q3 and the defrag mod for so long, it's very interesting to have all these bugs I had exploited countless times finally explained :)

  • @GroinMischief
    @GroinMischief 2 роки тому +77

    Diagonal overbounces are easier to perform by using +strafe, which allows you to move to all 360 degrees very slowly with your mouse. Also m_side 0 locks it to only forward and back movement, so you don't get weird horizontal angles by accident.
    Would be nice to see your breakdown of some Quake 2 bugs, they got a lot of weird shit in there lol

    • @bshthrasher
      @bshthrasher 22 дні тому

      It's not the same thing tho, Diagonal Ob is when you do it with horizontal speeds above 1 UPS, like 96 UPS for example, then engine calculates your resulting vector. The Obs involving +strafe button occur with horizontal speeds below 1 UPS and are called ZW Obs or Zero-Weird Overbounces. IIRC the speed of Diagonal Ob is lower than the speed of ZW Ob, because vector math is different. Diagonal Obs are way harder to perform, so after doing a ZWOb you can't tell you did a Diagonal Ob it's simply not true in terms of technical difficulty)

  • @BmikroB
    @BmikroB 4 місяці тому

    An amazingly detailed, yet still easy to follow. You've explained it exceptionally well, thank you for this video!

  • @liblast
    @liblast Рік тому +10

    For an aspiring game developer these videos are very interesting.
    Thank you for going in-depth on these technical topics!
    I'd love to see something about Unreal or Unreal Tournament '99 - that's an entirely different code lineage.

    • @bunnytrakt0r
      @bunnytrakt0r 11 місяців тому

      Bounce jump possible in ut99 but it horizontal jump and speed. And its not hard if ú know some liltle secrets. And some else interesting things.😉

  • @iamsixsyllables9679
    @iamsixsyllables9679 Рік тому +5

    definitely a wonder that little know about other than q3 defrag players, I was pretty confused when I couldn't do it in quake live, before I learned that it was patched haha.
    I wanted to say that I always love watching your videos, and they are very professionally made, especially with the graphs and visualizations. Keep it up

  • @attractivegd9531
    @attractivegd9531 2 роки тому +2

    Can't fathom enough how awesome these videos are.

  • @richardtoth7240
    @richardtoth7240 2 роки тому +3

    I love these videos of quake. Brings back memories haha.

  • @toajames1
    @toajames1 Рік тому +2

    This reminds me of superbouncing in Halo 2. It was similar in the sense that you had to land between 2 pieces of geometry to make it happen.

  • @florianneumann9441
    @florianneumann9441 Рік тому

    i haven't expected to be interrested to watch a q3 video after all this time but that was great ^^

  • @QuakeGamerROTMG
    @QuakeGamerROTMG Рік тому +1

    Cannot believe that I've never heard of or experienced this but it's pretty rare that you would NOT be holding movement keys in Quake 3

  • @jeffploetner
    @jeffploetner 2 роки тому +1

    Awesome video and explanation! Love the code you brought in.

  • @fr3fou
    @fr3fou 2 роки тому +2

    I'm in love with this channel

  • @joshuam2263
    @joshuam2263 2 роки тому +2

    So interesting and well presented, just like all the other videos!

  • @GloomGenetics
    @GloomGenetics Рік тому

    did not knew about this mechanic, thanks for the video.

  • @SaperPl1
    @SaperPl1 2 роки тому +3

    I would really like to see some videos on how much of this stuff worked in Medal of Honor: Allied Assault, which did use the engine. Also there were some other interesting bugs used by competitive players like for example freezing the grenade on a closing door to know which side the enemy team is attacking from (by hearing explosion when the door were open). Another trick I remember was to collapse the player model by changing animations while jumping onto the ladder, and it was called "sharking". I feel like since it's the same (similar/derivative) engine underneath, but a slightly different game, this could be something fresh and not that far off from what you've been already doing. Except the potential issue with source code of the game, I think.

  • @grafzhl
    @grafzhl 2 місяці тому

    Watching this almost 20 years after I discovered Defrag is pretty nostalgic :>

  • @n00k1e
    @n00k1e 2 роки тому +2

    Amazing video as always

  • @Cypeq
    @Cypeq Рік тому +1

    fun fact most overbounce used in game where there is no wall to stop you dead, can be performed just strafing

  • @kered13
    @kered13 2 роки тому +20

    What I have still never understood is what the overbounce code was supposed to do. Why clip the player's velocity to slightly positive? Why rescale that vector back to the original magnitude? Since this section of code is supposed to be handling the player landing on a surface, the obvious thing to do is to set the player's vertical velocity to 0, why did they make it more complicated?

    • @MattsRamblings
      @MattsRamblings  2 роки тому +9

      This is a good question, and something I wanted to answer in the video but couldn't figure out. If anyone knows for sure I'd love to hear about it!

    • @TribeWars1
      @TribeWars1 2 роки тому +6

      Perhaps they ran into division by 0 exceptions and a dev fixed it this way?

    • @TarenGarond
      @TarenGarond 2 роки тому +5

      PM_StepSlideMove(PM_SlideMove) is supposed to handle players landing(And most other velocity clipping against surfaces, not against ground you currently walk on though), the code you're talking about should normally just handle walking.
      And the comments in the code is quite clear, ClipVelocity clips your velocity against a possible slope you're moving on and VectorScaling gives you back the speed you lost so you don't lose speed when walking on slopes.
      Edit : check later comment for corrections of the prior text (Or I may just don't know what the heck I'm talking about but it is probably closer to the truth though XD)
      The text that follows is just my theories(I'm not that familiar with bg_slidemove.c and how collision checking is done).
      But I think the overbounce(overclip) = 1.001 stuff is so that you will pushed out into that 0.25 units tall "ground layer" when walking so that you hover a tiny bit over ground.
      1.001 is used in all ClipVelocity's including the ones inside PM_SlideMove, as said earlier this is the function that handle most of velocity clippings against surfaces.
      My theory is that that rounding errors could (possibly) lead to "continuous collisions" (if overbounce = 1) that (possibly) messes with how PM_SlideMove works and makes it clip players velocity several times against the same surface for no reason.
      I might be totally wrong though.
      By the way interestingly overbounce is 1 in Q/QW and 1.01 in Q2, don't know if their versions of "slidemove" works differently.

    • @GroinMischief
      @GroinMischief 2 роки тому +8

      Quake 2 has a somewhat similar bug, the higher you fall the higher your next jump will be (very small differences). This makes it possible to jump over some crates with low FPS values, that you normally couldn't. Apparently the point was to prevent the player getting stuck into geometry. I could be remembering it wrong though

    • @TarenGarond
      @TarenGarond 2 роки тому +3

      I wanted to do corrections to what I said earlier.
      That code doesn't really handle the "act of walking" on a slope(Although it is handled while pml.walking = true) it handles sliding along the ground plane(I mean the comments in the code is quite damn frickin clear! L0L...) by "external forces", as the player acceleration is already made parallel to the ground plane(And not slowed down) earlier in the code.
      So when walking, velocity clipping against the ground plane from "external forces" as gravity(Only when on slick or when in knockback timer) or knockback velocity could never slow you down(It can obviously change the direction of the vector though).
      This makes a bit of sense(At least when getting knocked back I think) but at the same time not really, I don't know to be honest...
      But yeah I may just talk shite, for anyone wanting to know how this really works check the source code for yourself(It is quite fun!), lol.

  • @peersvensson9253
    @peersvensson9253 2 роки тому +5

    The only missing part would be about ZWOBs, which is a bit like a DOB but done with

  • @EmSixTeen
    @EmSixTeen 2 роки тому +1

    Informative video. Very cool mod.

  • @q3dqopb
    @q3dqopb 2 роки тому +3

    Thanks for this FANTASTIC video, Matt! Do you have a defrag nickname? Also, can you open-source your mod rendering the OB surfaces in different colors? Defrag has its own OB detector, but your highlighted surfaces look a lot fancier.

    • @MattsRamblings
      @MattsRamblings  2 роки тому

      Hey, my mod (including source) is available here: github.com/matthewearl/ioquake3/tree/me/ob

    • @q3dqopb
      @q3dqopb Рік тому

      @@MattsRamblings by the way, you covered VOB, HOB and DOB aka WOB. But you didn't tell about the so called ZWOB - zero-weird overbounce. You fall with zero lateral velocity, press +strafe key, and move your mouse gently forward (or in other directions). This makes next velocity slightly over zero, which allows you to control the 3d vector direction. But as long as the next velocity is less than 0.5, it is rounded down to zero. ZWOBs are used in defrag much more often than WOBs that you showed at the end of this video.

  • @ralfherp4555
    @ralfherp4555 2 роки тому

    Interesting video. Well done.

  • @kurzackd
    @kurzackd Рік тому +1

    At least 10 years of experience...
    At one point I was playing this game on a semi-pro level....
    This is the *FIRST TIME EVER* I ever hear of this bug...
    *WTF.*

  • @granite_planet
    @granite_planet 2 роки тому

    Well made video! Awesome!

  • @spasdar
    @spasdar 2 роки тому

    very interesting! thank you for sharing!

  • @golarac6433
    @golarac6433 2 роки тому

    Great job, more videos like this :D

  • @starc0w
    @starc0w Рік тому

    Sooo cool! Thank you very much! 👍🍀

  • @rxn7
    @rxn7 2 роки тому

    i love your videos

  • @Yocairo
    @Yocairo Рік тому +4

    CoD4 - bounce jumps are very similar but still very much different from this. Could cover that too, since it's based on the same engine.
    Lots of FPS switching... ua-cam.com/video/HqrImHk8RB8/v-deo.html

  •  2 роки тому

    Thank you for sharing.

  • @jimday666
    @jimday666 Рік тому +1

    Titanquest, Apex technical movements please.
    Warzone1, Warzone2 OB, because I experienced a few times, just by pure accident.

  • @2macki332
    @2macki332 Рік тому

    The code behind multiplication achieved would be a nice video :]

  • @peterpan408
    @peterpan408 Рік тому

    Thats perfect physics!

  • @SuperSkandale
    @SuperSkandale Рік тому

    I don't recall any of these bugs from my adolescence gaming years.

  • @zachary1152
    @zachary1152 2 роки тому +1

    There's a really funny/annoying jump pad "bug" that people always exploit in Quake Live. Land on another player while they're on the jump pad, and that person below you is forever stuck unless they rocket themselves free. I assume because the physics for the top player is saying you're going down and the bottom player's physics is saying you're going up, but the frozen in place part is pretty goofy.

  • @Frobbl
    @Frobbl 2 роки тому +2

    I've seen defrag players do some kinda "plasma jump" in which they gain big amounts of forward speed after shooting one plasma shot right in front of their feet. I have never bothered looking into it because I never competitively played defrag.
    How does this work? Is it just an overbounce triggered by the plasmashot in combination with a very well timed jump that comes right after triggering the overbounce? Or does it have to do with the Plasma shot itself and isn't caused by an overbounce?

    • @ix-ir
      @ix-ir Рік тому +1

      I think this is caused by the way being in knock back status reduces ground friction.

    • @TarenGarond
      @TarenGarond Рік тому

      In VQ3 when on slick or being in a knockback timer(50-200ms(I think) when being shot or damaging yourself) ground friction is removed and you get the acceleration lowered to the same as in the air, but in CPM only the friction is removed(Leading to extreme strafing acceleration potential)!
      By damaging yourself (setting the timer to 50ms with plasma probably, not entirely sure though) and land within the knockback timer the landing is setting the timer to 250ms(Might be another value in CPM).
      The reason the landing is changing the timer is that the game uses same timer for several things with flags set to indicate what it is used for right now XD, the landing is setting a "landtime"-flag(not used for anything, but originally was to prevent you from jumping within the 250 ms timer) but the "knockback"-flag isn't removed.
      So within this 250ms timer after landing you can now on ground accelerate quite extremely by them sick strafes.
      Additional fun fact : The setting of the landing timer is also what is allowing you to wallclip/skim because the game is(Every game tick) giving you back the speed you had before colliding with walls if you are within a "playermove"-timer, the reason is when you do a waterjump(going out of water up to ground(Setting the playermove-timer and a flag)) you should slide up ledges but the game don't check the waterjump-flag but instead only checks if in a timer(Same as in QW,Q2) XD...

  • @benjaminauer
    @benjaminauer Рік тому +1

    i always wondered if skimming is a bug or desired feature. maybe looking at the code would clear it up

    • @TarenGarond
      @TarenGarond Рік тому

      I've read a lot of the movement code from of the Q1,QW,Q2,Q3 source codes and from the start(In Q3) it was very very likely a bug.
      But skimming might have been left in there to smooth-out jumping up/over stuff, as when falling down while hitting a ledge you step up but when going up you would just stop when hitting something if skimming wasn't present, but I'm quite certain there is a "deadtime" between "skimming-timer" and falling down(In a typical jump) so don't really make sense(If skimming was detected in development it might have been left in there for the heck of it though.... I don't know XD).
      By the way this comment "don't change velocity if in a timer (FIXME: is this correct?)" is seen before the code that allows skimming, XD...
      I will post an (slightly edited) old comment of mine(that I posted on a video about skimming/wallclipping) after this if you want to know more.

    • @TarenGarond
      @TarenGarond Рік тому

      The timer in Q3 starts when you land(if velocity[2] < -200), also the PMF_TIME_LAND flag is set.
      In Q3 there is one weird combined player movement timer(pm_time) with associated flags that is set to say what what the timer is currently used for.
      The flags are PMF_TIME_KNOCKBACK(Set when you're knocked back or launched out of a teleporter("Losing control")), PMF_TIME_LAND(Set when you land as said earlier) and PMF_TIME_WATERJUMP(Set when jumping out of water).
      PMF_TIME_LAND isn't really interesting here, it is just set but never checked anywhere(It was originally preventing the player to jump within the timer, as in early Quake 2 versions)!
      The PMF_TIME_WATERJUMP is the interesting one here(Kind of...), in QW wallclipping was introduced to easier get out of water letting you "slide" up on edges(I now know that QW "water jumping" over all actually works quite differently than in Q1, but yeah not going to explain this further.... XD).
      The timer in QW is set when jumping out of water and coming out of teleporters(I don't think there is any flags for the timer), when within the timer your velocity after clipping against surfaces is reset to the velocity you had before clipping(And therefore you slide against things without losing any speed).
      In Q2 and Q3 the timer is checked in the same way, no flags is checked!
      As said earlier the timer is set in Q3 when landing so that is what makes you able to wallclip!
      And actually you can wallclip with just one jump if it is a damage boosted one(The original comment-receiver wondered why you couldn't wallclip "the first jump" in Q3).
      It is normally a 250ms timer by the way(But can be manipulated with damage boosting of course).

  • @MrToadio
    @MrToadio 2 роки тому

    The command cg_overbounce_hud 1 cannot be found, and yes I did load the mod first. Any ideas? Using ioquake by the way.

    • @MattsRamblings
      @MattsRamblings  2 роки тому

      Does the line `File "vm/cgame.qvm" found in "/ob-hud/obhud1.pk3"` appear in your console output?

  • @maxwellmorris9189
    @maxwellmorris9189 2 роки тому

    when did you start coding? and what is your background? i am very interested.

  • @deadalnix
    @deadalnix Рік тому

    Wow! How did you write the mod?

  • @WarhelmeTR
    @WarhelmeTR 2 роки тому +1

    What about Quake 2? We need Quake 2 video also :)

  • @TheClonerx
    @TheClonerx 2 роки тому

    Incredible, and what makes this more interesting is that this in ULTRAKILL you can do almost the the same

  • @tryme25
    @tryme25 Рік тому

    Is this in quake live too?

  • @snakes_on_a_helicopter
    @snakes_on_a_helicopter 2 роки тому +2

    I would like for you to investigate the grapple in titanfall 2 especially how grapple slingshot ting works

  • @konkerouf
    @konkerouf Рік тому

    wasnt overbounced discovered by camping-gaz?

  • @eliseulucenabarros3920
    @eliseulucenabarros3920 Рік тому

    this is a mini game with the bug .

  • @nolan412
    @nolan412 2 роки тому

    The Half-Life 2 speedrun really exploited these kinds of bugs.

  • @xom.
    @xom. Рік тому

    Cod4 promod bounceeee

  • @user-sr6pi5lp3q
    @user-sr6pi5lp3q Рік тому

    Are videos only monetized after 10 minutes length?

  • @kurzackd
    @kurzackd Рік тому +1

    Considering Quake 3 's reputation of being extremely efficient, bug-free and smooth, how come this bug was NEVER addressed in all the game's years ??
    Sounds like a pretty big thing, and VERY abusable on the PRO level ?
    Is it a recent discovery?

    • @benj1008
      @benj1008 Рік тому

      AFAIK it's because 'pmove', which is the physics setting that is supposed to make player movement frame rate independent, was never turned on by default. I don't think it was ever used in anything but Defrag.

    • @kurzackd
      @kurzackd Рік тому +1

      @@benj1008 Are you telling me that in pro-matches, pros have this setting OFF, and thus -- their movement rates are frame-dependent? O_o

    • @envo2199
      @envo2199 Рік тому +2

      this was known since like 2005, i remember playing defrag maps with this trick ~20 years ago

    • @s4v624
      @s4v624 11 місяців тому

      ​@@kurzackdas Mat has explained in this video the overbounce bug is frame dependent this only works from 125 frames/second upwards
      Also pmove_fixed is set to 0 which makes it extra hard even if you would play with fps at or above 125 frames it is inconsistent.
      Hence why you dont see proplayers bouncing around
      But I remember in the beginning people actuallly used this until iD came in and added pmove veriable
      Also tournament organizers limited the max FPS to be bellow 125 frames in these days before pmove was intoduced.
      There is also another aspect PC systems werent advanced enough to even at framerates this high

    • @kurzackd
      @kurzackd 11 місяців тому

      @@s4v624 ya, fair points !! Thanks! :)

  • @ValenceFlux
    @ValenceFlux 2 роки тому

    How did that happen? What is going on? Who knows? Go faster!!!

    • @near5148
      @near5148 2 роки тому

      Gotta go fast!!!!!!!!!

  • @iq40
    @iq40 2 роки тому

    ty

  • @CZghost
    @CZghost 2 роки тому

    So features that defined the movement and physics style Quake 3 became famous for are bugs? This is truly the definition of a bug turning into a feature. Fun fact - most of these bugs exist even in Quake Live, id Sofware didn't bother to fix the bugs. Some bugs even had to be reintroduced as newer engine most likely fixed some bugs that resulted in a famous movement style, so in order to maintain the style of the game that defined Quake, they had to intentionally introduce the bugs back. Once Bethesda claimed id Software, they basically turned Quake into lootcrates filled junk with no intention to further improve the current games. Quake Live is only held together by its community, just like original Quake III Arena. Bethesda doesn't involve in further development of the game. They changed the game a bit, undoubtly making it worse and real pain for map makers that try to maintain a bit of game parity between Quake III Arena and Quake Live, and that's it. No more involvement and people have been calling for a fix of newly introduced issues for a very long time. Especially map makers find it really pain in the ass that runes do not spawn in their position in the world but rather in spawnpoints, completely irrational change decision from Bethesda that didn't even bother to fix the maps that were previously bundled with Quake Live when it was still id Software's property. They made some changes in the game code, which caused wreack havoc in other parts, like maps, and players hate it. I find empty runepads in previously bundled maps while the runes are still spawning in the map, just not in their original placement, but rather in spawnpoints. Bethesda tried to simplify the game to forcing the players to pickup the runes right at the spawn. But I hate that I get assigned a random rune that I don't want, I actually want to chose my rune, not forcibly take some random one and "deal with it". That's why I don't play Quake Live as much as before. But I'm going to call Bethesda out on that and actually demand to fix this. No more forced random choice. Also, as map maker I find it really painful to convert my Quake 3 maps to Quake Live only to find out that the runes are not in their places but rather randomly spawn somewhere completely else. That's just so wrong from Bethesda. Now don't get me wrong, Bethesda actually created one of the most successful franchises, which is Fallout series. That's actually pretty good. But Bethesda doesn't handle adopting games of other developers they bought very well. Quake Champions is pretty good game, not gonna lie. But the microtransactions inside the game are a little bit concerning to say last. Quake Live doesn't have issues with microtransactions, but the game has tons of unnecessary changes that actually ruined the game, which makes it even worse.

  • @mati3380
    @mati3380 2 роки тому

    ta fajnie, ale zamknij morde