Not a needless intro at all, surprisingly this is the first AI tutorial I've seen that actually explains why you would use a behaviour over a blueprint at all... rather than "ok we're building an AI so right click and search AI behaviour tree..." this might be one of my favourite new channels!
After all this time... Blackboards and Behavior Trees were the answer! Seriously I've been trying to get ai to go back to roaming for at least a year! Than you so much for this!
This is easily the best AI tutorial out there. not only you got to the point, you explained and gave easier solutions and introductions to things for other projects. Solid video!
Was so confused for so long, I'm new coming from different tutorials so my code was looking like a mishmash and yours looked really complex but after a few rewatches I got the AI chasing me properly and I'm ecstatic thank you man
This is the best tutorial I have seen yet for anything in UE4! I love how not only do you show how to do the tasks but you show *why*. That makes it very easy to actually learn the topic. I can't wait to go through the rest of the series and learn some different ways to use the great AI Controller from this video.
you are a secret hero! thx alot for this. i love this Fred Material Cube, my brain makes him instantly glowing eyes as your example AIC has taken control and possess that creapy cube for the first time.
I never wrote a comment on youtube before, but I just feel that I'll be a bad guy if I didn't thank you. Man, your tutorial is just from another level, compared to 10+ courses I had from Udemy, Artstation, and youtube. Please keep going and good luck.
Hey, it all worked!!! Thanks Dude, I'm more of an artist and I hadn't explored much of unreal outside of the basics setting up assets and make them look pretty, but this is the best AI tutorial I've seen yet and it's really easy to follow. I gonna dive into the rest of your content now.
Thanks for the series, looking forward to going through it! btw, at 41 minutes exactly, you can go file > refresh all nodes. It's especially helpful if you ever use the property and function transfer tool
I was looking at part 6 flying AI, and you had me go here as a catch up. Wow, I learned a lot. Now I know I can program UE like I do any other language, (referring to the MyAIFunctions). It makes sense and you didn't dumb it down as a lot of tubers do. (Subscribed)
I know this video was made a long time ago. But I am hoping that you are still checking these comments... I am running into an issue around 37:47 where my "CanSeeTarget?" bool will not update from false to true. All of the sensing seems to be working properly. The print strings are printing. But the bool will not change. Any advice would be greatly appreciated!
Thank you very mucb for this much needed tutorial. I need the Ai to patrol/roam to specific locations in the map instead of a random point in radius, can you make a tutorial for a task that goes with this tutorial?
Good Tutorial ......... but i doing it on my character and my character is slide and do the animation in the sametime pls tell me what can doing to keep the character not slide and walk not slide and walk pls reply fasst
I'm not sure what you mean, can you try explain more? One thing that comes to mind: Maybe play around with the Use Controller Rotation settings or 2d Blendspaces. Sounds like your character isn't set up to be facing one way while moving in another.
This is a very pleasant tutorial! Everything is clear, detailed in a way that shows you know what you're talking about (also, thanks for the multiple tips blueprint, like UpdateBBKey, that made me reflect about code optimisations). Did you come from a professional game-making environment? It seems like you had you fair share of project during your dev career. In any case you deserve more viewers as I found it more learning-friendly than RyanLaley's videos which just rush in everything without much explanations.
However I did work as a research scientist before I got into game development, so if these videos have a shred of professionalism I’d say that’s where it comes from
first of all love the video it was easy to understand, but i am not sure where it went wrong i did a similar one couple days ago and i followed this one step by step and have the same issue where the AI doesn't do anything and just stand there, when checking the BT it goes to the patrol and when sighted nodes but it rapidly moves between them and goes to the wait node so i was wondering does it have anything to do with it being UE4 .27 since a friend told me that some stuff are not working well in the newest version
Hey, Thanks for the great tutorial. I have one issue, though. My Enemy AI does not return to its origin. I don´t know why. I think I set up everything like you did.
Great video! I had a few bugs, but was able to fix them with a little bit of self troubleshooting. Thanks on helping me learn! Btw if anyone is reading this and wondering if it will work in Unreal 5 it does!
39:00 My AI will not do this for anything, I can run around corners, into buildings, and underwater, but once CanSeeTarget is set to True, it will not go back to false. Any suggestions?
how would you control what happens when AI roaming gets to a waypoint? I really want to have it curve instead of snapping to aim at the next point, is there a way to create a curve between two random points and have the ai follow the curve? so a sailing ship would look like it's curving..
Not sure if you can do it using AI Move To, but you can do this by adding force and turning the rotation of your character. I set up a system that does this in the Flying AI part of this series, you could probably apply it to your boat to give it smooth movement
Makes sense, thank you! It is patrolling, however I'd like to have the character move freely like a fish in the ocean not just on a navmesh surface but between and around floating objects, hunting for other fish... Any pointers on how to? :)
Hi, Thanks for the advice on the other issue I was having but now I have a new one, lol. For some reason the Moveto: Origin Node has stopped completing, Im sure Ive messed something up somewhere, its getting set correctly on the black board when i viewed it in real time it showed the pawns origin point, however moveto: Origin Flashes, doesnt complete and it gets stuck there in a loop and Im at a complete loss. All I wanted was something like a bee, goes out from a nest to a random point, waits there and then returns to the nest, Unless it sees a player at which point it aggressively chases them off, firing away. The tutorial was perfect for that, I just wanted to add a bit where it didnt just choose another random point but returned home after the reaching the first random point before selecting the next and now ive buggered the whole lot, I tried re following your tutorial but I cant seem to fix the issue. :( The random point selection and move to works fine, the following and shooting works fine its just the return to origin that seems to have gotten bricked. Ive been at it for hours trying to figure out whats going wrong but I just cant get move to origin to function as intended. Any Ideas whats causing it or if its easier just a zip file to download with the blueprints for that kind of AI already in place I can just slap a mesh on and be done? (With Full Credit of course) It really made the game Im working on so much more alive than the blueprint based AI i had cobbled together as well as saved a tonne of cpu overheads but I cant seem to wrap my head around these trees and the way all these variables intermingle and im sure its something dumb Ive overlooked somewhere but it was working perfectly last night and since I saved and reloaded its just seemed borked :( Thanks for the great tutorials tho they really go a long way to adding life to a game for one man bands like myself who lack these kind of skills
Hard to say what’s going on. Here are a few ideas of things to check: Is the pawns path being blocked somehow? Can it actually reach the origin? Is the destination key on the MoveTo node actually the correct key? FYI the project files are available in the description
Might pay to check all your decorator nodes too, especially the abort conditions. Sometimes they can cause weird glitches in the tree if they’re set to abort the wrong things whenever their Boolean is changed
Thank you so much for the tutorial but how can we use the Pawn Sensing Component to sense from multiple Pawns in the game and then follow the one closest and if it loses sight of it then look for the next nearest sensed pawn?
Found your flying ai as I've been working on a multiplayer game for the past few years and finally decided to add some troops. It worked. So now I'm on this video. For some reason as soon as I started with pawn sensing the ai will spin in circles. It works off and on with one of my dragons when I spawn, but when I spawn a giant or another dragon rider type it just does it. If I turn off the yaw control in the AI CharBP The AI just goes wandering off to neverland. Any ideas?
I have a slight problem, the chase player sequence tries to kick off but isntanly fails, and when can see target is updated to true, roaming isnt aborted.
@@esotericgamedev it turns out that using the same function library for two different AI's was the problem, so i ended up just updating the blackboard manually for the one that was broken.
Hello, I have the problem what I also saw in the comments: The enemy doesn't turn back to origin. But even without the backtoorininthing the rest works very well. I found out the BTTasks all have a box inside the ring in the thumbnail instead of a ring without a box inside. I am using UE5.2. Maybe this is in my case the reason?
please help! i cant get the behavior tree to function properly. i have everything set up the same. it will wait 5 seconds then do a super quick flash trough the rest of the tree and my ai wont move.
@@marta-dy4no the quick flash through the tree means all of your tasks are instantly failing. One example causing this could be because the nav mesh is broken and the AI can’t move
Thanks for the video man, i have an issue though, im creating a rts and my camera is set as default pawn, so my pawn sensing only follows the camera pawn on the middle, do you know how to make it follow my other units?
Hey man, ive been following your tutorials, and im getting this error regarding your set value as bool system. The error is pretty consistent, but due to it being contained within the AI_functions Area, i cant seem to find what heckin bool its refferring to. its one of those "acccesed none trying to read Callfunc_getblackboard_returnvalue" And its always the set-blackboard-key function and always the "set value as bool" Which is weird because nothing seems to be "failing" simulation wise. Nothing obvious. Every other Setvalue system returns no problems. Just thought i'd ask for your thoughts.
Sounds like it's being called to try and set a boolean on a blackboard that doesn't yet exist, like at begin play or maybe after an actor has been destroyed. Is it screwing up your game in any way?
@@esotericgamedev I don't know if it was causing huge issues, but getting so many errors did kinda worry me. I've tracked the source to the "Set_BB_key" thing (the one with a bunch of variables plugged in to the UpdateBBkey Function) and the "didsee" Bool. I took that BTT out and made a new one that solely updates the bool and the errors disappeared. which is weird because i still dont know why setBBkey didnt function.
Additionally, on the topic of setting a bool too early, because its the "recently saw" or "didsee" its quite far away from begin play or dead- as currently no one can die either.
@@esotericgamedev I was testing something out a few minutes ago- and i saw that the AI controller was set as a variable in the Setbbkey_task . Changed that, plugged it in to the Event recieve execute (owner controller). no more errors -__-' So yeah sounds like you're right on the money there, thanks!
Great tutorial, I got this figured out on 3d now, but how would you get this to work on a 2d project? I can't seem to figure out for the life of me how to get AI on 2d to work with Behavior Trees. Doing AI through the regular blueprints was easy to figure out but it's tedious. I know this can be done in 2d I'm just having trouble figuring it out.
Hiho, I have 2 questions about the tutorial. 1. My PatrolieAI does not follow me, does someone have an idea why this is? 2. How can my PatrolieAI follow me when looking for Pawn and not for actor? THX ^^
Hello there, Excellent and so helpful tutorial! Thank you so much for sharing with us this one as well the rest of your series! May I please ask you how to add specific animations for each state? (In my case I have some basic animation blueprint and custom imported individual animations but no idea how to actually write states in there to call upon and connect to the AI) for Example how to play an idle animation on the "wait" state and then play walk animation on "move to" state, etc. I have looked so much around but not able to find something to understand. Do you have any suggested tutorials? Thank you kindly!
You'll be able to setup different animations based on character speed using a State Machine and Blendspace inside an Animation Blueprint. Search those terms, there are plenty of great tutorials out there. Virtus Learning Hub is a good place to start
@Jackson'sGames , i'm doing this on a side scroller, how cna i restrict the Ai we've created, their randomn location movement to strictly on the Y-Axis(left and right)? I know this is super late haha
I've never worked with a side scroller project before, but my first thought is to strip out the axis you don't want to use from the find MoveTo location node. 1. Get random location in nav radius 2. Break vector 3. Make vector using only Z and Y or whatever axis you like 4. Make vector and use this as the MoveTo location No idea if this'll work but this is what comes to mind lol
@@esotericgamedev Thanks for the feedback, im still trying to work that part out its proving to be difficult. However i had another question. What if we wanted to create a Ai that always followed the player ? Like a companion.
This whole video took be about 18 hours to get through as I was working on tweaking stuff as it was being built. Although, I wanted to mention that at the very end, when applying the "Return to Origin" BT, the same sequence did not work in my own situation. The AI would move to the Origin and cycle through that same tree indefinitely, not returning to Move to Location. Just in case anyone else has the same issue, I was able to fix it by applying "is not set" to the BB condition on SetBBKey, SetBBkey to False as well > wait > Return to Origin > Stop Gameplay Behavior with "Is at Location" attached. That way the sequence would play for chasing, check if the player is still in sight, move to origin, verify origin location, then revert back to Move to Location.
really great tutorials,thx alot! Dont hesitate to create a udemy course for your tutorials. Even thought i am following the complete tutorials i will also buy the gumroad pack to support you.
i got the waiting to fire off.. after trying to set this up on another character and then copy and paste it to another character it didnt work.. i set up the variables and wouldnt show the behavior tree node.. started all over again and there it is.. my god this program is picky.. cant copy and paste ANYTHING.. all has to be built from scratch in every single character.. that sucks..
When I played video games as a kid, I never thought about all the crazy things a developer had to do to bring good stuff to the table.
2:10 Start
2:45 Navmesh
3:18 Character
6:40 Setup AIC
12:00 BT roaming
12:25 BTT find roaming location
12:40 Receive execute AI
13:30 GetRandomReachablePointInRadius
13:50 Blackboard key
14:30 Finish Execute
15:05 BT set FindRoamingLocationBTT
15:33 BT set MoveTo
16:38 simulate
18:30 Pawn Sensing
20:10 On See Pawn
22:50 Function Library
36:00 debug Set type as pawn
38:00 Run BT before update BB key
Thank you!!!!
My need to make AI in Unreal brought me here.
Thank you and have a great day.
Hope it helps mate, feel free to ask any questions you might have
Finally a Ai tutorial that make sense and actually works. Jackson you da man!!!
Not a needless intro at all, surprisingly this is the first AI tutorial I've seen that actually explains why you would use a behaviour over a blueprint at all... rather than "ok we're building an AI so right click and search AI behaviour tree..." this might be one of my favourite new channels!
Thank you Logan I’m glad to hear it 😊 thanks for tuning in
After all this time... Blackboards and Behavior Trees were the answer! Seriously I've been trying to get ai to go back to roaming for at least a year! Than you so much for this!
Glad I could help :)
This is easily the best AI tutorial out there. not only you got to the point, you explained and gave easier solutions and introductions to things for other projects. Solid video!
Thanks mate glad it helped
Was so confused for so long, I'm new coming from different tutorials so my code was looking like a mishmash and yours looked really complex but after a few rewatches I got the AI chasing me properly and I'm ecstatic thank you man
Hahaha you’re welcome
This is the best tutorial I have seen yet for anything in UE4! I love how not only do you show how to do the tasks but you show *why*. That makes it very easy to actually learn the topic. I can't wait to go through the rest of the series and learn some different ways to use the great AI Controller from this video.
Glad I could help 😊
you are a secret hero! thx alot for this. i love this Fred Material Cube, my brain makes him instantly glowing eyes as your example AIC has taken control and possess that creapy cube for the first time.
😆 you’re welcome
I never wrote a comment on youtube before, but I just feel that I'll be a bad guy if I didn't thank you. Man, your tutorial is just from another level, compared to 10+ courses I had from Udemy, Artstation, and youtube. Please keep going and good luck.
abdu saad thank you for the feedback man, glad to help 😊
Hey, it all worked!!! Thanks Dude, I'm more of an artist and I hadn't explored much of unreal outside of the basics setting up assets and make them look pretty, but this is the best AI tutorial I've seen yet and it's really easy to follow. I gonna dive into the rest of your content now.
Fantastic. Glad to hear it mate, thanks for taking the time to let me know.
Thanks for the series, looking forward to going through it! btw, at 41 minutes exactly, you can go file > refresh all nodes. It's especially helpful if you ever use the property and function transfer tool
Omg I never knew this, thank you haha
Thanks so much man, this series is amazing! Really enjoyable to watch and perfectly paced.
Incendiary Agenda thanks for the feedback man glad you liked it 🥰
I was looking at part 6 flying AI, and you had me go here as a catch up. Wow, I learned a lot. Now I know I can program UE like I do any other language, (referring to the MyAIFunctions). It makes sense and you didn't dumb it down as a lot of tubers do. (Subscribed)
Glad to hear it
Damn i was searching this for a week, thanks :D
I know this video was made a long time ago. But I am hoping that you are still checking these comments... I am running into an issue around 37:47 where my "CanSeeTarget?" bool will not update from false to true. All of the sensing seems to be working properly. The print strings are printing. But the bool will not change. Any advice would be greatly appreciated!
Bruhh i dont know how but you have made the best tutorial on A.I thx
lol thx my dude
Even though you kept saying you won't explain much, yet you explained so well, like why FinishExcute. Thank you!!
It’s my pleasure
Thank you very mucb for this much needed tutorial.
I need the Ai to patrol/roam to specific locations in the map instead of a random point in radius, can you make a tutorial for a task that goes with this tutorial?
Awesome tutorial!!!
Thank you so much this have been trying to get something like this to work for like a week. Very new to Ai. :)
Thanks, this is just what I was looking for
My pleasure mate
Good Tutorial ......... but i doing it on my character and my character is slide and do the animation in the sametime pls tell me what can doing to keep the character not slide and walk not slide and walk pls reply fasst
I'm not sure what you mean, can you try explain more? One thing that comes to mind: Maybe play around with the Use Controller Rotation settings or 2d Blendspaces. Sounds like your character isn't set up to be facing one way while moving in another.
Sharon help me pleADDH#^@^
@@The-Soothsayer ?bruh
Is there ANY way to get this to work with vehicle movement components?
Respect mate. Thanks a lot for sharing.
This is a very pleasant tutorial! Everything is clear, detailed in a way that shows you know what you're talking about (also, thanks for the multiple tips blueprint, like UpdateBBKey, that made me reflect about code optimisations). Did you come from a professional game-making environment? It seems like you had you fair share of project during your dev career. In any case you deserve more viewers as I found it more learning-friendly than RyanLaley's videos which just rush in everything without much explanations.
Glad to hear it helped mate. No actually I’ve never even worked in the industry, everything here is self taught from building my own projects.
However I did work as a research scientist before I got into game development, so if these videos have a shred of professionalism I’d say that’s where it comes from
amazing tutorial...probably the best one on this topic
Glad I could help :)
first of all love the video it was easy to understand, but i am not sure where it went wrong i did a similar one couple days ago and i followed this one step by step and have the same issue where the AI doesn't do anything and just stand there, when checking the BT it goes to the patrol and when sighted nodes but it rapidly moves between them and goes to the wait node so i was wondering does it have anything to do with it being UE4 .27 since a friend told me that some stuff are not working well in the newest version
having the same issue any advice?
Hey, Thanks for the great tutorial. I have one issue, though. My Enemy AI does not return to its origin. I don´t know why. I think I set up everything like you did.
Great video! I had a few bugs, but was able to fix them with a little bit of self troubleshooting. Thanks on helping me learn! Btw if anyone is reading this and wondering if it will work in Unreal 5 it does!
Glad I could help mate ✌️
This is great, wonderfully done, easy to understand and to follow too!
Keep it up and make more please i would love to learn more about AI :)
Glad I could help :) Also SAO is awesome hehe
39:00 My AI will not do this for anything, I can run around corners, into buildings, and underwater, but once CanSeeTarget is set to True, it will not go back to false. Any suggestions?
I had the same issue. Turns out I misspelled the "Key Name" when referencing "Update BBKey". (its case sensitive).
how would you control what happens when AI roaming gets to a waypoint? I really want to have it curve instead of snapping to aim at the next point, is there a way to create a curve between two random points and have the ai follow the curve? so a sailing ship would look like it's curving..
Not sure if you can do it using AI Move To, but you can do this by adding force and turning the rotation of your character. I set up a system that does this in the Flying AI part of this series, you could probably apply it to your boat to give it smooth movement
Makes sense, thank you! It is patrolling, however I'd like to have the character move freely like a fish in the ocean not just on a navmesh surface but between and around floating objects, hunting for other fish... Any pointers on how to? :)
Keep watching the series until you get to Flying AI
@@esotericgamedev Alright, thanks! :)
Hi, Thanks for the advice on the other issue I was having but now I have a new one, lol. For some reason the Moveto: Origin Node has stopped completing, Im sure Ive messed something up somewhere, its getting set correctly on the black board when i viewed it in real time it showed the pawns origin point, however moveto: Origin Flashes, doesnt complete and it gets stuck there in a loop and Im at a complete loss.
All I wanted was something like a bee, goes out from a nest to a random point, waits there and then returns to the nest, Unless it sees a player at which point it aggressively chases them off, firing away. The tutorial was perfect for that, I just wanted to add a bit where it didnt just choose another random point but returned home after the reaching the first random point before selecting the next and now ive buggered the whole lot, I tried re following your tutorial but I cant seem to fix the issue. :( The random point selection and move to works fine, the following and shooting works fine its just the return to origin that seems to have gotten bricked. Ive been at it for hours trying to figure out whats going wrong but I just cant get move to origin to function as intended.
Any Ideas whats causing it or if its easier just a zip file to download with the blueprints for that kind of AI already in place I can just slap a mesh on and be done? (With Full Credit of course) It really made the game Im working on so much more alive than the blueprint based AI i had cobbled together as well as saved a tonne of cpu overheads but I cant seem to wrap my head around these trees and the way all these variables intermingle and im sure its something dumb Ive overlooked somewhere but it was working perfectly last night and since I saved and reloaded its just seemed borked :(
Thanks for the great tutorials tho they really go a long way to adding life to a game for one man bands like myself who lack these kind of skills
Hard to say what’s going on. Here are a few ideas of things to check: Is the pawns path being blocked somehow? Can it actually reach the origin? Is the destination key on the MoveTo node actually the correct key? FYI the project files are available in the description
Might pay to check all your decorator nodes too, especially the abort conditions. Sometimes they can cause weird glitches in the tree if they’re set to abort the wrong things whenever their Boolean is changed
There is no event for pawn sensing to update the pawn pin ( to none ) when losing sight of the currently perceived pawn.
How did you get your character to start running, as I can't get the patrolling AI to stop chasing me and move fast enough?
Thank you so much for the tutorial but how can we use the Pawn Sensing Component to sense from multiple Pawns in the game and then follow the one closest and if it loses sight of it then look for the next nearest sensed pawn?
Found your flying ai as I've been working on a multiplayer game for the past few years and finally decided to add some troops. It worked. So now I'm on this video. For some reason as soon as I started with pawn sensing the ai will spin in circles. It works off and on with one of my dragons when I spawn, but when I spawn a giant or another dragon rider type it just does it. If I turn off the yaw control in the AI CharBP The AI just goes wandering off to neverland. Any ideas?
25:12 what should i use instead of float * float ? | it does not exist in UE 5.1^^
Multiply
@@esotericgamedev ԅ(¯﹃¯ԅ) could not breath without your instructions, thank you
@@realmcafee 😆🙏😅
I have a slight problem, the chase player sequence tries to kick off but isntanly fails, and when can see target is updated to true, roaming isnt aborted.
update the abort conditions on the blue decorator node
@@esotericgamedev it turns out that using the same function library for two different AI's was the problem, so i ended up just updating the blackboard manually for the one that was broken.
Hello, I have the problem what I also saw in the comments: The enemy doesn't turn back to origin. But even without the backtoorininthing the rest works very well. I found out the BTTasks all have a box inside the ring in the thumbnail instead of a ring without a box inside. I am using UE5.2. Maybe this is in my case the reason?
Not sure, but come over to the discord if you like and somebody there might have an idea
@@esotericgamedev OK Thank You!
Damn good stuff man! THANKS!
My pleasure
Thank you dude :)
glad I could help :)
please help! i cant get the behavior tree to function properly. i have everything set up the same. it will wait 5 seconds then do a super quick flash trough the rest of the tree and my ai wont move.
If everything was the same it would work, there must be a mistake
@@esotericgamedev I figured out what was wrong. Under project settings i had to change how run time.
@@esotericgamedev typically in the world of game dev and following tuts theres a mistake some where lol this time was a bit diff
I'm having the same problem! What runtime settings did you change it to?
@@marta-dy4no the quick flash through the tree means all of your tasks are instantly failing. One example causing this could be because the nav mesh is broken and the AI can’t move
Jackson's Games - how do i reduce the movement spedd of the ai
Caharactet movement walk speed
@@esotericgamedev okay thnak you
Thanks for the video man, i have an issue though, im creating a rts and my camera is set as default pawn, so my pawn sensing only follows the camera pawn on the middle, do you know how to make it follow my other units?
Hey man, ive been following your tutorials, and im getting this error regarding your set value as bool system.
The error is pretty consistent, but due to it being contained within the AI_functions Area, i cant seem to find what heckin bool its refferring to.
its one of those "acccesed none trying to read Callfunc_getblackboard_returnvalue" And its always the set-blackboard-key function and always the "set value as bool"
Which is weird because nothing seems to be "failing" simulation wise. Nothing obvious. Every other Setvalue system returns no problems.
Just thought i'd ask for your thoughts.
Sounds like it's being called to try and set a boolean on a blackboard that doesn't yet exist, like at begin play or maybe after an actor has been destroyed. Is it screwing up your game in any way?
@@esotericgamedev I don't know if it was causing huge issues, but getting so many errors did kinda worry me.
I've tracked the source to the "Set_BB_key" thing (the one with a bunch of variables plugged in to the UpdateBBkey Function) and the "didsee" Bool.
I took that BTT out and made a new one that solely updates the bool and the errors disappeared.
which is weird because i still dont know why setBBkey didnt function.
Additionally, on the topic of setting a bool too early, because its the "recently saw" or "didsee" its quite far away from begin play or dead- as currently no one can die either.
@@sampender7469 strange, maybe an invalid AI Controller rather than blackboard? But honestly could be anything 😅
@@esotericgamedev I was testing something out a few minutes ago- and i saw that the AI controller was set as a variable in the Setbbkey_task . Changed that, plugged it in to the Event recieve execute (owner controller). no more errors -__-'
So yeah sounds like you're right on the money there, thanks!
Thank you SO MUCH for the incredible material! Definitely subbing:)
Glad I could help
Great tutorial really Awesome 👍.
Awesome tutorial! Thanks for it!
glad I could help :)
Great tutorial, I got this figured out on 3d now, but how would you get this to work on a 2d project? I can't seem to figure out for the life of me how to get AI on 2d to work with Behavior Trees. Doing AI through the regular blueprints was easy to figure out but it's tedious. I know this can be done in 2d I'm just having trouble figuring it out.
I’d assume that it would be the same but you would just set the position on one of the axis to zero
Hiho, I have 2 questions about the tutorial.
1. My PatrolieAI does not follow me, does someone have an idea why this is?
2. How can my PatrolieAI follow me when looking for Pawn and not for actor? THX ^^
I’m afraid you’ll need to be more specific, I don’t understand what you’re asking
@@esotericgamedev i will try. At the point print string can see/cant see I will not get the message
Hello there, Excellent and so helpful tutorial! Thank you so much for sharing with us this one as well the rest of your series! May I please ask you how to add specific animations for each state? (In my case I have some basic animation blueprint and custom imported individual animations but no idea how to actually write states in there to call upon and connect to the AI) for Example how to play an idle animation on the "wait" state and then play walk animation on "move to" state, etc. I have looked so much around but not able to find something to understand. Do you have any suggested tutorials? Thank you kindly!
You'll be able to setup different animations based on character speed using a State Machine and Blendspace inside an Animation Blueprint. Search those terms, there are plenty of great tutorials out there. Virtus Learning Hub is a good place to start
I just want to say thank you
my pleasure mate :)
Please do flying navigation!!!
Sounds tricky but I could give it a go :P I have a basic flying AI tutorial at the end of this series if that does what you're looking for
Fantastic tutorial! Very clean and easy to follow
Glad I could help :)
@Jackson'sGames , i'm doing this on a side scroller, how cna i restrict the Ai we've created, their randomn location movement to strictly on the Y-Axis(left and right)? I know this is super late haha
I've never worked with a side scroller project before, but my first thought is to strip out the axis you don't want to use from the find MoveTo location node.
1. Get random location in nav radius
2. Break vector
3. Make vector using only Z and Y or whatever axis you like
4. Make vector and use this as the MoveTo location
No idea if this'll work but this is what comes to mind lol
@@esotericgamedev Thanks for the feedback, im still trying to work that part out its proving to be difficult. However i had another question. What if we wanted to create a Ai that always followed the player ? Like a companion.
@@relaygaming3308 Use AIMoveTo node and set the Player Character or Pawn as the MoveTo target actor
This whole video took be about 18 hours to get through as I was working on tweaking stuff as it was being built.
Although, I wanted to mention that at the very end, when applying the "Return to Origin" BT, the same sequence did not work in my own situation. The AI would move to the Origin and cycle through that same tree indefinitely, not returning to Move to Location. Just in case anyone else has the same issue, I was able to fix it by applying "is not set" to the BB condition on SetBBKey, SetBBkey to False as well > wait > Return to Origin > Stop Gameplay Behavior with "Is at Location" attached. That way the sequence would play for chasing, check if the player is still in sight, move to origin, verify origin location, then revert back to Move to Location.
18 hours woweee, dedication :D
Thanks again
Bless you
really great tutorials,thx alot!
Dont hesitate to create a udemy course for your tutorials. Even thought i am following the complete tutorials i will also buy the gumroad pack to support you.
Soleil thank you, I’m glad I could help 🥰
Great work! Thanks!
MrDevonParsons my pleasure
Why are you using pawn sensing in 2020? Why not AI perception ?
i could never get behavior trees to work.
i got the waiting to fire off.. after trying to set this up on another character and then copy and paste it to another character it didnt work.. i set up the variables and wouldnt show the behavior tree node.. started all over again and there it is.. my god this program is picky.. cant copy and paste ANYTHING.. all has to be built from scratch in every single character.. that sucks..
Mine won't stop chasing
I figured it out
He wants ur blood
17:53 It has become self aware.
😆 he is escaping the computer
Thanks !!
Just saw a way to increase speed, engine input, and added it to my third person character
Thanks dude
My pleasure homie
24:04
When you click things and tabs while explaining other things it starts to lose me lol
LOL FREEEDD
Ma boy
@@esotericgamedev lol, love your tutorials btw, im on guardian episode, im making a guardian stalker for my yt video coming out soon.
@@quilldev6280 glad to hear it 😊 and nice lol guardian stalkers are rad
Slightly eccentric, eh? 😄
🥴