Blueprint vs C++ Performance

Поделиться
HTML-код
  • Опубликовано: 19 дек 2024

Комментарии • 369

  • @Georgesbarsukov
    @Georgesbarsukov 4 года назад +61

    I love it, a clean video showing what I wanted to see. Thank you.

  • @gail_blue
    @gail_blue 8 месяцев назад +6

    So if anyone is still watching this, one problem with this benchmark is that forloops in Blueprints are Blueprint macros, which make around 6ish function calls. Meaning, for a simple one-call function, running it through a BP forloop will slow it down by a factor of 7ish.
    The take away being that Blueprints are terrible at forloops, but not so bad at everything else.
    You can double-click any BP forloop to verify.

  • @mantronicsenterprises
    @mantronicsenterprises 7 лет назад +114

    This was a simple way to present the difference of the 3 options for loops, thank you!

  • @NinponixTutorials
    @NinponixTutorials 5 лет назад +255

    Glad I learned C++ programming much earlier.

    • @malikvalley
      @malikvalley 5 лет назад +24

      Glad I learning C# and now can learn C++ easily

    • @ryvikun4325
      @ryvikun4325 4 года назад +3

      Ik this is so late but, i have learned c++
      So, is that knowledge can be implemented in Unreal engine?

    • @xX-fd2qj
      @xX-fd2qj 4 года назад +24

      @@ryvikun4325 not by itself. You have to learn Unreal's api.
      If you haven't used UE4 before I'd recommend going in with a hybrid approach. Create things utilizing blueprint and then replicate your efforts in C++. I've found it's easier to learn the general API in blueprints but C++ will get you used to UE4's data model and naming conventions.

    • @ryvikun4325
      @ryvikun4325 4 года назад +3

      @@xX-fd2qj thank you, this information is really usefull

    • @Linkario86
      @Linkario86 4 года назад +3

      @@malikvalley Is it really easier when you learned C#? I want to learn UE but the C++ part is the biggest bummer for me. All I know about C++ is a little controller with Arduino Uno.

  • @_duttes
    @_duttes 5 лет назад +229

    When people who use bp get triggered

    • @KRX01
      @KRX01 4 года назад +9

      i think nobody triggered.Im glad seee this , bc i use just BP's but i want to know how to write codes...thats all

    • @w47-p1e
      @w47-p1e 4 года назад +1

      @Logic_Encrypted dont get triggered so much

    • @brannonharris4642
      @brannonharris4642 3 года назад +1

      When people who refuse to use BP get triggered

    • @Ynox54321
      @Ynox54321 3 года назад +6

      Sounds more like people who use blueprint trigger you for some reason?

    • @SaulBadman
      @SaulBadman 3 года назад

      @@brannonharris4642 BP is for noobs

  • @MatheusLB2009
    @MatheusLB2009 6 лет назад +95

    I might be too late here but anyway: i watched Epic's GDC talk on making Fortnite go from 30fps to 60fps on consoles. One critical point was to turn some blueprints into C++ code. Of course some bp might take 1ms so not much benefit but many could take 9ms and the C++ would always be faster

    • @necrago
      @necrago 3 года назад +6

      If they did that, they might be able to reach 90fps

    • @RosieSapphireMusic
      @RosieSapphireMusic 2 года назад +1

      @@necrago If you also consider optimizations you could make with C++ that you just can't do in blueprints, they could bring that number even higher. Granted, I doubt they'll put that level of effort into it. lol

    • @kurushimee
      @kurushimee 2 года назад +5

      Yeah, you can have non performance intensive code in blueprints but all heavy calculations should be done in C++

    • @jestificated
      @jestificated Год назад

      is it a simple conversion tool or do you need to know c++ like a pro?

    • @flotto7045
      @flotto7045 Год назад +2

      You need to know c++ like a slightly above average developer

  • @MrTerminalZ
    @MrTerminalZ 5 лет назад +6

    Did no one make it to 1:45 where he tests results of blueprint after nativization?

    • @nitroneonicman
      @nitroneonicman 5 лет назад +6

      The salty Blueprint users were too mad to make it that far.

    • @b00mere
      @b00mere 5 лет назад

      Thanks for this comment, was about to leave, now i'll go to 1:45 !

    • @ЭмреДалгыч
      @ЭмреДалгыч 4 года назад

      it's still terrible in comparaison

  • @randomd00d19
    @randomd00d19 2 года назад +18

    This vid is the real answer on which to use, and my conclusion is bp&c++.
    Do bp until you come across something expensive to process and code that part out.
    If you can't do that then try nativization while keeping vigilant of glitches.
    Thanks for the vid. It's exactly what I needed.

  • @alyo7774
    @alyo7774 3 года назад +45

    This is not the main problem of blueprints. The thing that annoys me greatly with them is a constant need to keep your graph pretty, or at least readable. You have to care about spatial image of code, and either end up with a messy network or deep rabit-holes subgraphs, which is annoying to read. Managing the text code is so much easier, and multiple functions only make it easier.

    • @commanderboo8879
      @commanderboo8879 2 года назад +6

      yeah as someone that got into learning Unreal Engine already knowing C++ as a way to build my skills, I find Blueprints more arcane and tedious to use at times tbh.

    • @spht9ng
      @spht9ng 2 года назад

      @@commanderboo8879 I hate looking at the mess of wires. Reminds me of why I hated Reason for making music back in the day.

    • @gamedev_byhobby8872
      @gamedev_byhobby8872 Год назад

      If you're not careful it can also happen with code but with no handy wires pointing and connecting scripts

    • @361Fhwtiyd
      @361Fhwtiyd Год назад +1

      @alyo7774
      @commanderboo8879
      I find it hilarious when people say BP is easier.
      Managing a code decently sized codebase only done in BP seems like a nightmare.
      10% of the effort of software goes into writing it.
      90% of it goes into integrating it with the rest of your codebase and maintaining it.
      If you type slow, BP may be faster for the %10.

    • @361Fhwtiyd
      @361Fhwtiyd Год назад +2

      @gamedev_byhobby8872
      The "handy wires" just show the order of execution. The simplest part of understanding the code.
      Navigating from function to function is easily done with IDEs for the past few decades.
      they also stop becoming so handy once you start producing something of substance.

  • @mahmoudmimi4022
    @mahmoudmimi4022 2 года назад +2

    What about if I use blueprint in my project and when finish it I will convert blueprint to c++ ...
    Are this give me more fast performance..

  • @SpeedfreakUK
    @SpeedfreakUK 3 года назад +24

    Follow the 80/20 rule. 80% of your game's time will be spend in 20% of its code, so that 20% is the only part that needs to be fast. Most stuff made in blueprint only fires once per frame, if that, so in real world scenarios blueprints will rarely have significant effects on performance.

    • @codyvandal2860
      @codyvandal2860 3 года назад +2

      especially nowadays right? I think it was worse when they originally came out?

    • @SpeedfreakUK
      @SpeedfreakUK 3 года назад +20

      @@codyvandal2860 I don't think it would have been much different. At the end of the day the most demanding stuff in the engine, the physics and raytraces and so on, are all done in hyper-optimised C++. As someone said in another comment, sometimes it does pay to move some blueprints to C++ as with Fortnite, but you do that AFTER you have determined a blueprint is slowing down your game rather than trying to optimise everything beforehand. Pre-optimisation usually just wastes time.

    • @starvosxant4348
      @starvosxant4348 3 года назад +6

      Paretto's principle.

    • @dzakikamal5323
      @dzakikamal5323 13 дней назад

      i'm not sure pal. my game feels more responsive especially on the hardware input part when using C++ compared to blueprint

  • @HangryBunniesFromMars
    @HangryBunniesFromMars 7 лет назад +4

    Thank you so much for this. I am tackling nativization right now!

    • @nitroneonicman
      @nitroneonicman 6 лет назад

      It's so worth it dude, the Inheritance properties of the engine which aren't exposed to Blueprints is really a game changer.

  • @joshpolman201
    @joshpolman201 5 лет назад +35

    I’m new to both c++ and blueprints, but I’m pretty sure if you’re running a 500-1000x loop in a single frame... well isn’t that INSANELY bad programming?
    And if you had no choice, wouldn’t you at least run it on a background thread?
    I understand your point, c++ is way more efficient... but if used intelligently, and there was zero lag noticed by the player, then any difference would be negligible, and there wouldn’t be any reason to avoid blueprints.

    • @Navhkrin
      @Navhkrin 4 года назад +23

      Sure, you can use blueprints where you dont need the performance. But when you need it, use c++, regardless of whether player notices it or not. No point in wasting computation resources. Remember that some people may play your game in old laptops, the fact that you dont notice difference on your computer doesnt mean no one will.
      You cant just apply "use intelligently" to all scenerios. Imagine having a massive fire explosion ability in your game. That ability will need to apply damage to every enemy that was hit by it, it is possible that you have a horde game where this ability hits like 200 units. You cant just have these units die one by one while this damage loop is executing in blueprint. Idea here is to move computationally expensive logic, in this example being the for loop, to c++.
      Also, we cant just say "running 500x for loop in a single frame" is bad programming or not. It depends on the context. For stuff like accurate physics simulations, we run million-x for loops per frame. But yeah, whenever you need such heavy computation idea is to have it on another thread so that we dont get frame drops. (Nota that for accurate physics simulation we cant do this, we must calculate equations for every particle before we render the new frame so that the simulation is "accurate")

    • @joshpolman201
      @joshpolman201 4 года назад +7

      Navhkrin Fair points.

    • @TheMrTape
      @TheMrTape 4 года назад +1

      I'd expect the capability of max 500.000 loops per physics frame/tick running 100fps, depending on how much code is to be looped; it's only 50Mhz; given 1Ghz of one core, we should expect about 8 CPU cycles to do stuff with after the loop overhead (12ish cycles), which of course would be about minimum space to do something useful with. Computers are powerful and can easily achieve this, so we should expect and take advantage of it. The question is rather when would you ever need this; it could definitely be argued that in many cases it is bad programming, if it's not necessary; it does defeat the logic of gradually calculating states tick by tick. Lets come up with an example where a huge loop would be relevant (yet bad manner): I have a container system, a container can hold 10k items and has data stored in an array; upon you opening the container, I'm gonna loop through the array and parse every item so appropriate icons can be shown; each loop has a loop inside that parses 20 item attributes to display state icons along the individual icons; that's 200.000 loops each involving costly engine calls, so will cause a hiccup. Why is it bad manner? Unless all items are to be displayed at the same time, I shouldn't parse the irrelevant data (but would have to know what is irrelevant in advance, eg. by sorting and/or indexing it appropriately). If I still have to, I should batch the processing across several ticks (or threads when suitable), optimally sizing the batches real time according to to how much time has elapsed processing during the tick, before starting a new loop or set of loops, essentially taking advantage of all available processing power without delaying subsequent ticks or frames; even on poor hardware we'd end up with tens of thousands of loops going for each tick.

    • @armanx2
      @armanx2 4 года назад +3

      IF i recall well , blueprints were made for artist because they could not program, but here is the thing, if artist need visual programming because code is for them too hard to understand or they don't feel comfortable , i don't think that same artist is going to be capable of producing efficient algorithms... add on top of that the blueprint drawback of performance and you will get very bad results. I mean to me it's simple i'm dev not an artist and i shine when i need to write code but i'm not that good at artistic side of thing, artist they shine on artistic side of things but they are not devs, difference being is when a dev does also does artists job they do use standard tools artist are using like Photoshop for example, they are not going to use paint because it's easy to use....yes it may appear to be easy but it has very limited possibilities in comparison to Photoshop. So long story short using Blueprint for gamedev is like using Paint instead of Photoshop , will get things done ? well if you just need to crop an image yes it can , but you are limiting yourself very much.

    • @Magaelcrack
      @Magaelcrack 4 года назад

      Really depends the type of game, is it strategy? Is it a FPS? is it fast paced? Big maps? lots of systems?

  • @Porus3D
    @Porus3D Год назад

    Hi, any chance you'll make an updated 2023 video?

  • @Rockam
    @Rockam 7 лет назад +25

    Waw great video!! so revealing

  • @Custodi
    @Custodi 4 года назад +7

    I didnt got it, you just take a func to C++, and BP&C++ works as well as clear C++?

    • @Zulfar-bd9tc
      @Zulfar-bd9tc 4 года назад +21

      From what I gathered doing some google searches, so not entirely sure if this is correct but just my guess, BP is a scripting virtual machine, and using a VM will usually have a pretty decent chunk of overhead to deal with. Every time you see a node in BP, it has to bounce back to the VM to do the compilation.
      So, when you look at the BP version of the function, it has to loop through and go back through the VM multiple times, but then it also is looping a BP function which contains a loop, so it has to basically do N*N loops, bouncing through the virtual machine each loop. This is why it crashes once the loop reached 1000, because jumping back 1000*1000 times through the virtual machine is too much.
      Whereas if you look at the C++ version, it just has to bounce back to the VM once, and it will perform the entire C++ loop function in there using whatever the input number N is provided in that node.
      The reason BP&C++ version works almost as well as the C++ version is because it has only 1 BP loop into a C++ function, so rather than doing N*N loops through the virtual machine it only has to do N loops through the virtual machine. In short, when it reached 1000, it only had to loop through the virtual machine 1000 times, as opposed to using straight BP doing 1000*1000 loops through the virtual machine.

    • @ShoryYTP
      @ShoryYTP 4 года назад +8

      @@Zulfar-bd9tc that's actually more informative than everything else i've read about blueprints

  • @mr.raider744
    @mr.raider744 4 года назад +22

    learning both is the best choise....more easier and more faster and better....am i right? am i right or am i right ?

    • @starvosxant4348
      @starvosxant4348 3 года назад +5

      Yeah. Learn both, build your game First with BP (the core mechanics), and then rewrite to c++

    • @mr.raider744
      @mr.raider744 3 года назад +2

      @@_v_m_ hey hey hey... take it easy, if C++ is hella fuck hard you can start with C# in unity...unreal is not that simple and it needs alot of work,not recomended to start with specialy if your a small developer. C# is easier and you can learn some programming basics from it make some games then go to unreal, but if you want the hard way....go learn C++ as your first programming language that would be alot harder but way more effective.

    • @mr.raider744
      @mr.raider744 3 года назад

      @@_v_m_ BP Performance is not stable......i mean there's some game dev companies out there spend millions just to make their game engine for high performance so you should not miss this point...its very important,but BP is not that bad you can actually make a game using it but its not recommended spacially for multiplayer games.

    • @mr.raider744
      @mr.raider744 3 года назад

      @@_v_m_ True

    • @starvosxant4348
      @starvosxant4348 3 года назад +4

      @@mr.raider744 If you want to be a game developer, you need to stop with this "ah it's hard" no, just no. Change this from "it's hard" to "i can do if i want".
      Take 0.5/1 year to learn C++, stop putting unexisting barriers, it'll just slow you down. It is a process, and the results are worthy.

  • @GeneralNovais
    @GeneralNovais Год назад +1

    Way For Loop = 10000 in C++ before packing BP as native, results 4971ms and after is 52ms? packing BP affects standalone C++?

  • @diswazzi1683
    @diswazzi1683 3 года назад +3

    Why does the more complicated one have to be the fastest?

    • @sd19delta16
      @sd19delta16 3 года назад +1

      The work it takes to make something more complex to be better has to pay off somewhere.

  • @Nintendan95
    @Nintendan95 7 лет назад +7

    Very interesting! I was thinking about just how efficient C++ is compared to BP the other day.
    Thanks for testing this!
    ありがとうございました
    ところで曲の名前はなんですか?

    • @nitroneonicman
      @nitroneonicman 5 лет назад +3

      The song is Sandstorm by Darude

    • @cabreram.4734
      @cabreram.4734 5 лет назад

      What's the bender Kanji mean here?

    • @n.lwhitaker572
      @n.lwhitaker572 4 года назад

      @@cabreram.4734 Its the kanji for "song", which of course is Darude's Sandstorm

  • @harsh9558
    @harsh9558 3 года назад

    Thx a lot for this video!

  • @Rogueixpresents
    @Rogueixpresents 4 года назад +3

    thank you for this :D

  • @Rend3d
    @Rend3d 7 лет назад +4

    Thanks MAN for TEST!

  • @zeon3d755
    @zeon3d755 6 месяцев назад +1

    pls do the same on ue5.4?

  • @DirkTeucher
    @DirkTeucher 2 года назад +1

    There is a big difference in performance for BP in editor vs packaged. So is this a packaged test or in editor?

    • @marcelobarreto7204
      @marcelobarreto7204 4 месяца назад

      He packed with blueprint nativization, which is some kind of blueprint convertion to cpp that UE does during the compilation

  • @danielpam6310
    @danielpam6310 4 года назад +3

    Nice music! What genre is this!!!?? 💯❤️

    • @nitecro
      @nitecro 4 года назад +2

      trance

  • @Cpt.Tripps
    @Cpt.Tripps 7 лет назад +89

    Good video, just a couple of thoughts:
    I know it's a BP to C++ comparison and not BP vs nativized BP, but it would be overall more meaningful if the video showed more direct comparisons between the same number of loops with and without nativization vs C++ - we only get 500 loops in the first half and 10,000 loops in the second where both are represented ( C++ and either of BP methods). It would be far better to also have 1000/10000 with BP in the first half and 500/1000 overall in the second.
    (In order to get the non packaged version to manage more loops in BP, go to project settings and increase Maximum Loop Iteration Count. You should be able to run up to around 30,000 loops in your test).
    As a small nitpick, the BP function has to run a lot of Float-Integer conversions which does not apply to the C++ code (demonstrates that the latter is more efficient, whereas the topic is comparison of computation speed), a better comparison would be to have the results all in integers (but admittedly the difference wouldn't be all that much).
    If anyone is interested in some more comparisons, below are my (BP Only) results for the same setup as in this video, meant to compare the speed before and after nativization.
    I tested nativized and non nativized in Packaged and also added results for PIE and Standalone (Standalone and Packaged-non nativized yielded the same results, therefore I only included one of those). Btw, I assume the first half of the video runs in PIE, which is not the best way to conduct a comparison, due to additional overhead for BPs in editor.
    Loops (Executions) PIE | Standalone | Nativized]:
    A. 500 (125,250) PIE 395ms (*) | SA 45ms | Native 1ms
    B. 1000 (500,500) 1,593ms | 183ms | 3ms
    C. 10,000 (50,005,000) 157,236ms | 18,271ms | 297ms (*)
    D. 30,000 (450,015,000) 674,988 | 163,852 | 2,724ms
    E. 100,000 (705,082,704) N/A | N/A | 29,798ms
    (*) These two would be the values corresponding to the results in the video.
    Going by the above and the results from the video, C++ in this instance is roughly 200-300x faster than BP and 6-8x faster than nativized BP.

    • @jimothyus
      @jimothyus 7 лет назад +4

      dude that data is usefull as fk if you made a video you would get some views. thanks!

    • @Cpt.Tripps
      @Cpt.Tripps 7 лет назад +5

      I have compiled even more data here: www.reddit.com/r/unrealengine/comments/6qtxy3/test_blueprint_vs_c_performance_vs_nativized_bp/
      I made several additional test setups, and the less I rely on the loop itself being the main factor, the smaller the difference between C++ and nativized BP seems to get. My last test had the difference at about 30% (ratio of 1:1.3 (C++:BP/Nat), down from 1:8 when basically just running empty loops like in the video).
      I will probably try to put a somewhat more relevant game scenario to the test, e.g. thousands of actual actors in a scene ticking with some variable updates.

    • @jimothyus
      @jimothyus 7 лет назад

      +IndieDevRow wow thanks! i should probably visit the subreddit more often. appreciate it!

    • @jimothyus
      @jimothyus 7 лет назад +2

      +IndieDevRow check it out, that video is sick great work

    • @yoshmk13
      @yoshmk13 6 лет назад +1

      Indie Brothers I

  • @fish3010
    @fish3010 4 года назад +1

    Is this still the case? Or the gap in performance has decreased?

    • @argosbrave6415
      @argosbrave6415 4 года назад

      Nativized blueprints are doing better now, but the nature of this test will always lend itself to c++ blowing away BP.
      BP is slow when going from node to node. Once it's executing the code for a given node, it's pretty much the same as c++ performance wise.
      Since this test is just one big ass loop running over & over, w/ hardly any execution in any given, it'll highlight that issue.
      BPs are fine to use for a shipping game, just for the right things. This use case, heavy math, is & will always be terrible for them. But real games, Fortnite for instance, use them for lots of other stuff.

    • @fish3010
      @fish3010 4 года назад

      @@argosbrave6415 Thanks for the clarification! I wasn't sure if it will affect a game in any significant way. I guess it can have some inpact on lower end systems being more visible than on mid to high end even tho it's not something like matlab intensive

    • @starvosxant4348
      @starvosxant4348 3 года назад

      Use both of them. Blueprints are nothing more than a giant chunk of C++ code behind the scene, so of course run a single line of C++ code is better than running a giant code of c++ that will perform the same function as the single line.

  • @fleurbird
    @fleurbird 3 года назад

    Is this your alt account?
    J.k.
    Nice example

  • @anonymoususer734
    @anonymoususer734 3 года назад +2

    Glad that I programme in C++

  • @Pontos420
    @Pontos420 3 года назад +1

    Is there any difference with UE5 ?
    (I guess it is the same ?)

  • @MaxwellsWitch
    @MaxwellsWitch 7 лет назад +3

    Thanks! I really wanted to know the answer to this question.

  • @sanketvaria9734
    @sanketvaria9734 4 года назад +16

    to be honest, Why would someone want to loop something a million times in any real case scenario. It's like having a rocket launcher at home but you don't use it to kill mosquitoes. Rocket launcher is good for showcasing its power same way C++ is good for showcasing its speed over blueprint. Simple games would never need C++.

    • @tux_the_astronaut
      @tux_the_astronaut 4 года назад +1

      Yeah unless your loading /Saving lots of actors you it’s not really worth it

    • @PrimarchRoboleonFrenchyman
      @PrimarchRoboleonFrenchyman 3 года назад +2

      Nobody use the same loop a million time, but how many things are updating ? Not a million but still.

    • @nyx1284
      @nyx1284 3 года назад +1

      you will need to do it in a big system, maybe something if your doing procedural generation

    • @sanketvaria9734
      @sanketvaria9734 3 года назад

      @@nyx1284 true.

    • @drummerman883
      @drummerman883 3 года назад

      I have a BFS algo that does more. Depends on the game.

  • @Jdfskitz
    @Jdfskitz 3 месяца назад

    Can you remove that truncate on the blueprints only so I can see a true comparison please. there is no need for a double conversion back to back with a truncate that causes a huge performance hit.

    • @Jdfskitz
      @Jdfskitz 3 месяца назад

      Update I tested without the truncate and Modified the for loop macro as well to try and optimize then while doing further research, it narrows down that blueprints run through a virtual machine in the editor that is single threaded opposed to multithreaded which translates to machine code.
      I have discovered blueprints are good for EVERYTHING, "Except" Iterations.

  • @Paulo84100
    @Paulo84100 3 года назад +1

    But is there any moment when you use a bp as bad optimized as this one ?

    • @starvosxant4348
      @starvosxant4348 3 года назад

      No. Never actually, this is just to demonstrate

  • @wavelogic8471
    @wavelogic8471 3 года назад +8

    Once fully compiled, build, and package for release, you will get very different results.

    • @peterino2
      @peterino2 2 года назад +3

      He shows that at the end of the video

  • @tatoforever
    @tatoforever 6 лет назад +18

    This kind of test is more relevant for games with lot of interactive entities such as open world games where you have to constantly check lot of things at runtime or custom systems that need to pass/check huge amount of data. In my opinion the best combination is C++ and BP as it gives your designers more creative control without blowing out performance. All BP is just a really bad idea, no wonder why lots of Unreal games are really slow even when they seems quite simple. This can be multi-threaded and your 100 000 objects will take probably 5-10 less time cycle but multithreading is advanced topic, specially in C++.

    • @CogniVision
      @CogniVision 6 лет назад +1

      Yeah it's why C++ & BP is a good option. Leave the heavylifting functions to C++ and simply make them callable in BP for more visual feedback to the code execution and for designers to see what's going on. The C++ & BP hardly added any overhead vs full BP.
      BP is just not made for heavy calculations or loop iterations. I think there's also a limit to how many loops your BP can do which you can change in settings, which is why he got an error on the 1000, went over the limit.

    • @kalex22029
      @kalex22029 5 лет назад +1

      @@CogniVision This. Make your core functionality in C++ and then extend off of it with BP classes that inherit them.

    • @jakedubs
      @jakedubs Год назад

      Blueprints are used by a lot of artists and script kiddies that don't know what they are doing. Half the reason why you get bad performance

  •  6 лет назад +8

    Not very representative for me: it's the worth case with "Array" !

  • @mohsenafshan7908
    @mohsenafshan7908 3 года назад +7

    this video is good for comparison but also for the people who are criticizing BP i have to say, if you are going to run a loop for 10000 times in the runtime of your game, you better think of something else to do with your life rather than programing!.

    • @overcommon7662
      @overcommon7662 2 года назад

      He’s just showing overall performance.
      This means if you have a HUGE project that was identical, with the only difference being the programming style c++ or c++ & BP would be much better to use.
      Using only BP for a large project isn’t a good way to go.

  • @MrPoliceW
    @MrPoliceW 3 года назад +8

    c++ is not only performance, it's give you easy maintain and design your large project.

  • @andrewherrera7735
    @andrewherrera7735 3 года назад +3

    Early optimization is the root of all evil= you could optimize the hell out of everything, when it turns out that most of it was unnecessary cause it wasn't a bottleneck.

  • @TOBI-SAN
    @TOBI-SAN 7 лет назад +1

    icore 3 can run the game using this engine? i was thinking to use this than unity

    • @jahangirakbar4524
      @jahangirakbar4524 7 лет назад

      Kian_ PW GAMES I only want to use this engine because of blueprints! otherwise unity 3D is the best

    • @TOBI-SAN
      @TOBI-SAN 7 лет назад

      unreal engine blueprint user or unity3d plygame user?

  • @daddadia5015
    @daddadia5015 4 года назад +8

    I want to learn C++ so badly, but it literally takes 15 minutes for the code to compile so then my character can move despite me having a computer that worths 700£. And if I make the code display a widget, it will up the compile time to 20 minutes! Looks like I will have to wait until I can buy a better computer :/

    • @ShoryYTP
      @ShoryYTP 4 года назад +3

      You can still learn C++ by itself! Either watch online courses or (much better imo) buy a book. The best book to start is "Programming: Principles and Practice Using C++ (Second Edition)" written by the creator himself, Bjarne Stroutrup. Try using just visual studio, without having it linked to an open Unreal project, and code some windows console applications. You can also use online compilers like OnlineGDB if your computer is too slow.
      DONT use your PC's slowness as a justification, just learn it!

    • @unrelentingpest
      @unrelentingpest 4 года назад +6

      Try buying an SSD, I've heard it's the most important factor in compilation time.

  • @Lukeallnight
    @Lukeallnight 5 лет назад

    can someone explain how this compares?? it just looks like C++ math expression. vs Foreach loop which does alot more than Math. so it's obvious that there is more performance requirements on it. his example of the blueprint is a foreach of a foreach. when the C++ just looks like an adding calculation. if i'm wrong please explain.

    • @kalex22029
      @kalex22029 5 лет назад +1

      the 2 for(int i = 1; i

  • @xdragon5502
    @xdragon5502 7 лет назад +7

    You do now you can convert blueprint to c++?

    • @jackboyd2464
      @jackboyd2464 7 лет назад +3

      Makes very little difference, he shows the packaged & nativized build at the end and blueprints still run like shit

    • @Cpt.Tripps
      @Cpt.Tripps 7 лет назад +23

      "Makes very little difference"? Not sure what would constitute a big difference in your book then. Considering that without nativization the result for 'BP only' at 500 loops (125 thousand executions) was 454ms, while with nativization in roughly the same time (397ms) it went through 10,000 loops (50 million executions), I'd say it's not a bad optimization of a scripting language.

    • @CesarMonteroOrozco
      @CesarMonteroOrozco 7 лет назад +1

      Only if it was made in assembler it could get better. Now, make a multimedia application in assembler, or UE4..mmm...It would be interesting however to compare Unity C# and Unreal C++ with a matching visual quality. First, Unity would have to be able to match it, but that is another story.

    • @xdragon5502
      @xdragon5502 7 лет назад +1

      Well if you do not convert bp to c++, the your game will be bigger in file size

    • @nitroneonicman
      @nitroneonicman 6 лет назад +3

      Converting BP to C++ shows exactly why Blueprints are so slow. The Blueprint header is massive.

  • @CompanionCube
    @CompanionCube 4 года назад +5

    Misleading video. Blueprints are FINE to use as long as you stick to the best practices
    provided by Epic.
    This video shows the bad scenarios first and only shows the interesting scenario that actually matters at the very end.
    By 1:45 most viewers have already come to a wrong conclusion and have stopped watching.

  • @k-tech2937
    @k-tech2937 3 года назад +8

    bp are sometimes laughably inperforment, i implemented custom networking where i was receiving vehicle data from MatLab for a simulation, i made a delegate which was broadcasting FVector TArray and FRotator TArray each 5 elements long. Initially i tried handling the arrays in bp, this cause soooo much stuttering. Just moving the array handling into c++ and broadcasting 5 vectors and 5 rotators completly removed all the stuttering -.-

  • @morderus0033
    @morderus0033 3 года назад

    The sad part is that people are getting the wrong point based off this video...

  • @D4KiRZ
    @D4KiRZ 8 месяцев назад

    bro please test in shipping build...

  • @Nudtanun
    @Nudtanun Месяц назад

    Great!

  • @Marth8880
    @Marth8880 6 лет назад +1

    Music track?

  • @majedhk5460
    @majedhk5460 6 лет назад

    can you give me blueprint for this to try it on my device?!

    • @nitroneonicman
      @nitroneonicman 6 лет назад

      It's pretty easy to set up yourself.

    • @ugochanneltv5600
      @ugochanneltv5600 4 года назад

      @@kwakyekrieger2903 that's why i switch to unity. In the unreal community the 90% is lazy people who use only blueprints and I can't learn c++.

    • @zinetx
      @zinetx 4 года назад

      @@ugochanneltv5600 Minecraft kid, just go play with your toys or whatever.

  • @BohdanMart-h5x
    @BohdanMart-h5x 7 месяцев назад

    Damn. It's so sad that Nativization is no longer a thing!

  • @nicolashernanhoyosrodrigue4696
    @nicolashernanhoyosrodrigue4696 5 лет назад +1

    THANKS A LOT!

  • @stepanshnder1850
    @stepanshnder1850 Год назад

    i can make BP + C++ in AI??

  • @crazyguy7585
    @crazyguy7585 2 года назад +1

    my Simple Thoughts C++ is Best who know C++ Programming Blueprint is Best Who know Blueprints but if u know both then u don't need to see this video just do ur work.

  • @Fr0zka_
    @Fr0zka_ 3 года назад +4

    Even though blueprint is slower to execute than c++, this video was uploaded 4years ago, I'm pretty sure blueprint have been optimized since then (not at the point of c++ I think but it's better than nothing)

    • @Gordoxgrey
      @Gordoxgrey 3 года назад +5

      I just did this test with the exact code they've used and I've got 2-3ms with compiled blueprint nativized code

    • @Zondac
      @Zondac 3 года назад

      @@Gordoxgrey wait really? I gotta test this

    • @viruspanin
      @viruspanin 3 года назад +4

      Also, this video shows performance in editor. According to Epic (watch the Unreal Fest 2019 talk, In-depth blueprints), yes, blueprints are slower than C++, but they are horribly slower only in editor. In cooked/packaged shipping build, they are still slower, but the difference is way way smaller.

    • @Nebulon5000
      @Nebulon5000 Год назад

      This is neat info, is there a link I can see where they talked about it! No worries if you cant find it, thank you!!@@viruspanin

  • @PirateDion
    @PirateDion 3 года назад

    Is this still a thing 3+ years later? Learning C++ but I like the visual element of BP :(

    • @janlucsaneaux1915
      @janlucsaneaux1915 3 года назад

      Can confirm it's still a thing after converting my Blueprint interface to C++ in my Multiplayer Game. Also converted my Anim Notifys and they are definitely running a lot more consistently.
      This is all on a multiplayer game I'm working on so it probably won't make too much of a difference on single player. You can get away with making a whole game in singleplayer using only BP, but you really want to be as fast as possible for multiplayer.
      At the end of the day you should be aiming to use both in order to fully take advantage of UE4. Design/Prototype in BP, convert to C++, expose the functions/variables of your choosing to BP to make your life and designer's life easier.

    • @PirateDion
      @PirateDion 3 года назад

      ​@@janlucsaneaux1915 How is the conversion process? Do you have to effectively recode everything in C++ that was in blueprints or is it just a click and convert situation?
      The idea of reprogramming everything has me antsy and I don't even have much there to begin with.
      Though I am aiming at a single player experience for the first attempt anyways so there's that.
      Heard there is blueprint nativization that improves performance quite a bit as well but still new to effectively all of this.

    • @starvosxant4348
      @starvosxant4348 3 года назад

      @@PirateDion You should use both of them. I think there is a tool in Unreal marketplace called Magic Node. It is free. It'll help you

  • @joacotossello
    @joacotossello 2 года назад +2

    Nice video, Very bad logic...
    1) Why casting to float and then truncate?
    2) Why casting 2nd loop index to float?
    3) Why doing 500.500 loops instead of just 1000?
    You are doing Summation(K; K=1 to 1000) loops, EXTREMELY low performance for high X values.
    4) Why using Now() instead of GetGameTimeInSeconds()? Then divide it by 1000 OC...
    int result = 0;
    int loops = ;
    float time = GetGameTimeInSeconds();
    For(int x = 1; x

  • @dominusfons4455
    @dominusfons4455 4 года назад +6

    I started ue4 being optimistic that I didn't need to code to create my dream game because I was so intimidated by c++ and then I watched this video and then I got motivated to learned c++ from zero to data structures and algorithm expert in two and a half weeks. Now I can code faster than I can connect or search nodes for my blueprint lmao...

    • @salehodinie6615
      @salehodinie6615 4 года назад +1

      where did you learn to code c++ for unreal?

    • @dominusfons4455
      @dominusfons4455 4 года назад

      Saleh Odinie udemy I took the c++ zero to mastery 2020 course

    • @dominusfons4455
      @dominusfons4455 4 года назад

      Saleh Odinie after the course I just took the unreal engine c++ developer: learn c++ and make video games but you already need to know the basic of c++ and more before that course hence the first course I took^

    • @salehodinie6615
      @salehodinie6615 4 года назад

      @@dominusfons4455
      Do you feel confident now that you can do pretty much anything? or at least if you face a bug, are you confident enough to solve it on your own?

    • @dominusfons4455
      @dominusfons4455 4 года назад +1

      Saleh Odinie I wouldn’t say I can do pretty much everything since I need practice and exposure to problems I haven’t seen. I can say for sure that I can solve any problem since I already have the logic to do so but it will take me some time(inversely proportional to how many hours I have practiced the concept related to the problem) to come up with a solution since programming speed comes with plenty of practice. Like I remembered when I first did loops and array problems, it took me almost half a day to create a solution to them. Then after a week, I can solve them in less than 30 minutes.

  • @cwash08
    @cwash08 4 года назад +2

    holy crap the performance is huge. I know how to code anyway but seeing this makes me not even want to consider Blueprint at all. Of course if you don't know, Blueprint looks like a good starting point so depending on what you're making if you're less experienced don't let it discourage you

    • @maciejzjawin4477
      @maciejzjawin4477 4 года назад

      Several indie games are being made with blueprints like sword and magic and stuff and farm folks recently switched to blueprint and the performance is great mainly because this was three years ago

  • @xiaobai2977
    @xiaobai2977 6 лет назад +1

    sounds like a toca touring car song sped up

  • @rudnfehdgus
    @rudnfehdgus 4 года назад

    Thanks!!

  • @jaredjackson3333
    @jaredjackson3333 6 лет назад +2

    why is this so loud jesus,
    but insightful video thank you

  • @crazyphysicsdev2832
    @crazyphysicsdev2832 7 лет назад +1

    Nice vid! So when i write everything in BP and turn on bp nativization - is it the same as i write all in c++? or nearly the same?

  • @mijaelviricocheaparra7474
    @mijaelviricocheaparra7474 5 лет назад +4

    0:52 Ubisoft example.

    • @mateuszabramek7015
      @mateuszabramek7015 5 лет назад

      This have bright sides - Assassin's Creed Unity had so many bugs after premiere, so as apologies you got extra 4 titles for free. I remember falling over and over through floor during one mission and this was the only way...

  • @kloa4219
    @kloa4219 5 лет назад +1

    Test it out in mobile. Android and IOS alike

  • @MondayGone
    @MondayGone 5 лет назад +1

    Awesome

  • @comixamples524
    @comixamples524 5 лет назад +32

    Ah yes I see. I don't understand any of this shit. Maybe someday . . .

    • @theRPGmaster
      @theRPGmaster 5 лет назад

      The code takes less time = faster.

    • @tremfuufuuu2549
      @tremfuufuuu2549 4 года назад

      blueprint are a way to code more easy but this take a much time than c++, and c++ is literaly a code e more faster to code and to computer

  • @terraint3697
    @terraint3697 4 года назад

    But honestly who the fck would ever do two for loops like this. I've seen full blueprint games with multiple players, tons of ai, thousands of actors and it's still very performant. If you want or need that extra performance with c++ do it, but if you want your full game in blueprint most likely it's fine. My approach = prototype quickly in blueprint and convert to c++ later what you need to.

    • @JEsterCW
      @JEsterCW 4 года назад

      Tru bp nativization is also amazing option

  • @gurila11
    @gurila11 4 года назад +4

    C++ Win 🏆

  • @VulgoBe
    @VulgoBe 6 лет назад +1

    Valeu cara, quase comprei um curso de blueprints.
    thanks dude, I almost bought a blueprint course. You save me

  • @theshermantanker7043
    @theshermantanker7043 4 года назад

    This has got to be the only engine that uses an extremely low level language for scripting

  • @yasinozkan
    @yasinozkan 4 года назад

    I noticed you have a ForLoop 2 times, one in the function and one connected to that function, why ? I did a ForLoop with 500 connected to a linetrace in BP and I get 4ms (i7 k4970)

  • @ParkingLotStudioGames
    @ParkingLotStudioGames 3 года назад

    "C++ or Blueprints? How Blueprints Suck And Why You Should Use C++"

  • @Sirbozo
    @Sirbozo 5 месяцев назад

    cool

  • @tux_the_astronaut
    @tux_the_astronaut 4 года назад

    I still is BP but for complex stuff I use c++ And BP is left for simple stuff

  • @Montazeran8
    @Montazeran8 2 месяца назад

    🔥🔥🔥

  • @jordanserres-gonzalez9634
    @jordanserres-gonzalez9634 2 года назад

    what is this song has no right to be such a banger

  • @MrsHorridVR
    @MrsHorridVR 3 года назад +1

    always nativise your blueprints folks!

  • @Sqrt-i2z
    @Sqrt-i2z 3 года назад

    500 loop? Do you know that math behind when you put 500 in 500 loop? It will be 125250 loop. Its not 500 loop man.

  • @skuglious
    @skuglious 4 года назад

    I failed in c++ exam......fml

  • @hassentammous6400
    @hassentammous6400 6 лет назад

    thanks

  • @miguelfelix7175
    @miguelfelix7175 2 года назад +1

    Before, I was confused which programming language to use, now from what I see, I'm going to switch to C++, thanks 😊.

  • @jacktoobsee
    @jacktoobsee День назад

    pure functions, castings, bindings, delay nodes, event ticks in blueprints....dead

  • @seansopata5121
    @seansopata5121 4 года назад +12

    If you're running a loop on that many items, you've already failed. BP or c++, it doesn't matter.

    • @tux_the_astronaut
      @tux_the_astronaut 4 года назад

      Agreed if you’re doing something that large then it need to be broken up into chunks

    • @muhammadseyan8361
      @muhammadseyan8361 4 года назад +2

      the video is showing how slow BP actually are

    • @zinetx
      @zinetx 4 года назад

      @@muhammadseyan8361 you don't say!

    • @mugs4439
      @mugs4439 4 года назад +5

      @@zinetx He's clarifying because the original commenter seems to not realize that he's only running this loop test as an extreme to highlight performance differences..

    • @theshermantanker7043
      @theshermantanker7043 4 года назад

      ...you do realise this is a stress test done on purpose, do you?

  • @СчастливыйЧеловек-х9с

    Where 10000 to BP?

  • @butter_fly_games
    @butter_fly_games 2 года назад

    Try again in packaged game and not in editor, because editor performance is always bad...

  • @stdc_tri
    @stdc_tri 2 года назад +1

    C++ & BP is the way to go. Using C++ is so powerful and fast, blueprints add flexibility.

  • @anupamkumar4109
    @anupamkumar4109 4 года назад

    Music

  • @gsus7125original
    @gsus7125original 5 лет назад +3

    I'm going to have to stick to Unity, C++ is too hard. C# vastly easier and more convenient.

    • @SrAirflayer
      @SrAirflayer 5 лет назад +1

      Nope, you're wrong. C++ is a natural evolution of C. Maybe C is more comfortable for you but this dont make it better... And yes, I programmed with both of them

    • @jeanquerol8645
      @jeanquerol8645 4 года назад +9

      @@SrAirflayer I think he was talking about C#, not C

    • @yoman9446
      @yoman9446 4 года назад +2

      Blueprint > Unity C#

    • @ugochanneltv5600
      @ugochanneltv5600 4 года назад +2

      @@yoman9446 SAME LAZY GUY WHO DON'T WANT TO LEARN HOW TO CODE AHAHHAAHAHAH

    • @theshermantanker7043
      @theshermantanker7043 4 года назад

      @@SrAirflayer They're talking about C# which Unity uses for scripts. I can't really disagree either since this is the first I've seen C++ used for scripting

  • @BestMovieActors
    @BestMovieActors 7 лет назад

    Dr. Chaos

  • @langi9095
    @langi9095 6 лет назад +5

    I find blueprints a lot faster and easier

    • @MaxArtemyev
      @MaxArtemyev 6 лет назад +2

      What do u mean by "find"?

    • @tanan8116
      @tanan8116 6 лет назад

      Yeah right

    • @thechosenone729
      @thechosenone729 5 лет назад +3

      BP's are for designing and maybe you can use them to do a small game but for medium and big projects BP are disaster....

    • @iBot.
      @iBot. 5 лет назад

      Peter Quad How so?

    • @starvosxant4348
      @starvosxant4348 3 года назад

      @@MaxArtemyev Because in his country language, find and think have the same word (not the same meaning). So he may have tried to say "i think blueprints a lot faster and easier"

  • @FangyOify
    @FangyOify 7 лет назад +4

    Work is good, but I think thats useless for gamedevs cause of its not actual. I dont know examples, where use 10k loops. I believe - combination bp and c make best perfomance, but I don't believe that onlybp script so laggy. I think bp it is similar functions and nodes as c++ but it is comfortable for people who are not so good in programming "old style"

    • @hazerjm
      @hazerjm 6 лет назад +2

      Blueprints are worse than c++ and no, c++ is not “old style”

    • @starvosxant4348
      @starvosxant4348 3 года назад +1

      You can develop a whole triple a game with Blueprint only, but if you only to increase fps, use both of them.

  • @spectrablaze3760
    @spectrablaze3760 4 года назад

    In editor

  • @mes2009
    @mes2009 Месяц назад

    both better for Performance and test
    c++ take more time
    BP bye bye Performance

  • @anotherfool9278
    @anotherfool9278 6 лет назад +2

    interesting. it would be cooler if you showed a practical example and not one trying to crash the engine. Also visual coding is made for those who dont understand regular coding or for artists, riggers and animators. Just like some people can buy art online ready to be placed in the engine. In order for one to do everything, there has to be compromises and easier ways to think about things. I love blueprints and I have a coding background. As a visual learning, blueprints just make more sense.

    • @kalex22029
      @kalex22029 5 лет назад +1

      Considering the main way Epic got Fortnite from 30fps to 60fps on consoles was switching a lot of code from blueprint to C++, it has a significant impact in practical cases. It's good for some things, level scripting, etc and adding on functionality to your C++ classes but it should never replace C++ classes. Blueprints are a great stepping stone and everything you do in blueprint translates almost directly commands wise into UE4 C++. I feel like once someone is comfortable with BP, if they want to make their game as optimal as possible, turning everything into C++ is the natural progression, and once you're comfortable with BP, UE4 C++ is very easy to pick up.
      C++ code is just more expandable, cleaner, faster to execute, more efficient and, once the developer becomes proficient with it, faster to write. It has downsides in terms of compilation time, which leads to natural iteration time decreases, but a solid workflow is
      Blueprint prototype (Gives a visual aid to figuring out the core system) --> Remake in C++ --> Compile, test --> Make a blueprint class inheriting from the C++ class --> Expand on its functionality with BP to do menial tasks that aren't performance intensive

    • @MacMan2152
      @MacMan2152 5 лет назад

      Xander Kyron what tasks aren't performance intensive? I've became quite good with blueprints and I currently am switching to c++ and I can't find much information on what would be more efficient or faster to do with blueprints. I've figured out tick events and loops are always better to do with c++, are there anything else that should always be done specifically in c++ or blueprints?

    • @kalex22029
      @kalex22029 5 лет назад

      @@MacMan2152 You may have misunderstood me - I meant that it is more efficient to *write* it, as in man hours/dev time, in some cases. With good code, blueprint will never be as efficient as C++ performance wise, but if something is really basic like opening a door or looting a crate, it will take less man hours for one developer on the team to do it in blueprint than C++, which means it costs less, so it is efficient from a business perspective to do basic tasks with bp.

  • @magnus00125
    @magnus00125 3 года назад

    NANTE KORE WA?!

  • @LeoMKyll
    @LeoMKyll 3 года назад

    Confirmation bias

  • @petertremblay3725
    @petertremblay3725 7 лет назад +30

    Well if you were dreaming of making a game only with blueprints then you dream just shattered!

    • @diwang4572
      @diwang4572 7 лет назад +16

      Peter Tremblay but who would using for loop 100000 times in a game?

    • @petertremblay3725
      @petertremblay3725 7 лет назад +10

      I understand your point but for multiplayer and certain complex game mechanics blueprint is totally out of the question!

    • @ratbytegamesue4tutorials782
      @ratbytegamesue4tutorials782 6 лет назад +5

      thats wrong , bp only games are great also for MP games ... you can´t say it out of the box , it depending what kind of project are making. here one good example store.steampowered.com/app/571740/Golf_It/

    • @petertremblay3725
      @petertremblay3725 6 лет назад +4

      For little game like that yes but not for anything serious like a RPG or an online game.

    • @sam_music555
      @sam_music555 6 лет назад +5

      If you can use blueprint than c++ isn't impossible, the main difficult of coding is actually...the ability to solve problems, if you can do in BP why you wouldn't do either in c++? Ok c++ is a bit hard as Language but with some training you can do it