Half-Life 2 NPC Movement Part 1: Local Navigation

Поділитися
Вставка
  • Опубліковано 26 гру 2024

КОМЕНТАРІ • 135

  • @ReverendPuffin
    @ReverendPuffin Місяць тому +231

    Glad you got some great recognition after the documentary for showing off the Ep3 Blob 3 years ago (and being correct in its use).

  • @Redstone_Co
    @Redstone_Co Місяць тому +92

    Honestly this is the part of source i was really wondering about, the AI, awesome that finaly someone covered it good
    God the jumping...

  • @npc_pigeon
    @npc_pigeon Місяць тому +242

    mmmm yes i have awoken to pinsplash, today is a fine day

    • @epicpersuasive
      @epicpersuasive Місяць тому

      Why did this comment say 2d ago but youtube says 20h ago

    • @block_place1232
      @block_place1232 Місяць тому +3

      ​@@epicpersuasivechannel members getting the video earlier

  • @_motho_
    @_motho_ 13 днів тому +6

    The code checking for "if physics prop is walkable and the trace lands 9 units up" is to make sure NPCs cant use physics props to get into places theyre not supposed to. Say the player drops a pallet at an angle near a small ledge. We need to make sure NPCs cant use that pallet to path up the ledge, so that code makes sure whatever theyre pathing on isnt an inclined physics prop. Essentially we only want NPCs pathing like that if theyre pathing on map geometry, not dynamic or static objects.

  • @SkylorBeck
    @SkylorBeck Місяць тому +65

    And now it makes sense why Gmod died when I spawned too many fast zombies as a kid

  • @khajiitstolenothing3367
    @khajiitstolenothing3367 25 днів тому +12

    3:57 Alyx's speech bubbles about Gordon are kinda cute

  • @RaptorMocha
    @RaptorMocha Місяць тому +86

    ya know the crawling movement type was probably intended for the torso zombies then they just kinda realized “thats stupid just make them use the walk movement”

    • @TomatoRadio
      @TomatoRadio 8 днів тому +5

      Or for Rebels to follow you through vents or other low areas. Probably was deemed not worth it, which it isn't.

  • @JeroenDStout
    @JeroenDStout 27 днів тому +16

    From a math perspective it really hurts to hear regular vectors described as "not your standard C++ vectors"

  • @1upD
    @1upD Місяць тому +34

    This is very informative and well put together. I really appreciate the deep dive and I wish there were more videos made like this.

  • @Cjramos23
    @Cjramos23 Місяць тому +36

    I love these sorts of videos, instantly went into my watch later

  • @Winsane
    @Winsane 21 день тому +4

    The NPC knows where it is at all times. It knows this because it knows where it isn't.

  • @gameworkerty
    @gameworkerty Місяць тому +42

    Honestly this is what I wanted from the HL2 developer commentary mode

    • @SiisKolkytEuroo
      @SiisKolkytEuroo 28 днів тому

      Maybe there could be a mod that replaces the voice lines with this

    • @chippym8316
      @chippym8316 28 днів тому +7

      ​@@SiisKolkytEurooIt just replaces every dev com with this video playing at 240p.

    • @soupcangaming662
      @soupcangaming662 22 дні тому +4

      @@chippym8316 Also includes brush + displacement breakdown. Bonus feature: "Your idealism is an epic failure".

  • @explodingbearz
    @explodingbearz Місяць тому +39

    Dinner and pin splash is peak

  • @gobletgobletstein5672
    @gobletgobletstein5672 Місяць тому +7

    technical pinsplash video is exactly what I wanted to see this morning thank you so much

  • @crazychicken767
    @crazychicken767 Місяць тому +5

    Ahh I can't wait to rewatch this 40 times

  • @danin900
    @danin900 Місяць тому +36

    I was filled with Entropy, but it has Zeroed out.

  • @blu3m0nkey
    @blu3m0nkey 23 дні тому +2

    Swiming is used for the unused shark enemy (found in hl1 water levels, and in one of the teleporter sequences in kliners lab)
    Fun fact, the crossbow is meant for the shark, happily, it was still used after its discontinument.

  • @kalel4everr
    @kalel4everr Місяць тому +3

    I expect this will be useful for making gmod maps, ty for making this video!

    • @buck_et
      @buck_et Місяць тому +4

      Femtanyl pfp??/ Femtanyl mentioned?!?! 🗣🔥🔥🔥

  • @Polish_Beekeeper
    @Polish_Beekeeper Місяць тому +36

    I just realized ur pfp is that one lick thing

    • @JuanGamer0202
      @JuanGamer0202 Місяць тому +11

      This shit was everywere in forums back in 2010s lmao

    • @Krezzing
      @Krezzing Місяць тому +4

      What

    • @Pinsplash
      @Pinsplash  Місяць тому +29

      👅

    • @Tuntor689
      @Tuntor689 Місяць тому +9

      wait what’s the lick thing

    • @slugcatsu
      @slugcatsu Місяць тому +3

      it is indeed that one lick thing

  • @UnimportantAcc
    @UnimportantAcc 27 днів тому +3

    Bruh that jumping calculation. Now that's quality coding

  • @acousticfacts
    @acousticfacts Місяць тому +5

    1:03 floorpoint to nlo, floorpoint to new little odessa, come in odessa

  • @UziIdiot
    @UziIdiot Місяць тому +2

    Since seeing the source 2 npc navigation I was wondering what source 1's was since it seemed like such a tiny detail. Thank you for this video it has explained so much

  • @sosug
    @sosug Місяць тому +8

    FUCK YEA I AM SO FUCKING HAPPY NOW THAT I WILL MAKE DINNER AND WATCH THIS VIDEO RIGHT NOW

  • @ZanyCat
    @ZanyCat 28 днів тому

    i just want to say you have a really calm and relaxing voice and i could listen to you talk for hours about literally anything

  • @hansonkerman7286
    @hansonkerman7286 Місяць тому +16

    hell yes 🔥🔥🔥🔥 source engine guts detail just as i start replaying hl2 to listen to the new dev commentary
    (i feel the need to declare that i really like the new font)

  • @m1kegame_dev456
    @m1kegame_dev456 Місяць тому +7

    I love half life 2, I really hope these HLX files are Hl3, my hopes are higher than the moon.

  • @NoahGooder
    @NoahGooder Місяць тому +22

    as one of the modders who played with the original 2013 sdk I think we are far into hl3 territory unless they feel nice and release the source 2 sdk.

  • @Lugent
    @Lugent Місяць тому

    Man, waking up and see a technical pinplash video (youtube took days to recommend this despite the bell enabled as All :p) what a good start of a day.

  • @Coolkidstan
    @Coolkidstan Місяць тому

    I NEED this more often. Thank you so much dude.

  • @unfa00
    @unfa00 29 днів тому

    5:20 - I suspect that "checking if a position qualifies as a step" is about making sure that there is basically room for the character to stand there. Probably to prevent 1-unit long steps to be climbable?

  • @DetectivePoofPoof
    @DetectivePoofPoof Місяць тому

    Damn that's great! Good job going through and explaining all of this I was always curious about how some things actually work in that game.

  • @Volkswagen_Yeetle
    @Volkswagen_Yeetle Місяць тому +5

    Bros mic said: "Bass? I'll take all of it."

  • @MacaqueStinx
    @MacaqueStinx Місяць тому +3

    I love you pinsplash

  • @ijre
    @ijre Місяць тому +1

    awesome stuff, thanks

  • @Taras195
    @Taras195 Місяць тому

    Awesome analysis!

  • @gildun
    @gildun Місяць тому +6

    Pinsplash is back!111
    Hope you'll never gonna make videos that gonna put an entire community against you.
    Anyway, glad you're back.

  • @ahsanyousuf7071
    @ahsanyousuf7071 Місяць тому

    Pinsplash uploaded? We're sleeping good tonight.

  • @rtsoldat
    @rtsoldat Місяць тому

    heyy just found out your channel, great video!! keep them coming! i want to know all about nav meshes now lol

  • @NoReasonToAnwser
    @NoReasonToAnwser 3 дні тому +1

    The stand check is most interesting to me for my own hobbyist game dev purposes as I could use it to improve my character controller. Would anyone know if there is a resource for it that goes into greater detail?

  • @ctrlaltrepeat245
    @ctrlaltrepeat245 17 днів тому +1

    There is no Entropy Zero 2 video in ba sing se

  • @Bozothcow
    @Bozothcow Місяць тому

    This is what we desire.

  • @Igor_Zdrowowicz
    @Igor_Zdrowowicz Місяць тому +3

    vec3 are always kinda float trios 🧐🤓

  • @AlexVonBronx
    @AlexVonBronx Місяць тому

    Less than 24 hours ago I thought to myself "man, Pinsplash hasn't made a new Half Life 2 analysis video in a long time" and her e we are.

  • @paradoxicalegg6112
    @paradoxicalegg6112 27 днів тому +5

    wait weren't you the guy hating on ez2

    • @equinox3665
      @equinox3665 22 дні тому +4

      yes he was lol

    • @kornsuwin
      @kornsuwin 11 днів тому +2

      what's the problem with having an opinion

    • @dk1480
      @dk1480 День тому +1

      ​@kornsuwinthe problem is people dislike it

  • @cahrsiegui8184
    @cahrsiegui8184 19 днів тому

    Goated video

  • @PattPlays
    @PattPlays 27 днів тому

    Using whst you have looked at, could you design a source map and drop a unit and a goal on opposite ends of an obstacle in a way where you know the solution will take the program a visible stretch of time to figure out.
    I find it funny to think of an npc walking up to a glass wall with gordon on the other side and just .. thinking .. processing.. then takes one of like 16 exits to get to him.

  • @L_U-K_E
    @L_U-K_E Місяць тому

    Very interesting mate 👍

  • @FOXY_ANIMATIONS
    @FOXY_ANIMATIONS Місяць тому

    keep it ,youtube lacks this type of source engine videos

  • @dkskcjfjswwwwwws413
    @dkskcjfjswwwwwws413 Місяць тому +17

    so this is how my favorite source game and replacement for hl3, entropy zero 2 works

    • @IllagerRaids
      @IllagerRaids Місяць тому +8

      This gonna make him 3650 times more mad

  • @terrestrialTerror
    @terrestrialTerror Місяць тому

    that ending was slick

  • @seyidhanbingul3656
    @seyidhanbingul3656 Місяць тому

    Yeah man please keep going. And save joe...

  • @SophiaWoessner
    @SophiaWoessner Місяць тому

    myess I hath been summoned

  • @humanharddrive1
    @humanharddrive1 Місяць тому

    Part 1? Who would make such thing into a series?

  • @neilharrah7365
    @neilharrah7365 19 днів тому +2

    Any plans to put the chaos mod on workshop?

    • @Rons058
      @Rons058 13 днів тому +1

      +

    • @dk1480
      @dk1480 День тому

      Workshop doesn't allow code modification

  • @lenship2
    @lenship2 Місяць тому

    pinsplash is straight up moving the npcs now ......

  • @amanda_bynes226
    @amanda_bynes226 Місяць тому

    took me a couple views but this was a fantastic explanation

  • @CalavErik
    @CalavErik Місяць тому

    I do like the new font

  • @SamTuffman
    @SamTuffman 27 днів тому

    Great video, I once messed with my own pathfinding, and using source's navmesh was easy but never really thought about pathfinding within each NavArea, I just said whatever and made each area smaller to better account for any obstructions.
    Also do you know when node graphs versus when navareas are used?

  • @nikitakrapivinalt
    @nikitakrapivinalt 20 днів тому

    the sun is leaking

  • @DriftJunkie
    @DriftJunkie Місяць тому

    7:01 I wish someone would explain this corner case 🤔

  • @Max_Marz
    @Max_Marz 28 днів тому

    The npc’s hole… (spits coffee)

  • @ZanderArchX
    @ZanderArchX Місяць тому

    So they can trace a path to an ending position, but does the missile know where it is?

  • @randigo9992
    @randigo9992 Місяць тому

    Can you mess with code like this and make HL2 but very weird and cursed, like in a way that it looks okay at first but then NPCs do weird stuff like Grigori jumps for no reason or something

  • @PiuFan
    @PiuFan Місяць тому +3

    Why u deleted video and post about EZ2 on your channel?

    • @tincan357
      @tincan357 Місяць тому +4

      people got really mad at him and i guess people were also upset with the post on why he deleted the video, idk exactly but i feel like people should just move on

  • @sanitylost4271
    @sanitylost4271 Місяць тому

    Can you make a vid about map changes in anniversary update?

  • @Freak_Gamer
    @Freak_Gamer 29 днів тому

    Could you do a video like this but for HL Alyx / Source engine 2? I really want to know how valve improves things with a decade of time. Did it get faster? Slower? More accurate?

    • @SamTuffman
      @SamTuffman 27 днів тому

      Idk if thats possible, we have access to hl2's source code, but we dont really have access to Alyx's source code. The closest we have is sbox's implementation, and their api documentation is kinda terrible.
      I'm sure when it comes to local navigation, its pretty different as the antlions are slow in Alyx, theres no jumping or any special move types like that, but the fundamentals are still there. They probably still use traces, and when it comes to actual navigation, a navmesh.

  • @jettjame
    @jettjame 25 днів тому

    pinsplash ur a fking legend

  • @liverygone
    @liverygone 18 днів тому +1

    0.5 percentile of watch time apparently I've watched five times as much as the average viewer of your channel

  • @wuspoppin6564
    @wuspoppin6564 Місяць тому

    14:50 views retention probably goes crazy here

  • @ValiantNorth
    @ValiantNorth 16 днів тому

    Step Check, I'm stuck

  • @ardon8399
    @ardon8399 Місяць тому

    have you ever made any finished maps or mods yourself? since you know so much about the source engine

  • @CharlesVanNoland
    @CharlesVanNoland Місяць тому +3

    This seems way overcomplicated and gnarly. I would aim for doing something like generating a Minkowski sum between the relevant section of the world's collision hull (which I guess in the case of the Source engine would be the BSP leaves themselves) plus other entities' collision hulls and the NPC's collision volume, and then just trace a polyline path through the result as it would automatically eliminate anything that would block the NPC's path. Then I'd just re-evaluate the path at a fixed interval, just like with AI units in an RTS game. I'd try to collapse the whole problem down to something more like a 2.5D navigation situation and not have all these special-case checks for different little things and edge-cases in 3D, which is janky and not very robust or extensible (which is why it has so many bugs, like holding the barrel over an NPC's head when it starts pathfinding). Someone was really tweaking on all this code back in the day instead of just coming up with a fast and simple robust solution!

    • @gobletgobletstein5672
      @gobletgobletstein5672 Місяць тому

      yep that's source engine for ya

    • @chocolates182
      @chocolates182 Місяць тому +1

      as someone who doesnt know about coding, this sounds like wizard magic

  • @Darnk715
    @Darnk715 Місяць тому

    What are headcrab attacks considered?

  • @Olivman7
    @Olivman7 29 днів тому

    Wait, so NPC navigation in Source doesn't use A* at all?

    • @SamTuffman
      @SamTuffman 27 днів тому

      It probably does, this is just for local navigation. Hes probably going to talk about NavAreas in the next part.

  • @MarkRosOfft
    @MarkRosOfft Місяць тому

    Actually I love making story maps for hl2 in hammer, but the complicity of its movement is killing me

    • @MarkRosOfft
      @MarkRosOfft Місяць тому

      scripted_sequence my behated

  • @vrad_exe
    @vrad_exe Місяць тому

    If you an NPC, you are from video games.

  • @chen939
    @chen939 Місяць тому

    Noting this down. I mean sure I've read the sources to NPC navigation but still.

  • @captainethanol1332
    @captainethanol1332 29 днів тому

    Man I'm not even interested in this aspect of hl you just explain shit good

  • @tiga0006
    @tiga0006 Місяць тому

    How do you know that so precisely?
    Did you read the source code? It sounds to me like you're reading from the source code while explaining! :D If that, do that, loop 16 times through, otherwise to this and so on....

    • @SamTuffman
      @SamTuffman 27 днів тому

      Yes, the hl2 source code has been leaked many times, but hes probably just using the soruce-sdk which was released by valve like 10 years ago. It sounds like hes even modifying the code himself as well.

  • @PlasticCogLiquid
    @PlasticCogLiquid Місяць тому

    I guarantee all the 'weird' code that doesn't seem to make sense is there for a reason. If you remove it I bet some stuff will break eventually. I've learned that the hard way even going back and screwing with my own stuff that I wrote a long time ago "Why'd I do that? How stupid, DELETE!" then the whole thing breaks.

  • @TheBoringEdward
    @TheBoringEdward Місяць тому

    How high did you raise the low ends on your recording?

  • @CorruptedDogg
    @CorruptedDogg Місяць тому

    who up splashing they pin

  • @issholland
    @issholland 4 дні тому

    UA-cam tells me i used to be a member here. What?

  • @nonsense-me
    @nonsense-me Місяць тому

    Nice

  • @afbanjagjafdbxcvbrtjwsasdg2825
    @afbanjagjafdbxcvbrtjwsasdg2825 29 днів тому

    Hull, not hole. That's already the same pronunciation for two common words.

  • @rubysvndev
    @rubysvndev Місяць тому

    holy peak

  • @tools.shoe.country.quickly
    @tools.shoe.country.quickly Місяць тому +1

    yayyyyyyyyyyyyyyyyy hl2 ai

  • @andreisechi7871
    @andreisechi7871 Місяць тому

    Bro casually decided to make tutorial about source engine ,this Is getting out of control😢

  • @dr.angerous
    @dr.angerous 29 днів тому

    Noice

  • @viannizvnv7222
    @viannizvnv7222 Місяць тому +1

    alright, back to normal

    • @Kaltrademarked
      @Kaltrademarked Місяць тому +6

      we are not to speak of the entropy zero incident

  • @Rain0T
    @Rain0T Місяць тому

    10:38 i agree, the new font is gross

  • @Greenhourglass
    @Greenhourglass Місяць тому

    glad i'm not the only one that doesn't like the new font :(
    at least it's still there in HL2:DM....
    because they're just gonna bury it instead of updating it...... 🫠