Enemy AI Series 1: The State Machine

  Рет қаралды 52,394

Garbaj

Garbaj

Күн бұрын

Пікірлер: 108
@jlewwis1995
@jlewwis1995 4 жыл бұрын
11:34 *yanderedev has entered the chat*
@leechjuice4546
@leechjuice4546 3 жыл бұрын
lol
@foam444
@foam444 3 жыл бұрын
Hah!
@rafaelgpontes
@rafaelgpontes 4 жыл бұрын
I sincerely think that state machine is one of the most important topics to learn in game dev.
@garbaj
@garbaj 4 жыл бұрын
I agree, it's so useful!
@ishkapoor7931
@ishkapoor7931 4 жыл бұрын
somehow in just love with your tutorial... you are an amazing tutor and a guide... Hope to really amazing stuff from you(greedy). though you have already made some really amazing tuts!!!
@garbaj
@garbaj 4 жыл бұрын
Thanks for your support!
@raghavendrabhat6035
@raghavendrabhat6035 4 жыл бұрын
@@garbaj you deserve so much more from youtube man
@sigitsatriap6505
@sigitsatriap6505 4 жыл бұрын
State machine ?? Finally !! Please make player state machine in the next video, can you make it with 3rd person ? Its more easy to see player action i think I can’t understand at other video tutorial, Your explanation was easy to understand I’m joining your discord ! 🥳
@garbaj
@garbaj 4 жыл бұрын
Thank you! Also, this state machine can be used for anything, including player characters and 3rd person as well. It's all the same
@jamesxxxyz8775
@jamesxxxyz8775 4 жыл бұрын
kzbin.info/www/bejne/gpKxkoejjtZmobs there is a download link for 3rd person controller.
@sigitsatriap6505
@sigitsatriap6505 4 жыл бұрын
JamesXXXYZ thanks alot !!! Really u know what i looking for 👍🏻
@_mickmccarthy
@_mickmccarthy 4 жыл бұрын
Awesome! Thoroughly looking forward to the rest of this series!
@garbaj
@garbaj 4 жыл бұрын
Thanks!
@NOPerative
@NOPerative 4 жыл бұрын
Garbaj != garbage state isTrue == TRUE Awesome stuff as usual. One's trash may be another's treasure - would agree considering this video. Excellent example and discussion - topic & delivery 10/10.
@garbaj
@garbaj 4 жыл бұрын
Wow, thanks for the words of encouragement! I'll continue to do my best
@mr0o
@mr0o 4 жыл бұрын
Just found your channel yesterday and holy shit this is great stuff! I am learning a lot more than I have from other tutorials
@garbaj
@garbaj 4 жыл бұрын
Welcome! Glad you're finding my videos helpful
@nightcode3171
@nightcode3171 4 жыл бұрын
Very simple and very helpful, thanks for the tutorials
@garbaj
@garbaj 4 жыл бұрын
Glad it helped!
@bity-bite
@bity-bite 4 жыл бұрын
love how you explain everything!
@garbaj
@garbaj 4 жыл бұрын
Just trying to do my best!
@s.s.scriptties
@s.s.scriptties 3 жыл бұрын
I have a problem in line 19 if raycast.is_colliding( ): it is saying its a debugging error : Attempt to call function 'is_colliding' in base 'null instance' on a null instance . I'm new to programing so don't know what any of dat means so can u pls help
@lezharayman9897
@lezharayman9897 4 жыл бұрын
PLZ make more and more and more ..... Keep them coming. A BIG SUBSCRIBE FOR YOU !!!
@garbaj
@garbaj 4 жыл бұрын
Appreciate the sub! Welcome to the channel
@BrianRogers3D
@BrianRogers3D 3 жыл бұрын
great job explaining some programming basics and common approaches. I'm more of an animator and 3D guy than programming. I've decided to make something in VR using Godot, so I watch every vid you make, because you are such a great teacher. Really appreciate your efforts.
@yamen._.m
@yamen._.m 4 жыл бұрын
Please continue all of these amazing and clear tutorials please please Thank u soo much I have some difficulty in stuff like this And what u are doing helps me a lot I can finish earlier as well as learn tons of stuff Again, Thank u man :-)
@garbaj
@garbaj 4 жыл бұрын
Hey! Glad my videos are helping you
@vatan2578
@vatan2578 4 жыл бұрын
Thank you very much for your educational sharing. I wish you Health and Success.
@garbaj
@garbaj 4 жыл бұрын
Thanks, much appreciated
@davidfilus1741
@davidfilus1741 2 жыл бұрын
Such an amazing explanation! Can't wait for the rest of the series!
@shayneoneill1506
@shayneoneill1506 4 жыл бұрын
If your getting into fairly advanced stuff, its worth looking into Behavior Trees, which dont have a lot of the downsides of state machines. That said there aren't a lot of good implementations of behavior trees on Godot. (The one I use I had to hack extensively to implement a blackboard. One of these days I'll either push the changes back, or upload it myself, but its a bit of a dirty hack that needs some cleaning.
@enclonstudio2525
@enclonstudio2525 4 жыл бұрын
ТЫ красава,успехов тебе
@garbaj
@garbaj 4 жыл бұрын
благодарю вас
@classicguy7813
@classicguy7813 4 жыл бұрын
Subbed and amazed . Love Turkey
@garbaj
@garbaj 4 жыл бұрын
Thanks for the sub, glad to help!
@roflman
@roflman 3 жыл бұрын
"Can't we just use a bunch of if statements instead?" No Yandere dev, go away
@arturbrilliant
@arturbrilliant 4 жыл бұрын
Thank you for your videos, bro! :)
@garbaj
@garbaj 4 жыл бұрын
You're welcome
@unfa00
@unfa00 3 жыл бұрын
Oh wow, I wish I've watched this *before* I implemented my super crappy state machine based on strings rather than enums...
@jackthejzsc1629
@jackthejzsc1629 3 жыл бұрын
0:45 Squid game?
@christianbatista0
@christianbatista0 2 жыл бұрын
Thank you for telling me there is more then IF and ELSE
@Fropaa
@Fropaa 3 жыл бұрын
i have a problem in 11:00 the dummy doesnt play the animation when the raycast is collision help
@drew230
@drew230 3 жыл бұрын
Just found this today,man this is what I needed fam
@redsnow579
@redsnow579 4 жыл бұрын
Start sharing this like crazy people! Indie game devs need to know that these tutorials exist!
@garbaj
@garbaj 4 жыл бұрын
Thanks for the support! And yes, please share my videos with the world!
@mali-wp8wc
@mali-wp8wc 4 жыл бұрын
First
@warriorsimplicity1
@warriorsimplicity1 4 жыл бұрын
You're the best ONE to make Godot tutorials
@garbaj
@garbaj 4 жыл бұрын
Thanks!
@NgaeGameStudio
@NgaeGameStudio 3 жыл бұрын
Yeah thats what exactly i did last year with gamemaker in 2d fighting game, i use health and stamina to take decision for the AI, if AI health less than 1 then ai will do something or if gun low ammo then ai will do something 👍 keep that good work bro
@UlfgrimRaneth
@UlfgrimRaneth 4 ай бұрын
Finally! I've been stuck with trying to make the AI for my game work for weeks and every tutorial just told me what to do instead of actually teaching how it works. Your video is a godsent. Thank you so much.
@Chevifier
@Chevifier 4 жыл бұрын
Ive been using Godot for years and didnt realize I dont have the give the Enumerator a name lol I usually do something like enum PlayerState = { IDLE, WALKING, JUMPING } then call it like state = PlayerState.IDLE
@garbaj
@garbaj 4 жыл бұрын
it's probably a good idea to name them so things don't get mixed up, but yeah you don't actually have to do it
@nicholasdellipaoli226
@nicholasdellipaoli226 2 жыл бұрын
So happy to see that the first clip of gaming used in a video titled about creating AI, is Halo Combat Evolved. The best enemy AI in any FPS ever!
@handsome_lad
@handsome_lad 4 жыл бұрын
Nice :D
@Evangelion09
@Evangelion09 2 жыл бұрын
IT IS SO F GODD TUTORIAL!!!!!!! perfect
@gimong5537
@gimong5537 3 жыл бұрын
can i make him chase the character? please show me how
@OmegaF77
@OmegaF77 2 жыл бұрын
It's perfect aside from the fact that the states are still smeared across the logic. The better way would be have different functions as states and run those functions in the match/case (switch) statements. Each function would have their own logic and animation.
@FletcherGaddy
@FletcherGaddy 3 жыл бұрын
Aw looks like this series kinda died, shame. Love your content in general man, keep making awesome videos!
@travisratto5418
@travisratto5418 2 жыл бұрын
I'm glad i found this channel. Plus you update your code.
@shakthinandan7124
@shakthinandan7124 3 жыл бұрын
I watched state machine videos before but never understood the topic State Machines this better The way your explain is so good Keep making more videos
@DuhKoreGames
@DuhKoreGames 3 ай бұрын
needs a godot 4 update to this series!
@mahmoud_ali_963
@mahmoud_ali_963 4 жыл бұрын
I wish you make tutorial on export game in godot I made a simple game in godot and after exporting it ..it can't change the menu sean to the game sean
@nomadic_shadow
@nomadic_shadow 2 жыл бұрын
Thanks, Garbaj. This was really helpful in me making my basic patrolling AI that uses raycasts to detect collisions.
@notplushh
@notplushh 3 жыл бұрын
TYSM YOUR TUTORIALS ALWAYS GET THE JOB DONE 99.99% OF THE TIME
@luh034
@luh034 3 жыл бұрын
why is this channel so small? It deserves way more subs i think.
@disdis6127
@disdis6127 3 жыл бұрын
Great video!
@justalemur5285
@justalemur5285 4 жыл бұрын
you the best
@garbaj
@garbaj 4 жыл бұрын
Thanks!
@ranjithrans
@ranjithrans 4 жыл бұрын
How could you read my mind???
@garbaj
@garbaj 4 жыл бұрын
Muahahahaha!
@frankoesavage8314
@frankoesavage8314 4 жыл бұрын
.......plot twist i was thinking the same thing
@nightcode3171
@nightcode3171 4 жыл бұрын
Ikrr
@judelingan5863
@judelingan5863 3 жыл бұрын
this is really good, but how is an enumerator better than an array?
@garbaj
@garbaj 3 жыл бұрын
It's not necessarily better, but being able to refer to a state by it's name rather than by it's array index is a little easier to explain in a tutorial
@nightcode3171
@nightcode3171 4 жыл бұрын
Can u do an item or inventory system, i-if it's not to much.
@garbaj
@garbaj 4 жыл бұрын
Hope to do this eventually, just gotta learn how
@drbjbpog9956
@drbjbpog9956 2 жыл бұрын
this is great
@juancarlosblanco5259
@juancarlosblanco5259 4 ай бұрын
eres el mejor
@denizdemir9255
@denizdemir9255 4 жыл бұрын
This was really easy to understand! Another amazing tutorial.
@jamesxxxyz8775
@jamesxxxyz8775 4 жыл бұрын
Can you simulate viewing cone with raycasts? Position should be where the eyes are and in the idle state, enemy should look in random directions. When enemy detect the player he should turn to the player (while moving?).
@garbaj
@garbaj 4 жыл бұрын
Yes, you can. It requires some math that I don't understand, but it's definitely possible
@erhansevimli8219
@erhansevimli8219 Ай бұрын
Great tutoriaL
@seopterleo7934
@seopterleo7934 4 жыл бұрын
Is the game that u played the first made with godot. By the way amazing tutorial
@garbaj
@garbaj 4 жыл бұрын
No, that's Halo: Combat Evolved, made by Bungie for Xbox
@seopterleo7934
@seopterleo7934 4 жыл бұрын
Oh
@velot1eksedimoi417
@velot1eksedimoi417 4 жыл бұрын
I want to write it in c# , if i follow along your videos and just change syntax to c# , is it enough for it to work? Why wont you write your game code in c#?
@garbaj
@garbaj 4 жыл бұрын
I don't know if it's just a matter of changing the syntax. I'm clueless when it comes to C#
@HalfAsleepSam
@HalfAsleepSam 2 жыл бұрын
AI gets me excited instead of nervous
@abhishek-farswan
@abhishek-farswan 3 жыл бұрын
spartans assemble
@mahmoud_ali_963
@mahmoud_ali_963 4 жыл бұрын
Pro you grate
@mlnz2991
@mlnz2991 3 жыл бұрын
your tutorial is so easy to understand, thanks
@jesustzinon
@jesustzinon 4 жыл бұрын
Bro, this is a very good tutorial, this is very well explained! keep making these vids!
@garbaj
@garbaj 4 жыл бұрын
Thanks, will do!
@warriorsimplicity1
@warriorsimplicity1 4 жыл бұрын
6:46 how to get that code in my case?
@ahmadtakhimi6839
@ahmadtakhimi6839 4 жыл бұрын
Thank you for the tutorials. Can you please do a ragdoll setup and ingame usage ? Thanks
@garbaj
@garbaj 4 жыл бұрын
Hope to do a video on this soon
@mahmoud_ali_963
@mahmoud_ali_963 4 жыл бұрын
Im really thankful
@vsevolod_pl
@vsevolod_pl 4 жыл бұрын
How to import .blend model in godot?
@garbaj
@garbaj 4 жыл бұрын
You first need to export the model to a 3d format (obj, gltf, dae) before you can import it into Godot. A .blend file by itself wont import
@vsevolod_pl
@vsevolod_pl 4 жыл бұрын
@@garbaj Thank you! Which 3d format is better to choose?
@pascalcasier959
@pascalcasier959 4 жыл бұрын
Thank you so much for another great tutorial.
@garbaj
@garbaj 4 жыл бұрын
You're welcome!
@heawon78
@heawon78 4 жыл бұрын
Thank you
@garbaj
@garbaj 4 жыл бұрын
You're welcome!
Running With Bigger And Bigger Lunchlys
00:18
MrBeast
Рет қаралды 118 МЛН
Ozoda - Lada ( Official Music Video 2024 )
06:07
Ozoda
Рет қаралды 16 МЛН
How do Cats Eat Watermelon? 🍉
00:21
One More
Рет қаралды 11 МЛН
The Best FREE Software for Game Development! (In my Opinion)
11:06
Creating SMART enemies from scratch! | Devlog
5:40
Challacade
Рет қаралды 332 М.
Godot 4: Enemy AI using Behavior Trees (BeeHave)
21:04
Taillight Games
Рет қаралды 7 М.
I Wish I Had Known This Before I Started Unity Game Development...
11:11
My Experience Moving to Godot from Unity
16:54
DarkDax
Рет қаралды 28 М.
Which AI Behavior Framework Should You Use? | AI Series 46
17:26
LlamAcademy
Рет қаралды 46 М.
Tierlisting the BEST (and worst) GAME ENGINES
33:51
BiteMe Games
Рет қаралды 227 М.
How to Add Interaction in Godot 4
16:48
Nagi
Рет қаралды 16 М.
Godot FPS Movement Tutorial - Wall Running
13:21
Garbaj
Рет қаралды 29 М.
Сняли домик блин🏠
23:19
Valera Ghosther
Рет қаралды 1,2 МЛН
skibidi toilet 77 (part 3)
4:51
DaFuq!?Boom!
Рет қаралды 21 МЛН