Forgot to mention that respawned enemies always have their reaction time set to 18 so they don't instantly attack you if they respawn in your proximity. There's a lot to talk about the AI, so there's probably more stuff I forgot to mention. If I gather enough material I'll make a bonus episode.
i am lucky that CacoDemons don't resapwn it would be a nightmare ( sorry if i accideantrly pronnounced "cacodemons" wrong i haven't played doom in ages tbh)
its because the Punch and the Chainsaw are Hit scan weapons in the source code there just coded to only affect damage if your next to the Actors Hit box. Doom removed stealth in it's melee attacks as the Knife in Wolf 3d was Silent and that function for weapon slot 1 was retained in the Blake Stone games the combat knife was replaced with a ranged self recharging energy gun with normal range but kept the stealth function. it only failed if you did not kill the actor and the alert sound would wake up every one in the room without a Deaf Flag.
"When you make a sound." But all you did was punch the air, unless Doom Guy is punching the air so hard that it's literally breaking the sound barrier.
@@portablerefrigerator4902 oh yeah worst spoiler ever... I mean come on dude this isnt a gameplay or a narrative video just a informative one about how the ai works
Doomguy: “Oh? You're approaching me? Instead of running away, you're coming right to me?” Baron: “I can’t get the shit beat out of me without getting closer.” Doomguy: “Oh ho! Then come as close as you like.”
I'd heard about the grace period before a monster fires at you, but seeing the example of regular (and even regular with fast monsters) vs nightmare makes that second mode's description of "not even remotely fair" make so much more sense.
Videos like this remind me of how incredible we humans have achieve when it comes to coding and video games as a whole, like really, look at all this work and all that. Suggestion, look up for "how does pokemon sprite work" that is insane too....
I understand it was John Romero who coded all the interactive stuff from the engine. I'd like to know if he coded too the monsters and all the gameplay stuff (except for Status Bar and Automap which were made or finished by Dave Taylor), as the editing tools and the environment behavior are credited to Romero, and here also seems to be the case.
Theres a reason why civvie gives jc those super long titles, John's an actual rocket scientist and in some other dimension an actual evil dictator that rules the world
The official source port that id Software uses for consoles and is bundled with Doom Eternal is made from scratch in Unity. There is more info in the Doom wiki here doomwiki.org/wiki/Doom_Classic_Unity_port
When I was a kid playing this game, I always wondered why there were small holes in the walls of some maps, Now I know that it was there for sound to wake up a hidden room full of monsters so they can teleport into the map. I always just thought it was the last secret I couldn't find.
@@acidwizzardbastard E1M9 "Military Base" in the original Doom (room with the Rocket Launcher) and Map 16 "Suburbs" in Doom II (big outdoor fight near the toxic waste lake) are two notable examples.
@@xt355 Military Base - The hole is in the top of the wall directly across from the stairs: ruclips.net/video/fLzz51ReF20/видео.html Suburbs - The hole is on the left, in the wall just below the ledge that leads to the toxic pit: ruclips.net/video/FOcDWLTnk-s/видео.html
Or in MAP01 of DooM II too, the secret closet with 2 imps and a stimpack had a hole in its top left corner leading all the way to the fenced but open closet with an imp on the right. That caused the sound to propagate from the main room, into the fenced closed, through the hole and into the secret.
The most impressive part of Doom's AI is that it's so randomized, so unpredictable, fighting each enemy doesn't feel the same although basically they really are. Kudos for ID fellas' programming!
@@IchigoMait while it is deterministic (demos just repeat player inputs afterall), there are so many calls to the rng array that doing something the same way twice is impossible for a human to actually do past the very first action they take. It's effectively random.
Honestly this is an understated point. I've played indie games with "simple AI" where all they did was instantly turn to the player and effectively "hold forward". I felt this to be very unfun to play against. This highlights a very basic yet super important point about AI: Fun has nothing to do with how simple or complex the AIs are, and game AIs should focus on being fun. Its okay that they're stupid, because they're stupid in a way that makes them fun to dispatch.
No. Damage is random. Things like pain states and Wether an enemy dies depends on the outcome ofrandom damage. Monster chase behaviour has some randomness. There is some random spread on some weapons. The player cannot see through pseudorandom numbers and know the state in real time. Pseudorandomness looks and feels like randomness.
@@ttty2242 They are from two different canons. Doom guy is a disgraced space marine from the original Doom series. He's a good guy but otherwise a normal but determined person. Doom slayer is from the new series, and he's very much not ordinary in any way.
Best kind of videos, I can't get over how well produced they are. No fluff, no idiotic intros, no bullshiting around, straight to the point and facts supported by code itself - WONDERFUL!!
@@rompevuevitos222 interest is important, but coding experience helps a lot. i can't even imagine, how someone new to the topic could follow. this is basically video assisted C-code hypes me up for going through the source, though
@@BrauschN When you're intersted in something, you can put as much time into it without getting as worn out/bored as someone who doesn't really "dig it" Wich considering that indeed is REALLY hard to get into coding, it's really important
Demon:"Dark lord we have come up with 2 strategy's for dealing with the doom guy. strategy 1 overwhelm him with a highly coordinated tactical assault comprised of our most elite demons. strategy 2 run up to him screaming like madmen and fire wildly. which do you choose?" Dark lord:"....."
Sure doom has 3d coordinates, but nothing in the game is an actual 3d model. If that were the case, levels would be nowhere near as editable as they are.
@@illuminatidad yeah the map geometry is super simple collections of planed sprites it’s not full 3d modeling or anything, that’s why the objects and layouts are a bit limited
Man I'd wish this video existed 20 years ago, I had to understand most of this stuff the hard way when there wasn't that much documentation on the game, yet this still revealed stuff I wasn't aware of like Barons not turning around. Great video!
I don't know if you mentioned it anywhere before so sorry if you did... But, are you a programmer by a chance? Because if not, then I'm kinda curious what helped you understand C code this well.
The next time someone says "game coding can't be that hard" I'm gonna be like "cool, here's a vid dissecting the code of a 27 year old game. Lemme know when it makes sense to you."
This code is elegant in its simplicity. Having modded Quake 2 in the late 90s and then a bot to work with it, reverse engineering id's dense clean code was a breeze, I had zero prior experience with C++ and was able to get in there and figure out everything from the simple cluster nade mod to the server side and client side flows in days, with only a c++ syntax reference
First I thought that I would say that the code seen in this video is actually pretty elegant and easy to understand - for a programmer. Then it dawned upon me that anyone who already had experience in programming wouldn't make that statement anyway, so yeah :)
This is what makes Doom a masterpiece, and what kids, idiots and journalists don’t see behind its apparent simplicity. Many later bad shooters had crap AI, because their creators wasted all their time on graphics.
This is awesome! As a IT engineer, anyone out there looking to get into software dev should subscribe to this guys channel. Excellent analysis of the code and even explained how some of the bugs/in game hacks work. Great job!
Your video editing skills are underrated. So clear, no unnecessary flowers, great visual examples. I enjoy this series as Doom was a fav of mine as a kid.
Still the best videos. No bad timewasting jokes, great editing, and straightforward explanations of Doom's fascinating programming. Eagerly awaiting the completion of your Sunlust playthrough. Great thumbnails too.
This is maybe one of my all-time favorite videos ever. As just a hobby game programmer, it is so inspiring. I really wish there were more videos like this, explaining source code in such a rapid fashion. Best video ever.
What? The chaingunner actually has more than one line of code other than telling it to shoot gun until player in view is dead? Edit - 9:34 I remember learning from civvie that the red symbol on the side of that door means there's demons inside. I'm learning so much I'm going to upgrade from tiny spider to Rick and Morty Mastermind spider in no time.
i'm glad you specify "no not oney" in every video now because it genuinely does catch me off guard every time i hear the name and i was wondering about it but i didn't want to ask cause thats weird.
WTF man, I was literally thinking the other day: "Wouldn't it be cool if decino made a video about Doom's AI?" 😀 Great video, very thorough, I guess it took you a lot of time...
I like how you give detailed specifications by poring through the code. It's easy to forget it's just a computer procedure when you actually play it, but you really give a coders level understanding of everything. It's amazing that you can just look at the code and say "ahhh, I understand all the implications of all of this". If you had written the code and were proudly explaining how the code you created worked that would be one thing, but you're analyzing open source code made by someone else.
Now I finally understand why some monsters won't walk down some stairs. And also why it's possible to keep shooting at an idle monster until it dies, without it ever waking up and attacking the player. Thank you so much for all those explanations.
Amazing how much programming goes into just making the enemies do something like decide whether to remain idle. Makes you appreciate designers more, instead of wanting to complain about glitches 😄 Also realize just how ahead of the curve id was
I was surprised the sound propagation was so physicality correct going through sectors and being blocked by closed doors... Thank you for another great insight. Spent many tens of hours staring into Carmack's code yet never figured this out
The work for understanding the AI working, just deserve the blue thumb. Thank you for the work, the search, and the time you take to make us understand
Man, those recent Doom ports are all sorts of weird. Really great video man. Keep it up. Also, 9:49 haha. It's funny to see that from the side. It's like 'Flappy Cacodemon'.
What really blew me away is that Carmack opted to use bitwise operations whenever possible. Take the bit at 12:04 for example: the enemy's height is quartered using a bit shift two places to the right, and then it gets shifted back 2 places when resurrected. This is especially important here since subtractions and multiplications are fairly expensive operations computation-wise, while bitwise operations are about as cheap as you can get. It's pretty insane to what lengths he went to optimize the game, and how inventive he was at it.
Forgot to mention that respawned enemies always have their reaction time set to 18 so they don't instantly attack you if they respawn in your proximity. There's a lot to talk about the AI, so there's probably more stuff I forgot to mention. If I gather enough material I'll make a bonus episode.
Nice
Fantastic breakdown as usual. The reaction time is pretty neat to know about as well as what causes some enemies to be stuck
i am lucky that CacoDemons don't resapwn it would be a nightmare ( sorry if i accideantrly pronnounced "cacodemons" wrong i haven't played doom in ages tbh)
Gib>jib
Gif>jif
To be fair is ok you forgot info so 1) we can still manage to understand the info and 2) we get to see another video of yours lol
Doomguy: *punches air*
Demons: *_E n e m y s p o t t e d_*
True
lol so true
Well, Doomguy can KO demons with a punch. With a swing that strong, I'm sure there's an air *whoosh*.
I charge at them when i have the berserk in Doom and Doom 2
its because the Punch and the Chainsaw are Hit scan weapons in the source code there just coded to only affect damage if your next to the Actors Hit box. Doom removed stealth in it's melee attacks as the Knife in Wolf 3d was Silent and that function for weapon slot 1 was retained in the Blake Stone games the combat knife was replaced with a ranged self recharging energy gun with normal range but kept the stealth function. it only failed if you did not kill the actor and the alert sound would wake up every one in the room without a Deaf Flag.
How to kill Doomguy
1: Walk towards enemy
2: Attack
3: Celebrate
@@comet-fy6pd *pain locked
Pro Tip: To defeat the Doomguy attack him until he dies,
Not a single person is aloud to like this comment anymore.
@@breakfast3006 for that
i liked his comment
@@timbabcock4757
And that, together with the attention you gave them, is precisely what they wanted to happen.
doomguy: holds very loud chainsaw
demons: i sleep
doomguy: punches air
demons: real shit?
Real shit indeed
Doomguy: shoots pistol
Demons on the other side of the map: *ASCENDED*
@@kingd8232 lmao
someone needs to make a sprite for doom that replaces the punch with doomguy clapping really loud.
I like your party hat
"When you make a sound." But all you did was punch the air, unless Doom Guy is punching the air so hard that it's literally breaking the sound barrier.
R4ND0MCR4P123 he is lol
well yeah he is
Dude, why didn’t you just ASSUME that he was breaking the sound barrier when he punches? Do you have ANY idea what doomguy is?
Now I want a mod that changes the punch miss animation to a clap.
Probably why he can kill demons with his fist
"Even dead enemies think" is probably one of the most video-gamey quotes I've ever heard and I love it :)
Never played multiplayer FPS before?
but do odd dead enemies think?
Fuck you. You spoiled it.
@@portablerefrigerator4902 damn bro sorry to hear you got the doom AI spoiled for you.
Really ruins the narrative.
@@portablerefrigerator4902 oh yeah worst spoiler ever...
I mean come on dude this isnt a gameplay or a narrative video just a informative one about how the ai works
Doomguy: “Come over here and fight me baron!”
Baron of hell: “Dude I can’t, command told me you’re not in my line of sight.”
Imagine a Doom mode called "Algorithmic Doom": every demon stops to enunciate everything they are going to do before doing it.
"Take this Doomguy, my ultimate technique! Max Damage Roll Homing Missile!"
Here comes flame boi...
@Ll Dd coming right to me
@ beat the shit out of
"You shoot at them, they get hurt and they die"
The entire lore of doom using a short phrase
The lore of Doom:
Kill things
Kill more things
Kill even more things
Kill angels because they’re working with demons
Kill eternal...ly.
@@thebiolibrary5572 And then at long last
Kill guy who made all things
Get all weapons, pretty much kill god, and then something stronger, all while killing thousands of helpless demons.
Doom lore: YA KILL SHIT
@@thebiolibrary5572 And kill big cow man called the icon of sin.
When the Revenant is walking, he looks like he's slapping the air while trying to hit you.
"Okay, Doomguy, I'm gonna start slapping air like this, and, if you get hit, it's your OWN fault."
He's just swatting flies. Flies like skeletons.
@@DjTake1One tryin to clap them cheeks
@@DjTake1One best comment
Skeletons are always the silliest.
"NYEH HEH IVE GOTCH YOU NOW HE-MAAN!"
You made me understand why a Cacodemon 180º noscoped me yesterday
Lmao
That brings the question of how the hell a caco would hardscope
@@GhostofFarta focusing its eye i guess
@@GhostofFarta A monocle, obviously
@@CT-1118 surley
Lost souls: *Charges at doomguy*
Doomguy: *Dodges*
Lost souls: Understandable, have a nice day
It do be like that tho
lost soul: mimir
a mimir 😭
I saw the tiny thumbnail and went “He didn’t.” And he did. Wow
is there a reference I'm not getting
Pocari S yeah
Real
No.
@@breakfast3006 thx
"The F State, where a player encounters 60 revenants in a single room of raised platforms and slams their keyboard through the monitor."
Or 60 archviles.
*Typing of IDDQD at mach 10 speed intensifies*
Top coment god
@@Psychoangel-d23 lmao a pro gamer here
@@jestfullgremblim8002 You gotta draw the line somewhere. And mass revenant spam is mine.
Doomguy: “Oh? You're approaching me? Instead of running away, you're coming right to me?”
Baron: “I can’t get the shit beat out of me without getting closer.”
Doomguy: “Oh ho! Then come as close as you like.”
Shiro: ''It's a trap!''
It was me, Doomguy!
When your wish of "dying" just reach a new level.
Jojo references
*Doomguy holding a super shotgun*
"HOHO, I could say the same about you!" *BOOM*
If computer science teachers are this thorough and efficient, I would be a better programmer
this is why I listen to doom music during lectures, it makes me feel like I’m listening to decino and it helps me focus
Guys, I'm starting to think this guy likes DOOM.
Nah, he’s more into wolfenstein
Nah he’s into fallout
All of y’all are stupid he is clearly into cyberpunk 2077
Idiots. He plays Halo.
You fools, he enjoys the superior Barbie Salon Tour most.
I'd heard about the grace period before a monster fires at you, but seeing the example of regular (and even regular with fast monsters) vs nightmare makes that second mode's description of "not even remotely fair" make so much more sense.
Videos like this remind me why I never got into coding. I salute people who can do it.
friendly reminder that the source code for Doom 1 is actually really clean C. Just try to start modding and you'll become familiar.
Videos like this remind me of how incredible we humans have achieve when it comes to coding and video games as a whole, like really, look at all this work and all that. Suggestion, look up for "how does pokemon sprite work" that is insane too....
@@cfdeers someone should hire that carmack dude, i think he might be pretty smart
@Agent 005 and hes working on AI.
@Agent 005 He did, but prioritizes AI now.
2:07 POV: you said something slightly offensive and the teachers heard you
he is coming
Gavrilo Princip
LMAO 😂😂
Like that one fancy dude in Sarajevo.
Run boi
Pov: you opened a pack of gum in class
Doomguy: *swats at fly in the air*
Every demon in a 10000 foot radius: _So you have chosen..._ *_death._*
No You have chosen death I merely started the conflict
Doomguy: you fool, *I am death*
Now all of Hell knows you are here!
This is one heck of a video.
Also, Jesus Christ what was John Carmack smoking when he wrote his code, he's something else.
JC has certainly earned being the target of all those super-genius-coder memes and then some!
I understand it was John Romero who coded all the interactive stuff from the engine. I'd like to know if he coded too the monsters and all the gameplay stuff (except for Status Bar and Automap which were made or finished by Dave Taylor), as the editing tools and the environment behavior are credited to Romero, and here also seems to be the case.
Benevolent hyperintelligent juvenile delinquent John carmack
Theres a reason why civvie gives jc those super long titles, John's an actual rocket scientist and in some other dimension an actual evil dictator that rules the world
@@bioman1hazard607 other dimension? For all we know, he just hasn't begun yet
Decino: *drops Doom knowledge*
Id devs: "Huh, I never knew that"
Given the omissions in the official Unity source port, I actually think decino knows more about the internals of Doom that the current devs at id do.
The official source port that id Software uses for consoles and is bundled with Doom Eternal is made from scratch in Unity. There is more info in the Doom wiki here doomwiki.org/wiki/Doom_Classic_Unity_port
Carmack knows everything, EVERYTHING
@@doodguytheblank2403 Yeah but he's an interdimensional tech-warlock.
@@doodguytheblank2403 I dont think even carmack knew about archies making ghost monsters
When I was a kid playing this game, I always wondered why there were small holes in the walls of some maps, Now I know that it was there for sound to wake up a hidden room full of monsters so they can teleport into the map. I always just thought it was the last secret I couldn't find.
Like which maps? Pardon me, I've just never noticed these.
@@acidwizzardbastard E1M9 "Military Base" in the original Doom (room with the Rocket Launcher) and Map 16 "Suburbs" in Doom II (big outdoor fight near the toxic waste lake) are two notable examples.
picture?
@@xt355 Military Base - The hole is in the top of the wall directly across from the stairs: ruclips.net/video/fLzz51ReF20/видео.html
Suburbs - The hole is on the left, in the wall just below the ledge that leads to the toxic pit: ruclips.net/video/FOcDWLTnk-s/видео.html
Or in MAP01 of DooM II too, the secret closet with 2 imps and a stimpack had a hole in its top left corner leading all the way to the fenced but open closet with an imp on the right. That caused the sound to propagate from the main room, into the fenced closed, through the hole and into the secret.
The majority of a Revenant's life cycle consists of dancing, the rest is dying.
Doomguy: swings arm
Every enemy nearby on nightmare difficulty: "So you have chosen death"
The most impressive part of Doom's AI is that it's so randomized, so unpredictable, fighting each enemy doesn't feel the same although basically they really are.
Kudos for ID fellas' programming!
@@IchigoMait Doom speedrunners want to argue with that. There is enough conditions in the code to make mobs semi-random at times.
@@IchigoMait while it is deterministic (demos just repeat player inputs afterall), there are so many calls to the rng array that doing something the same way twice is impossible for a human to actually do past the very first action they take. It's effectively random.
All thanks to the extradimensional being living in a cocoon named John Carmac
Honestly this is an understated point. I've played indie games with "simple AI" where all they did was instantly turn to the player and effectively "hold forward". I felt this to be very unfun to play against. This highlights a very basic yet super important point about AI: Fun has nothing to do with how simple or complex the AIs are, and game AIs should focus on being fun. Its okay that they're stupid, because they're stupid in a way that makes them fun to dispatch.
No. Damage is random. Things like pain states and Wether an enemy dies depends on the outcome ofrandom damage. Monster chase behaviour has some randomness. There is some random spread on some weapons. The player cannot see through pseudorandom numbers and know the state in real time. Pseudorandomness looks and feels like randomness.
6:49 "They'll toss a projectile from their behinds."
So, basically they fart out a projectile.
Baron of Farts! :)
Me after coffee in morning :)
Pretty sure he bled a bit when "expelling" the projectile
That's commitment if i've ever seen any
And it's green sooo....😆
Someone make a DOOM wad where all monsters that have projectiles fart them out.
1. Accept your mortality.
2. Casually approach Doomguy.
3. Pause, with anticipation.
4.
5.
6.
7.
8.
9. *ATTACK!*
@@clonefighter1996 yes
3. Go grab a beer, because you're a human and both the guy and the slayer have no problems with people.
@@wowalamoiz9489 doom guy and the slayer are the same person
@@ttty2242 They are from two different canons. Doom guy is a disgraced space marine from the original Doom series. He's a good guy but otherwise a normal but determined person.
Doom slayer is from the new series, and he's very much not ordinary in any way.
6:50
Doomguy: “Ah. You ate Chipotle too, huh?”
Best kind of videos, I can't get over how well produced they are. No fluff, no idiotic intros, no bullshiting around, straight to the point and facts supported by code itself - WONDERFUL!!
I enjoy how your code's syntax highlighting matches so well with Doom's color palette.
Decino: *uploads*
Me: *clicks faster than a pinky running at incredibly high speeds*
Faster than a Nightmare Fast Monsters Pinky
T U R B O P I N K Y
@@KeksimusMaximus i was gonna say hihg but i couldnt remember if it was high or hihg
is this what it feels like to learn something yet nothing at the same time?
edit: wtf 1.1k likes?????
me watching every educational video
Only if you have a bad attitude
@@RolloTonéBrownTown pretty sure that attitude has nothing to do with it
If anything it depends on your interest in the topic
@@rompevuevitos222 interest is important, but coding experience helps a lot.
i can't even imagine, how someone new to the topic could follow. this is basically video assisted C-code
hypes me up for going through the source, though
@@BrauschN When you're intersted in something, you can put as much time into it without getting as worn out/bored as someone who doesn't really "dig it"
Wich considering that indeed is REALLY hard to get into coding, it's really important
How to kill Doomguy:
1. Notice Doomguy
2. Casually approach Doomguy
3. Atacc Doomguy
4. Die from Doomguy
5. Profit for Doomguy
5.profit
*5. If on nightmare, respawn and attempt Atacc Doomguy again.
*6. Repeat.
@@ej22_gc86 lmao
9. Constantly say Atlas it's what you meant to say attack.
This guy explains Doom and coding at the same time, and it isn't boring. I love this guy
Demon:"Dark lord we have come up with 2 strategy's for dealing with the doom guy. strategy 1 overwhelm him with a highly coordinated tactical assault comprised of our most elite demons. strategy 2 run up to him screaming like madmen and fire wildly. which do you choose?"
Dark lord:"....."
Dark Lord:" ehhhhhh.............
*the second one* "
well, your not wrong
fire from your ass if you were preoccupied previously with another target
Option 1 is just nuts3 wad lol
Thumbnail is absolutely hilarious.
Civvie: alright we're going to get into some rick and morty territory
Cringe yet funny
@Just David to be fair Rick and Morty is inherently cringe
@Just David rick and morty is awful and I can cringe at it just like you're allowed to like it
@@RolloTonéBrownTown hater
It's funny cus it's true. If you know how to logic this should be easy stuff, else it's just random words and letters...
See what I did there ; )
I love how you use the "Gently approach" meme.
6:50 "so how did you die?"
"Baron fart"
LMAO
Incredibly densely packed video, a ton of work must have gone into this. Oh, and nice two see a couple of Anagnorisis appearances :-)
But of course, that map's a masterpiece.
Correct
Fan fact: Anagnorisis means recognition in Greek. Now let's see if this has anything to do with the map
@@toretronio9030 kool!
Ah, a man of culture
Next time anyone says "Doom is really 2D" I'm going to show them 9:49.
correct
the maps are 3D
the enemies are 2D sprites
@@thissitesucks905 Do you really believe you said something useful?
Sure doom has 3d coordinates, but nothing in the game is an actual 3d model. If that were the case, levels would be nowhere near as editable as they are.
@@noop9k just wanted to say it
@@illuminatidad yeah the map geometry is super simple collections of planed sprites it’s not full 3d modeling or anything, that’s why the objects and layouts are a bit limited
That is one swaggy Baron walk. Didn’t even know their backwards legs could do that
It would be nice to see some videos about features introduced in Doom 64, such as rooms above rooms not interfering with each other.
I think doom 64 had vector environments
Man I'd wish this video existed 20 years ago, I had to understand most of this stuff the hard way when there wasn't that much documentation on the game, yet this still revealed stuff I wasn't aware of like Barons not turning around. Great video!
I don't know if you mentioned it anywhere before so sorry if you did... But, are you a programmer by a chance?
Because if not, then I'm kinda curious what helped you understand C code this well.
I am.
@ElJoJos Xdxdxd I don't think I'm alone in saying that modding id games is why I learned a lot of things, including C.
@ElJoJos Xdxdxd i feel like most ppl watching videos this niche would fall into this category :p
@@RolloTonéBrownTown well I'm not a programmer but I do like to understand how things work
@@decino U are just a Zcsripter, *_Not a big Suprise_*
Also, I have Decorate Knowledge and even at Doom builder.
That thumbnail is cursed.
terrytrollface
blursed
Decino: The revenant will hit you if you get too close.
Me: HE HOO the boney boy go B O N K
yes
The next time someone says "game coding can't be that hard" I'm gonna be like "cool, here's a vid dissecting the code of a 27 year old game. Lemme know when it makes sense to you."
Yes. And if this was what 1990s code looked like, the 2020 stuff would be a lot more complicated!
This code is elegant in its simplicity. Having modded Quake 2 in the late 90s and then a bot to work with it, reverse engineering id's dense clean code was a breeze, I had zero prior experience with C++ and was able to get in there and figure out everything from the simple cluster nade mod to the server side and client side flows in days, with only a c++ syntax reference
First I thought that I would say that the code seen in this video is actually pretty elegant and easy to understand - for a programmer. Then it dawned upon me that anyone who already had experience in programming wouldn't make that statement anyway, so yeah :)
This is what makes Doom a masterpiece, and what kids, idiots and journalists don’t see behind its apparent simplicity.
Many later bad shooters had crap AI, because their creators wasted all their time on graphics.
@@hannahgreb1482 it's more or less the same, you forget a bracket or semicolon somewhere and reality collapses in on itself.
This is awesome! As a IT engineer, anyone out there looking to get into software dev should subscribe to this guys channel. Excellent analysis of the code and even explained how some of the bugs/in game hacks work. Great job!
As a janitorial engineer, I agree.
Makes me happy to see that list getting longer every video. Keep up the great content.
Normal people: Revenant
Me, an intellectual: Slap Daddy
That's a good one
insane papyrus
Me, a superior human: *DOOT SKELETON*
@@brucehc4975 boner
Lanky boi
my god finally, been looking through my feed to find good video to watch while eat my lunch.
Your video editing skills are underrated. So clear, no unnecessary flowers, great visual examples. I enjoy this series as Doom was a fav of mine as a kid.
Build engine AI is even more primitive. No cones of vision, no hearing (and no ambush flags), no group aggro
Bubblegum engine.
that is insane
Primitive, maybe, but you can't help but accept that a bunch of games did interactive justice with it, especially Blood.
Still the best videos. No bad timewasting jokes, great editing, and straightforward explanations of Doom's fascinating programming. Eagerly awaiting the completion of your Sunlust playthrough. Great thumbnails too.
Sorry, I don't have much to add here, but just feel compelled to thank you for the big effort this must have taken! Very interesting and insightful!
So much knowledge in one video, I'll need to rewatch it some more times to truly absorb it
This is maybe one of my all-time favorite videos ever. As just a hobby game programmer, it is so inspiring. I really wish there were more videos like this, explaining source code in such a rapid fashion.
Best video ever.
decino, I have to say I really love the detail you go into with DOOM's source code. This series is criminally underrated. Keep doing it!!
What? The chaingunner actually has more than one line of code other than telling it to shoot gun until player in view is dead?
Edit - 9:34 I remember learning from civvie that the red symbol on the side of that door means there's demons inside. I'm learning so much I'm going to upgrade from tiny spider to Rick and Morty Mastermind spider in no time.
i'm glad you specify "no not oney" in every video now because it genuinely does catch me off guard every time i hear the name and i was wondering about it but i didn't want to ask cause thats weird.
"no not oney"?
WTF man, I was literally thinking the other day: "Wouldn't it be cool if decino made a video about Doom's AI?" 😀
Great video, very thorough, I guess it took you a lot of time...
Doom guy: oh you're approaching me instead of running away?
Baron of hell: how else am I gonna rip you apart?
Doomguy:oh ho then come as close as you like
@@somerandompersonontheinter2004 ZA DOUBLE BARRUDO!!
3:53 - when you play Revenants anim at this speed, it looks like he's aggressively finger-snapping at you :)
I like how you give detailed specifications by poring through the code. It's easy to forget it's just a computer procedure when you actually play it, but you really give a coders level understanding of everything. It's amazing that you can just look at the code and say "ahhh, I understand all the implications of all of this". If you had written the code and were proudly explaining how the code you created worked that would be one thing, but you're analyzing open source code made by someone else.
Fascinating stuff, decino. Love all of these analytics videos. Thanks!
I like how his videos are quite serious but the thumbnail is made to look funny and joke about
0:24 y’all mind if I praise the lord
The most impressive thing is how well written the code is... It's a joy to any programmers' eyes
This vid in a nutshell:
1- Casually approach doomguy
2-Slap him
3- Repeat
4-Hope you don't die
The thumbnail: CASUALLY APPROACH CHILD
Now I finally understand why some monsters won't walk down some stairs. And also why it's possible to keep shooting at an idle monster until it dies, without it ever waking up and attacking the player. Thank you so much for all those explanations.
Another amazing video - such a stack of special cases! The bit about enemies not waking up on their second idle frame is something I hadn't realized
0:26 The Revenant looks like he's slappin someone's booty really energetically with both hands, I love it
Imagine if modern gaming had enemy AI this elaborate. DOOM was and still is ahead of it's time.
I have played the old doom games exactly once, but just listening how the logic behind the games works is fascinating! =)
Amazing how much programming goes into just making the enemies do something like decide whether to remain idle. Makes you appreciate designers more, instead of wanting to complain about glitches 😄 Also realize just how ahead of the curve id was
Loved the effort put into your thumbnails
I was surprised the sound propagation was so physicality correct going through sectors and being blocked by closed doors... Thank you for another great insight. Spent many tens of hours staring into Carmack's code yet never figured this out
Most enemies: Walks towards the Doomguy
Pinky Demons: Zig-zags in the whole place
Step one: enemy approachs doomguy
Step two: enemy attacks doomguy
Step three: Enemy becomes an introvert and runs away
The work for understanding the AI working, just deserve the blue thumb. Thank you for the work, the search, and the time you take to make us understand
9:24 ah Barney the archvile, he’s the most helpful demon in the entire franchise, able to allow you to skip level 27 in doom 2
barney calhoun the archvile security guard
6:55 why did i read that line of code as, "MOTHERFUCKER JUST ATTACKED."
Knowing id Software, could be the case
Another interesting episode about Doom mechanics!
Would love to see one about splash damage, too.
Imp: I have a plan to defeat doomguy
1# spot doomguy
2# approach doomguy
3# attach doomguy
4# celebrate
Protip: To defeat Doomguy, shoot him until he dies
Oh you meant attack
I really like how simple the scripting the Doom A.I. is;
Its crazy to see how simple the coding is, but how complex the construction of all the functions combined works
Man, those recent Doom ports are all sorts of weird. Really great video man. Keep it up.
Also, 9:49 haha. It's funny to see that from the side. It's like 'Flappy Cacodemon'.
This sounds like how my youngest Brothers brain works. I'll have to keep an eye out for his wake up sound, and his raise state animation.
Doom irl
Doomguy: Why are you running? Why are you running?
Enemy: (goes slow)
Did anyone notice that decino changed his circle, instead with a orange background he putted gray.
I really liked that yellow!
why did I read that as decino changed his dick. Hmm. I seem to have issues.
I thought I was just imagining it
Gathering The Easter Eggs
1:53 Decino, you never cease to amaze with details I never knew about a game that I've played for as long as it existed. Kudos! :D
0:32 That Revenant is GROOVIN'!
While cyber demon walks towards doomguy while doomguy just stands there
*M E N A C I N G L Y*
Doom guy: randomly punches air demons: DID I JUST HEAR SOMETHING
What really blew me away is that Carmack opted to use bitwise operations whenever possible. Take the bit at 12:04 for example: the enemy's height is quartered using a bit shift two places to the right, and then it gets shifted back 2 places when resurrected. This is especially important here since subtractions and multiplications are fairly expensive operations computation-wise, while bitwise operations are about as cheap as you can get.
It's pretty insane to what lengths he went to optimize the game, and how inventive he was at it.
So that's why some of my monsters fart out projectiles. I also had an A_FaceTarget oversight!
The xdeath state, where enemies are gibbed, is not to be confused with the Exdeath state, where THE LAWS OF THE UNIVERSE MEAN NOTHING
Now THERE'S a fight I'd pay to see.
Yo I appreciate this comment