The Unreal Engine Game Framework: From int main() to BeginPlay

Поділитися
Вставка
  • Опубліковано 22 тра 2024
  • What happens when you start up your Unreal Engine game? This video is a guided tour of the Engine's initialization process: along the way, we'll glimpse the high-level structure of the Engine (modules, game instances, local players, and viewports) and we'll see how all the different parts of the Game Framework (game modes, game states, player controllers, and the like) fit together.
    00:00 - Introduction: The game loop
    01:13 - Unreal's scary initialization code
    02:35 - GuardedMain and FEngineLoop
    03:09 - PreInit: loading engine, project, and plugin modules (IModuleInterface, UObject)
    05:17 - Init: Creating and starting the Engine (UEngine / UGameEngine)
    07:34 - Engine initialization (UGameInstance, UGameViewportClient, ULocalPlayer)
    09:24 - LoadMap: Reloading the world from disk (UWorld, ULevel)
    11:18 - LoadMap: Bringing the world up for play (AGameModeBase, AGameStateBase, AGameSession)
    14:10 - LoadMap: Logging the player into the game (APlayerController, APlayerState, UPlayer / UNetConnection)
    15:54 - LoadMap: Restarting the player (APawn, APlayerStart, AController / AAIController)
    18:11 - LoadMap: Routing the BeginPlay event (AWorldSettings)
    18:43 - Animated callstack summary
    21:55 - Base game mode classes (AGameMode, AGameState)
    22:36 - Characters and Pawns (ACharacter, UCharacterMovementComponent)
    24:02 - Where to specify custom subclasses
    25:32 - Delegates and subsystems (UGameInstanceSubsystem, UWorldSubsystem)
    26:42 - Conclusion
    Patreon: / alexforsythe
    Twitter: / alexforsythe
    #UnrealEngine #UE4 #programming

КОМЕНТАРІ • 328

  • @CinematographyDatabase
    @CinematographyDatabase 3 роки тому +344

    This video must be protected at all costs!

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

      Yup!

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

      Bro... I've been following your project for a while now (years) and every time I find a nugget of Gold, you have always been here first. I would pay you money to get your learning links!

  • @Rubberglass
    @Rubberglass 3 роки тому +176

    My GOODNESS! Been using UE4 for 5 years and this might be the best video I've seen on the core of how the engine works. A+

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

      I'm just watching this for fun at this point. The attention to detail the quality. I've i think never seen such a good programming video ever. I'm programming now for about 10 years.

  • @ekimr90
    @ekimr90 6 місяців тому +12

    I absolutely love your method of explaining Unreal concepts. Short, concise, no "HEY IT'S YA BOI" nonsense that makes me immediately look for another video. Just straightforward and professional. It's a breath of fresh air.

  • @beanboy504
    @beanboy504 3 роки тому +364

    I really think Epic needs to promote/support/sponsor/hire you to do videos for them. Like Unity did with Brakeys. These are the most in-depth and clearest videos I have seen on UE4 ever. UE4 lacks a lot of good in depth tutorials and videos. Glad you are filling that gap!

    • @randomexplosion6527
      @randomexplosion6527 Рік тому +6

      y e s

    • @wafi5576
      @wafi5576 Рік тому +3

      yeah . we need more educational stuff like this

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

      Agree 😂

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

      He used to be an engineer @ Epic Games

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

      2 years later this is still true! Would love for him to do a UE5 series sponsored by Epic

  • @kumituubi
    @kumituubi 2 місяці тому +6

    This is the best Unreal programming related video ever made, and is still valid in the era of UE5.

  • @hasanjamal3574
    @hasanjamal3574 Рік тому +46

    Alex, I hope you return to making Unreal Engine videos like this someday. They truly have changed the trajectory of my career (Student currently). For some people, videos like these make the difference between being overwhelmed by the mountain of knowledge needed for game dev and finding your footing and gradually being able to scale that mountain with confidence. You gave me that and I am sincerely grateful. Thank you.

  • @jeggie
    @jeggie 7 місяців тому +4

    This is the masterpiece that all other Unreal videos should be judged against. Flawless. Thank you for creating this!

  • @greyly_
    @greyly_ 3 роки тому +65

    It's criminal how few views this video has so far. I want to come back in six months and see at least 10k. Epic should promote your videos.

    • @Kingu__
      @Kingu__ 3 роки тому +4

      And they did :)

    • @greyly_
      @greyly_ 3 роки тому +1

      And it hit 10k.

    • @Grenader1995
      @Grenader1995 3 роки тому

      now it does have 10k and its been only a month :)

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

      If you want views and subs on YT, give them cats, farts or some top ten crap. That's the nature of YT and society as a whole in general, unfortunately.

  • @KITATUS
    @KITATUS 3 роки тому +60

    Having spent the past 7-8 years in Unreal Engine 4 - I can say without a doubt, this is the best piece of educational content I have seen for the engine (Sorry Mathew, I still love you!). Keep up the great work!

    • @TrojanLube69
      @TrojanLube69 3 роки тому +5

      Mathew’s videos are good to get a grasp on blueprints. This guy has been working in unreal engine since early days of the commercial engine. So he knows, and he is a really good software engineer.

  • @tom.looman
    @tom.looman 3 роки тому +273

    This is fantastic! Super thorough and well visualized so all these dense concepts are easy to follow along with. A+ this demystifies a lot of the code flow that is difficult to figure out for newbies. (I'll add this video to my written gameplay framework guide, which isn't nearly as detailed as this)

    • @AlexForsythe
      @AlexForsythe  3 роки тому +30

      Thanks for the shout-out!

    • @Developer-tx9uf
      @Developer-tx9uf 2 роки тому +12

      I love to see a legend recognize another legend.

    • @CHADALAK1
      @CHADALAK1 2 роки тому +4

      When Tom comments a video, you know you done something right :P

  • @yashkhd1100
    @yashkhd1100 Рік тому +7

    This is one of the rarest video of UE. When dealing with huge source repo like UE you actually need this kind of video to understand overall picture of why things are the way it is. This definitely gives lot of confidence if you plan to update engine. Unfortunately the guy seems busy with other stuff as his channel seems inactive from about an year.

  • @TrojanLube69
    @TrojanLube69 3 роки тому +27

    This is a class that has to be presented to game engine developers when they get hired by epic.

  • @wesc6755
    @wesc6755 3 роки тому +5

    This is exactly the kind of video that's just not found anywhere else. It's straight to the point and no irrelevant tangents trying to cram in a C++ tutorial. Whenever I hear "For those that don't already know..." in a video, it's a cue to scrub ahead until I get to the actual *point* of the video and it drives me crazy. Thank you for being respectful of our time.

  • @grey3318
    @grey3318 Рік тому +15

    Alex, I've been watching a ton of your videos the past 6 months or so as I've been learning Unreal for my own projects, and I wanted to share that I just got my first professional job in game dev, in part due to the projects I've built in Unreal. So, thanks for all the help in that process. I've still got a long ways to go in learning, but getting my foot in the door here will allow me to genuinely make a career out of game dev! I'm super excited for the future.

  • @nakedsingularity
    @nakedsingularity 8 місяців тому +3

    This video is so underrated. Your channel should receive Epic MegaGrants.

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

    A bit sad that I only discovered this series when it has been long finished Desevers so much more love. Hands down the best high level unreal tutorials I have ever come across.

  • @harshamohite1289
    @harshamohite1289 3 роки тому +15

    I've been using UE4 for three years and this video cleared up so much, I can't believe I didn't find something like this sooner. Very thorough, and incredibly high-quality walkthrough of the game loop. Hats off to you!

  • @watcover3396
    @watcover3396 3 роки тому +5

    Hi from the Unreal Engine CIS community, thanks for your hard work, it very helpful!

  • @P4nd0
    @P4nd0 2 роки тому +4

    A month ago, I started creating a game only based on C++, no blueprints, and this goal led me to watch (for now) nearly 50 videos about UE4. But man, this video's the only one who needs to be watched before starting anything else. That's the entry point of the universe. The framework is really well explained and detailed, and it helped me to get a different approach about my game conception.
    I have stumbled on this tutorial almost by accident, but it's like discovering a tiny shiny diamond in a wild and inextricable maze.

  • @TrojanLube69
    @TrojanLube69 3 роки тому +16

    Way so underrated! This deserves more views

  • @MarkerInteractive
    @MarkerInteractive 3 роки тому +8

    This is pure gold. This SHOULD be promoted

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

    Top-tier video, thank you very much!
    Working with Unreal for about 8 years now and did not found anything new for myself, but it really helps to structurize the overall engine flow!
    I'd wish I saw it back then when I just started xD

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

    You are a major component of why the human species will progress

  • @johnrex7108
    @johnrex7108 2 місяці тому +1

    An absolutely excellent breakdown of Unreal. Well done, man. Can't tell you how much new people to Unreal benefit from these types of videos.

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

    The analogy about how ancient codebases start up and the big bang is a kind of a transcendent realisation, to me at least.
    Great stuff.

  • @reubs
    @reubs 3 роки тому +6

    You sir have put my videos to shame. Excellent work!

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

      Dont be so harsh on yourself. I am learning a lot from your videos as well. Both of you are fantastic

  • @Ranger75th
    @Ranger75th 3 роки тому +11

    This is by far the best overview of UE4 internals that has ever been done! I never would have found this if it hadn't shown up on Epics site. Thank You!

  • @markyoshikawa4278
    @markyoshikawa4278 3 роки тому +4

    It felt like I was hired by Epic and you were on boarding me... Thanks so much!

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

    This guy knows his shit. Mindblowingly thorough and accurate.

  • @marckleise6436
    @marckleise6436 3 роки тому +7

    This is probably the best video I've ever seen about the UE framework and I've looked at hundreds. Epic should use this as a primer for new users and include it in the docs.

  • @iPwnN00bsTC
    @iPwnN00bsTC 3 роки тому +1

    incredibly good visualizations! amazing work!

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

    I've been looking for this for several years, thank you

  • @thoeme
    @thoeme 3 роки тому +1

    Simply amazingly put together. Many thanks for that hard work!

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

    Hands down the MOST INFORMATIVE video on UE.

  • @danielorchard6404
    @danielorchard6404 3 роки тому +1

    Absolutely incredible video, amazingly well done!

  • @adamkareem
    @adamkareem 3 роки тому +1

    Incredible explanation. This is really fantastic work!

  • @b.laciak8175
    @b.laciak8175 2 роки тому +1

    Amazing, in-depth material with great presentation. Thank you!

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

    Outstanding quality, extremely helpful! Thanks a lot for this!

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

    This channel is a real hidden gem. It's great exposure for someone like me who just started studying software engineering.

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

    From a software engineer's point of view who recently started studying UE and game making, I'd say your videos are one of the best out there. I really think UE should hire people like you to create solid documentation and educational videos that touch these topics with the needed depth.

  • @PixelPulse168
    @PixelPulse168 9 місяців тому +1

    Your presentation skill is remarkable.

  • @alwayssadbuttruthful
    @alwayssadbuttruthful 7 місяців тому

    absolutely astounding quality. thank you

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

    that's really good description for the programming (engineering) in a nutshell : you just woke up 1 frame after the big bang and you first need to define yourself as something while there's not even a term "something" and a word "define".

  • @OGU44
    @OGU44 8 місяців тому +1

    Awesome work mate! Very comprehensive! Thank you!!

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

    Incredible video. It's unbelievable how useful it is.

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

    Thank you so much for providing such a high quality course!

  • @joshuamcmillan6390
    @joshuamcmillan6390 5 місяців тому +1

    I’ve needed this! I’ve been banging my head against a wall not understanding how the engine was designed, now it’s all making sense!

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

    I can't give this video enough thumbs-up! Well presented and compact.

  • @kjiggity300
    @kjiggity300 3 роки тому +1

    Thank you for this detailed rundown!

  • @janlucsaneaux1915
    @janlucsaneaux1915 3 роки тому +1

    Wow! This is absolutely amazing!

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

    This is the best video on Unreal Engine architecture available out there bar none.

  • @KN-ci4dm
    @KN-ci4dm 3 роки тому +2

    This is a MUST-WATCH.

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

    incredible work. incredible. just massive

  • @ericfear
    @ericfear 3 роки тому +4

    This is phenomenally well explained, the graphics and sequence of topics flowed in a way that made this enoyable to digest. Nice work!

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

    What an absolute treasure of a video... Thank you for making it!

  • @Dan-gt3ov
    @Dan-gt3ov Рік тому

    This is the best piece of UE content I've ever seen. Thank you.

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

    This was an amazing video! The visuals made it really pedagogical and thorough, helped me crack a difficult problem!

  • @bub1ick
    @bub1ick 3 роки тому +1

    Unbelievable work! So informative and detailed. I was so amazed to see such a good presentation with such flawless animations and simplicity.

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

    Fantastic video!
    Very well made!

  • @thoril.pegason
    @thoril.pegason Рік тому

    I've watched so many programming videos and this is by far one of the best.

  • @Krustachu
    @Krustachu 3 роки тому +1

    Sir, your videos are by far the most well made and well explained on youtube. Thank you for taking the time to make those.

  • @rolandbalogh889
    @rolandbalogh889 3 роки тому +1

    Hoooly, this is a very well put together video! Thank you! This should be featured in the official UE docs :)

  • @SherajusSalehin
    @SherajusSalehin 8 місяців тому +1

    Best video I've found on Unreal engine by a long shot. Hats off to you, brother.

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

    Criminally underrated channel for how incredible your explanation and video production is

  • @jakedubs
    @jakedubs 3 роки тому +1

    Not a single dislike on this video! So informative.

  • @tim_arterbury
    @tim_arterbury 3 роки тому +4

    This is so helpful! Thank you!! 👏🏻👏🏻👏🏻

  • @jonasmlgaard8884
    @jonasmlgaard8884 3 роки тому +3

    As always, amazing content Alex. Love how you use those animations to accompany the verbal message. Super informative and very inspiring to watch and listen to. I've been trying to wrap my head around how the engine boots up for quite a while and never fully managed to keep focus to understand how it ever reached BeginPlay. I will for sure be rewatching this video a few times, but damn good job at explaining it from start to end.

  • @CompanionCube
    @CompanionCube 3 роки тому +1

    From somebody who learned this on his own: This video is the best entry point if you want unreal from scratch!

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

    Wow this reduces anxiety. So soothing!

  • @Gulzt
    @Gulzt 8 місяців тому +1

    It's so beautifully presented and so detailed and accurate, it's easily one of the best video's on Unreal ever made.

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

    This is amazing. I'm absolutely blown away. This makes me feel like I know nothing about Unreal. Thanks for putting in the effort to making this.

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

    This has to be the single most useful Unreal Engine video on UA-cam. Nothing else I can say really, amazing work!

  • @user-fr3it7zo5s
    @user-fr3it7zo5s 9 місяців тому +1

    Perfect explanation for engine starter!

  • @the-nomad-show
    @the-nomad-show 7 днів тому

    This was great! Made me understand why things work as they do in UE, thank you!

  • @PuraTvOyun
    @PuraTvOyun 3 роки тому +1

    Amazing work. Thanks for your effort and congrats for such high quality content. 👏👏👏👏👏

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

    Best video ever on what happens under the hood, great work man.

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

    Amazing video! Thanks for all the efforts!

  • @anastasiaionicioiu1456
    @anastasiaionicioiu1456 3 роки тому

    Brilliant video! Thanks so much for doing such a detailed overview

  • @AxioMATlC
    @AxioMATlC 3 роки тому +1

    This is such a good explanation that from a laymen to an expert could get value from it.

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

    the pace is freaking high but the explanation itself is very useful. Thank you!

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

    Thanks for sharing this!! Incredible how this video shows the core of Unreal engine about the c++ framework. Applauses

  • @ayrtonolvera4222
    @ayrtonolvera4222 6 місяців тому

    Nice video! Thanks for all the effort to put this together

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

    I love this! Thank you very much for such a comprehensive detailed explanation!

  • @spencerwannop3401
    @spencerwannop3401 3 роки тому +1

    You are an amazing teacher/coder/designer

  • @disruptive_innovator
    @disruptive_innovator 8 місяців тому

    this is the info I've been seeking to orient myself before making the plunge into some unreal fun.
    top notch job!

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

    Stellar work here, and eminently useful. Bravo sir!

  • @alekelpragh
    @alekelpragh 3 роки тому +3

    Awesome work! This might be the most important video about the UnrealEngine I've ever seen so far. I always had an idea about what happened when, but to actually run down the command chain to see what object is available at what time is priceless knowledge. Thank you very much to present this complex topic in that easily comprehensible way!

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

    Why did I not find you all these years !!! Class Apart content

  • @amilani4
    @amilani4 7 місяців тому

    Gotta say this one of the (if not the) best programming breakdowns I've ever seen, really excellent work. A shame it seems you've stopped making videos, this is brilliant.

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

    man....you're videos are an absolute joy to watch! Brilliant. Really gives me a boost and makes me want to become a really competent developer and not fear seemingly complicated challenges, your visual representations are very effective. Thank You.

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

    Clear and precise explanation. One needs to know well to deliver that good. Great tutorial👍

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

    Absolutely amazing content. Great depth and visualization. I wanted to dive in and research UE4 myself but quickly discovered myself lost under the mass of code. Really looking forward for the next part :)

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

    Love these videos. They are super useful. Thanks!

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

    Amazing explanation. Hats off to you sir, Keep it up, would love to have more such videos from you.

  • @Elou44Prod
    @Elou44Prod 3 роки тому +4

    Absolutely STUNNING! Thank you so much. I wish there were more videos on advanced topics for the UE. You really deserve a MegaGrant (or should apply for it)

  • @centneriss
    @centneriss 3 роки тому +1

    Very crisp and concise explanation of the basics how UE4 works under the hood. Thank you so much! Subscribed.

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

    the best video about UE architecture, I saw.

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

    This video is not just good at explaining how Unreal Engine works but also how cpp programs in general do. Super helpful!

  • @alexbarcelo9592
    @alexbarcelo9592 3 роки тому +1

    Thank you so much for making this video, it is fantastically well done.

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

    Another essentials reference video to bookmark and re-watch later.
    Your videos are beginning to creepily occupy all my Unreal bookmarks.
    At this time my worry is that there are too little of them.
    Thanks again.