Behavior Trees with Behavior Designer

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

КОМЕНТАРІ • 117

  • @Ben-bg2lp
    @Ben-bg2lp 4 роки тому +195

    I'm a beginner and I was watching an official unity video to learn how to write behavior trees. Instead, I was taught to buy an 80$ asset. If I were to keep learning like this I would've been broke before I learned anything.

    • @landrhykopp9836
      @landrhykopp9836 4 роки тому +10

      Excatly !! i'm agree with you. I prefer to learn it and increase my skills.

    • @beri4138
      @beri4138 3 роки тому +10

      There are a lot of good AI books that show you how to write behavior trees.

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

      Unity has been really good about teaching me a ton of stuff. It broke my heart to find out this was just an ad.

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

      @@beri4138 do you have a list please ?

    • @PS-vj6jz
      @PS-vj6jz 2 роки тому

      @@beri4138 Could you give examples of books on AI

  • @GameDevNerd
    @GameDevNerd 2 роки тому +14

    I've been programming and doing game dev for at least 15 years and I do it as a full-time career. Behavior Designer is a great tool to have but it has some quirks and issues and the documentation is kind of vague and ambiguous and the examples aren't all that great. Those things leave a lot to be desired and can make it hard to figure out, but it's still worth having. If you're a professional you can rewrite some parts of it and customize it a bit to polish it up for a real product like we do with AStar Pathfinding Project (for example, it's full of temporary array and list allocations that generate garbage like crazy and we had to simply change it to use static ones that it clears and recycles). So don't expect it to be 100% perfect, but it is well worth the money and will save a ton of time vs rolling your own system: the visual behavior editor alone is worth the money.
    One thing that drove me nuts about Behavior Designer is that nowhere are variables and references properly explained. They have a video and an example project but when I looked into the project it didn't seem to even be _using_ the shared variable like the video made it sound and the code didn't even seem the same. And they didn't explain how the system uses SharedVariable types when you add one in the editor or put one in a task class. I'll explain what I realized by looking at the code ...
    When you go to the "Variables" tab in the editor and add a new shared variable it's generating a per-instance shared variable for that particular tree instance. It's important to realize that SharedVariable is just a wrapper class with an implicit conversion operator and a "Value" property that gets the actual value. So when you add one to the code in your tasks it does _not_ automatically "share" the value or do anything magical like the name implies. If you add a SharedInt to your tree in the editor and name it "Amount" and then you write a task with a SharedInt called "Amount" it's not the same: changing one will not affect the other. The next thing you'll probably try is clicking on the task's inspector tab and hit the arrow by its SharedInt and then select "Amount" from the tree's variable list. That doesn't work either. I'm not sure if that's intentional or if it's just broken. The only way to make it work as expected was to get a reference to the BehaviorTree object by using var tree = GetComponent() ... then you have to write Amount = (SharedInt) tree.GetValue("Amount"); ... this code would go in the task's OnAwake override. What this does is it _copies the reference_ for the tree's "Amount" variable you created in the editor and stores it in the task class's field called "Amount". So now they're referencing the _same_ object in memory and they're actually "shared": changing one changes the other. You have to do this in your tasks to make a shared variable reference work, and I can't find any way to do it in the editor alone. Luckily it's a simple piece of code, but the variables system isn't all that great, imo. Something strongly typed and more robust is definitely needed and I am surprised they didn't provide a generic GetValue version that returns the _actual_ type and not System.Object which has to be casted to the actual type.

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

    the fact that unity doesnt have this in-house and I have to buy something a 3rd party made really speaks volumes. this should be a core feature.

  • @MatheusLB2009
    @MatheusLB2009 4 роки тому +54

    This comes for free as blueprints in UE4 and it's about damn time Unity had it integrated as well

  • @iontwos
    @iontwos 6 років тому +26

    All these tool should be natively integrated into the engine

    • @TokyoDan0
      @TokyoDan0 6 років тому

      Yeah, as long as the engine is not free.

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

      @Гоша Ватюнга Unity natively supports Bolt.

    • @yuvu11hjg
      @yuvu11hjg 10 місяців тому

      ​@@sxnorthrop But not behaviour trees

  • @AndreaLeganza
    @AndreaLeganza 6 років тому +145

    This and other tools should be integrated into Unity instead to be in the store .

    • @TedThomasTT
      @TedThomasTT 6 років тому +16

      Andrea Leganza "I want everything for free"

    • @The28studio
      @The28studio 6 років тому +4

      I want everything to be there for me.
      Create your own behavior trees , its not hard.

    • @Twitch375
      @Twitch375 6 років тому +33

      There are 7 free behavior tree assets on the store. Whether they're quality or have support to speak of... you'll have to find out for yourself.
      A behavior tree with a graphical interface is not much to ask for especially considering they are so easy to make and how widely applicable they are. The whole point of an engine is to avoid solving the same problems over and over and over again. And this one surely has been reluctantly done by hundreds of people & teams because free solutions are lacking either support, documentation, specific features, etc, etc all of which Unity could provide for behavior trees. Oh and Unreal has had a free, robust BT for *years*.

    • @Octamed
      @Octamed 6 років тому +1

      The trouble is, noone really knows the 'best' way to do behaviour trees. I personally hate the left->right freeform layout most use for no good reason. There's 3 or so behaviour trees that do nice stacked vertical nodes, which I think are better in every way, yet aren't used much. If Unity include something then 3rd party people tend to not bother. BT's are very specific to a lot of different situations, so it's hard to make them generic enough for an engine to include.

    • @Twitch375
      @Twitch375 6 років тому +9

      No one knows the 'best' way to do anything, and saying so is just pedant. That's why A* Pathfinding Project exists along with Unity's own navmesh. Unity themselves are promoting BT's flexibility to be used in a lot of varying situations. That's the whole idea of a BT and the reason they dominate the industry. Yes each engine/developer might have it's own specs and idiosyncrasies but the basic idea behind select, sequence, repeat, event, fail/success, etc is generally the same. With enough available source I'd imagine you'd be able to change the BT from horizontal to vertical given enough determination. Just because we don't have the 'perfect' solution doesn't mean we do nothing. Especially if the most obvious solution is the most widely applicable one.

  • @shadesbelow
    @shadesbelow 6 років тому +14

    This asset is so good, I've used it many times. Highly recommended.

  • @messiasalt
    @messiasalt 6 років тому

    man, behavior tree is the best thing in unity
    i use this for, animations, scripts, dialogues, it's very helpeful

    • @jackblack7802
      @jackblack7802 6 років тому

      Do you know where are the behavior designer tutorials I can find?

    • @alexRevolver
      @alexRevolver 5 місяців тому

      @@jackblack7802 i see nowhere...

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

    I'm digging this lady's voice
    Lara Croft, is that you??

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

    Unity should buy out the asset and make it available to everyone :)

  • @reaktorleak89
    @reaktorleak89 6 років тому +3

    AI suddenly makes a lot more sense. This should help out for my fps project.

  • @BrainSlugs83
    @BrainSlugs83 5 років тому +12

    Link is bad. It just links to searching for "on_sale:yes".

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

    Yes.Behaviour designer bring things really simple

  • @Soulzjd2
    @Soulzjd2 6 років тому +6

    Was I the only one who's OCD was freaking out about the animation of the feet not always syncing with the movement speed? lol

  • @kaiserdrache7675
    @kaiserdrache7675 5 років тому

    This is quite amazing.
    Quite incredible that you can put together such a functional and robust tool.
    There's just too must back-end code for me to think about. I love your skills.

  • @kukuhbasuki2099
    @kukuhbasuki2099 6 років тому +4

    more video about behaviour designer pleaaassseeee...

  • @boroborable
    @boroborable 6 років тому +3

    I prefer coding because I know how it will work, how I can debug. I don't trust any tool that makes simple things complicated but I can use tools which makes complicate things simple.

    • @sergey_molchanovsky
      @sergey_molchanovsky 6 років тому +2

      I prefer coding too, but for AI it's really better to use behaviour trees and FSMs due to its modularity and ability to see how things work in the form of graph.

  • @KrullMaestaren
    @KrullMaestaren 6 років тому +1

    Great new feature :)

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

    URL in description points at an MP3 collection instead of behavior designer now

  • @MatejVancoCG
    @MatejVancoCG 6 років тому +1

    Easy, fast and clear. Beautiful voice anyway!

  • @michelveraliot
    @michelveraliot 6 років тому +1

    Most amazing thing made by unity !

    • @Twitch375
      @Twitch375 6 років тому +5

      Love the enthusiasm, but sorry bud. It's an 80 dollar asset and it is not made by Unity but an unaffiliated developer.

    • @michelveraliot
      @michelveraliot 6 років тому

      How, that's cool!
      i dont know this was made by a small developper like pro builder and shader graph, but i was thinking this was made by unity.
      So all new Assets/Codes are made by small developper and unity select somes of the best assets in the assets store for unity 2018 or its just the behavior trees and shaders graph ?
      thanks for the information.
      have a nice day and sorry for my bad english.

    • @manueltripero
      @manueltripero 6 років тому +1

      This is basically a demonstration of a paid asset (basically the best thing unity has over other engines, and the thing that makes them more money).

    • @sergey_molchanovsky
      @sergey_molchanovsky 6 років тому

      You mixed up two different assets. Shader Graph is Unity's own tool, and it works with new 2018 scriptable rendering pipeline. Shader Forge was made by a small developer much earlier, now it's available for free.

  • @UnityExpert
    @UnityExpert 6 років тому

    when i think about how unity improving graphics every year, i dont really know how rendring is going to be in few years later. i m working with unity since 2011 and i m really surprised with this technologie can d, AI, machine learning, great graphics, processing wow

  • @MRCapscreen
    @MRCapscreen 4 роки тому +5

    This should be marked as a advertisement. It is not integrated in Unity and costs money.

  • @Autobalanced
    @Autobalanced 6 років тому +6

    These video's should be clearly marked that they're not features to be integrated but are actually advertisements for items on the Asset Store.

  • @weneedmorepowertobecomestr4591
    @weneedmorepowertobecomestr4591 6 років тому

    Thank you leaders 😲🙈👋👏

  • @zerocentpictures
    @zerocentpictures 6 років тому +1

    Pretty cool.

    • @unity
      @unity  6 років тому

      Thanks! - Matt

  • @rafarodriguez4765
    @rafarodriguez4765 4 роки тому +1

    The link of click here to learn more it is only a link to Mega Game Music Collection MP3 asset, in asset store....?????......Where it was supposed to link?

  • @simonestarace5249
    @simonestarace5249 6 років тому

    This is very interesting

  • @JazoraKW
    @JazoraKW 6 років тому

    what an epic tut for real this is the best game engine for me .

  • @damienclassen2179
    @damienclassen2179 6 років тому +1

    How the hell do you even access the behaviour tree window though? Does this framework have an introductory tutorial that I'm missing?

  • @klerta
    @klerta 6 років тому

    nice work

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

    Can you do it BOLT?!?!

  • @deangreasley8168
    @deangreasley8168 4 роки тому

    Hi guys, this looks very interesting. I've not purchased your behavior just yet, I'm just needing some clarification if can be used with other assets.Are we able to use this for lets say a RTS game, where the units could be either soldiers or vehicles. The asset Im thinking of using it with is the RTS Start Kit on the unity asset store.

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

    Anyone know if this is still worth in 2021?

  • @sulemanmuneer1478
    @sulemanmuneer1478 5 років тому

    Can it be used through script? Can we do thorough script continuously changing targets and seeking objects for one node?

  • @last8exile
    @last8exile 6 років тому +1

    Why ai continue to flee from dragon, as it can't see dragon while flee?

    • @person8203
      @person8203 6 років тому +1

      it was giving a position to run to once in flee mode. I guess because it couldn't see the player either there's no trigger and it keeps on going.

    • @ellmatic
      @ellmatic 6 років тому

      I believe he would run away from the player, to the given position, go to idle and *then* start looking for the player again to repeat the whole process. I may be wrong though.

  • @containedhurricane
    @containedhurricane 6 років тому +1

    I heard many developers can create more than just a Behaviour Tree with NodeCanvas, is it true?

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

      With node canvas you can also create dialogue tree and of course behaviour tree. I have it in my asset but im planning to have this one too. I think because this one have some preset task

  • @ellmatic
    @ellmatic 4 роки тому

    2:35 What's the purpose of the 'Send Message' task here?

  • @wendymorrison2385
    @wendymorrison2385 6 років тому +4

    Hi just wanted to know is their other more in-depth tutorials instead of the very basic one that just doesn't animate a character on opsive because I noticed that you have an enemy controller script and I can't find anywhere what are the things you have to add to the enemy to make it work. What I am saying there is no tutorial that uses a normal character. They all use a capsule. And yes I have checked out the examples but I need tutorials, not examples. I have only seen tutorials about the behavior tree layout and not any tutorials that says what has to go on the AI itself which is very disappointing.

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

    Does this work for 2D as good as for 3D games?

  • @HouseCatTV
    @HouseCatTV 6 років тому

    So this is kind of like a state machine?

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

    What if dragon is at the flee point? the enemy will run towards dragon

  • @MM-wr2kj
    @MM-wr2kj 8 місяців тому

    does it works with playmaker ?

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

    where is the sense of that if i can use graphic coding anyway for free?

  • @jochenfong3056
    @jochenfong3056 5 місяців тому

    in2024,unity even dont have self behavior tree tool

  • @iceiceninja
    @iceiceninja 6 років тому

    Hey! I am curious if you guys at Unity can make a 2D chess game tutorial using C#? I was looking around because I got stuck while making my own, and all of the tutorials I found were low quality or used JavaScript. Thanks for reading!

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

    Why Behavior Trees are not part of Unity yet?!

  • @emiofficial_
    @emiofficial_ 6 років тому +6

    awesome

    • @unity
      @unity  6 років тому

      Thanks! - Matt

  • @TheReferrer72
    @TheReferrer72 6 років тому +3

    Looks like another asset Unity has to buy, to try and keep up with Unreal. The trinity of engines is hotting up, Unity will probably have to opensource it's engine to stay in pole position.

    • @TokyoDan0
      @TokyoDan0 6 років тому +1

      You wrote 'trinity'. Unity, Unreal...what is the third one?

    • @looking_arround
      @looking_arround 6 років тому +2

      The Man
      RPGMaker

    • @The28studio
      @The28studio 5 років тому +1

      You guys say that every year , yet in never happend !
      UE is not even close to unity popularity among indies , it's catching up but still far .

    • @leftyfourguns
      @leftyfourguns 5 років тому +2

      Assets like this behavior tree editor existing without Unity development is the reason why Unity is the best free engine on the market. UE4 does not have an asset market place nearly as robust and well implementedas Unity's

  • @krytec4546
    @krytec4546 6 років тому

    Can anybody how to make a 2D AI that will wander in a specific zone until the player comes into view

  • @paulkruger4156
    @paulkruger4156 9 місяців тому

    The behaviour designer is far too expensive for me!

  • @NihongoWakannai
    @NihongoWakannai 6 років тому +1

    I thought this might have been a feature with 2018.1, it's kind of weird that you are giving tutorials and advertisement for specific assets in the store, no?

  • @datupload6253
    @datupload6253 6 років тому +2

    I wanted buy it witch Playmaker because is on 50% salle now, but author just now increased price 33% :/ Not interested anymore, thank your greed.

    • @TokyoDan0
      @TokyoDan0 6 років тому +1

      Says the cheap a*sho*e.

    • @datupload6253
      @datupload6253 6 років тому +3

      That is not about price. But about little cheating on customers from sellers side.

  • @satya3xd
    @satya3xd 6 років тому

    Awesome

  • @Disthron
    @Disthron 6 років тому +6

    I feel like these tutorials should focus on core unity features and not assets you have to buy. This tutorial is probably pretty useless if you don't own this asset.

    • @Prox_C
      @Prox_C 5 років тому

      Except that this tutorial is for people that do own it, and it is nice to have some tutorial content for the package that is sponsored by unity. Always good to have more tutorials, just watch what applies to you.

  • @ZoidbergForPresident
    @ZoidbergForPresident 6 років тому +4

    I'm not sure about all those product placements... it shouldn't be the purpose of the youtube channel I think.

  • @rainboxsoftware8383
    @rainboxsoftware8383 6 років тому

    Can u make a tutorial how to install unity3d in Ubuntu
    I installed it and installed successfully but it's not working
    It's not running
    Plzzzz help me

  • @daijoubu712
    @daijoubu712 11 місяців тому +1

    Okay, how do you make the characters use animations when they are moving??? none of this makes sense???? YOUVE SHOWN NOTHING AT ALL

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

    $80 is a ripoff for what should be a standard integrated feature

  • @QuesterDesura
    @QuesterDesura 6 років тому +28

    Please make tutorials about ECS and not about how to create a game without programming knowledge. Don't force Unity in that corner of WYSIWYG Game Engines and Unity only being used by script kids.

    • @unity
      @unity  6 років тому +8

      Did you see all the content we released from the friday session at GDC with Mike Acton, Joachim and others? There is a lot of ECS content recently released for you to absorb on our channel. Enjoy. - Matt S.

    • @HouseCatTV
      @HouseCatTV 6 років тому +6

      That's elitist.

    • @dfhdgsdcrthfjghktygerte
      @dfhdgsdcrthfjghktygerte 6 років тому +13

      I completely disagree with "more games the better - you will find good ones". When something becomes accessible to casuals then entire industry gets flooded with shit and the real gems can be easily lost in the tons of brown substance. Having coding as a stepping stone in a gamedev really helps to sweep away most of the dilettantes so the only tougher ones will survive and will publish the game with some sort of OK quality. I'm talking from the customer point of view. Unity itself doing everything right: more casuals - more money, more money - more money.

    • @Twitch375
      @Twitch375 6 років тому +5

      Andrew Bishof
      Just because something is easy to understand and use does not necessarily mean it's pandering to casual developers. I'm sure a lot of experienced and hardworking devs are using every tool Unity has to offer (maybe not all at once). A good example of this is the new shader graph. Anyone can learn how to use it in a week or so. High level devs no longer have to fuck around with Unitys old shader code to get something done in 3 days that could've taken 3 hours with the new approach. Accessibility helps *everyone* and that's something a lot of people seem to miss.

    • @TokyoDan0
      @TokyoDan0 6 років тому +3

      I don't want more people making games. Especially people who can't code properly. And there is too much competition already so that most people, even great coders, can't make any money so they will not continue to make games.

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

    You know, instead of making us buy an asset yous guys could buy this asset like Bolt and make it free for everyone, gosh is not that hard for a multi-billionaire company to do that

  • @Angry-Lynx
    @Angry-Lynx 6 років тому +12

    too sexy voice to focus on content ;

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

    Useless for people who want to start with BD

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

    pls unity delete this video! i really cant watch this ! 75€ for a tool that is included within every gameengine(besides unity)?????!