Godot 4.0 Third Person Controller Tutorial ( 2023 )

Поділитися
Вставка
  • Опубліковано 7 лют 2025

КОМЕНТАРІ • 425

  • @o1497
    @o1497 Рік тому +384

    Pro tip: when importing models from blender, if you put -col at the end of the name of the models in blender, Godot will automatically add a collider for the model when you import it!

    • @lukky.
      @lukky.  Рік тому +57

      Oh cool I didn't know this. gonna play around with it, thanks for the tip!

    • @christiandelao2547
      @christiandelao2547 Рік тому +31

      ​@lukky. Can also do -vehicle to make it a vehicle body, and -wheel for the wheels, there's a few others too, also for animations -loop

    • @echoless3484
      @echoless3484 11 місяців тому +3

      Is this when I am naming the file when exporting it?

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

      @@echoless3484nop, Its on names objects from inspector scene

    • @NinjaDog4339
      @NinjaDog4339 10 місяців тому +2

      @echoless you make a object duplicate it name your last object but add a dash at the end then colony like this yourobjectname-colonly click on the colony hold shift click on the normal object select parent object make sure the normal object is the parent and the colony is the child open up the objects children then click on colonly hold shift then click on the object file, export, collada, selection only put it in your go godots blender file.

  • @da_cat
    @da_cat Рік тому +64

    Jesus ... i tried for a week to achieve this by trying to merge like 7 different tutorials from different people and different engine versions. This is absolutely perfect. Thank you so much 🥳

  • @voc007
    @voc007 Рік тому +68

    Thanks for the tutorial! You can add a springcamera3d to camera-mount, move, and child the camera3d to the springcamera3d, adjust the spring length to match your camera3d, and now you have object collision detection, so the camera3d does not go thru the objects.

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

      Learned something new, thanks!

    • @alexfrankenberger
      @alexfrankenberger 7 місяців тому +2

      @voc007: very cool. that was new for me. the name of the node is SpringArm3D in Godot 4.2.2

  • @gurglesprain
    @gurglesprain Рік тому +133

    If you get the error "Can't change loop mode on animation embedded in another scene.", I fixed this from the Animation window with "Animation" -> "Manage Animations..." -> Click the save icon -> "Make Unique"

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

      Works. You helped, at least one, real person.

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

      thank you, this helped

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

      The homie.

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

      Hi. Where did you click to get the "manage animations"? I fiddled around a bit but couldn't find that. I made the mixamo_base a scene, and then edited in that scene, which appears to be working.

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

      hey. More specifically at the top of the animation window, around the middle, hovering the mouse over it and "animation tools" comes up. Clicking on it, manage is between new and duplicate. I'm on 4.1.1 (if that affects anything. It's hard to tell sometimes.) @@owenlloyd2528

  • @Darkest-Kn1ght
    @Darkest-Kn1ght Рік тому +118

    @Lukky You stand out from the crowd of UA-camrs providing Godot tutorials because you explain the little things that most simply skip over, so you never know the reasons why things happen. Your tutorials, I dare say, educate those of us learning this game engine, in a way that we can take anything you show, and do what WE want to get done. I consider you among the top tier tutorial creators here. I'm looking forward to more videos from you in the future. Would you happen to post anything anywhere else on social media, such as Twitter? Would you happen to tinker around in Blender as well?

    • @lukky.
      @lukky.  Рік тому +24

      Thank you so much for the kind words 😊.
      Yes I'll post all my socials on me channel soon. ( Twitter is lukky_nl ). And yes I do use blender alot most of my games start as blender mockups actually :)

  • @albiceleste101
    @albiceleste101 Рік тому +50

    10:00 when adjusting the camera you can press ctrl+2 to divide the viewport in 2, so you have the camera preview opened
    then switch back with ctrl+1

  • @ryandese
    @ryandese 8 місяців тому +7

    Thanks for the tutorial! Simple and easy to follow.

  • @emberjaxx585
    @emberjaxx585 Рік тому +18

    If anyone is having trouble with the camera controller around the 23:00 minute mark, where there character stops looking in the direction your camera is facing while moving. It may be because instead of visuals.look_at(position + direction) should actually be visuals.look_at(global_position + direction). For me the position command was outputting an increasing value no matter where I walked rather then referencing the global position. You can reverse engineer this issue by using the print_debug(position) line which then will print the variable on the screen when running the game. Good luck guys! also great video man!

    • @deprecatedgames
      @deprecatedgames Рік тому +4

      Thanks! My player was walking slanted like some jive turkey.

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

      Thanks, fixed my issue.

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

      for some reason my character look to the reverse position when i go foward he look to back wtf

    • @jonas_epic_gamer
      @jonas_epic_gamer Місяць тому

      im still trying to fix this issue, and I've already tried this, but are there any other solutions?

    • @SaharNahari-m8k
      @SaharNahari-m8k 22 дні тому +3

      @@jonas_epic_gamer make sure to put your "visuals.look_at.." line inside the larger scope of the "if direction..", not the "if animation_player.." !

  • @GreasyOaf
    @GreasyOaf Рік тому +4

    more please, seriously how did you crunch my last 6 hours or so into the first five minutes x.x I wish I found you first!

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

    I wanted to learn how to set this all up on a controller while going through the tutorial, and god, was it a nightmare. However, I am proud that I figured it out.
    This 100% isn't the best way to do this but it's what I figured out and works if anyone else is interested. (make sure to add your right stick inputs to the controller map for lookleft/right/up/down.) This goes after the camera movement part and before the jump action part.
    func _process(delta):
    rotate_y(deg_to_rad(Input.get_action_raw_strength("lookleft")*controllersense_horizontal))
    rotate_y(deg_to_rad(-Input.get_action_raw_strength("lookright")*controllersense_horizontal))
    visuals.rotate_y(deg_to_rad(-Input.get_action_raw_strength("lookleft")*controllersense_horizontal))
    visuals.rotate_y(deg_to_rad(Input.get_action_raw_strength("lookright")*controllersense_horizontal))
    camera_mount.rotate_x(deg_to_rad(Input.get_action_raw_strength("lookup")*controllersense_vertical))
    camera_mount.rotate_x(deg_to_rad(-Input.get_action_raw_strength("lookdown")*controllersense_vertical))
    I know there is a better way using "Input.get_vector()" but I couldn't figure out how to do it so this is what my brain made.

  • @danford6678
    @danford6678 Рік тому +4

    I love your intro - "Hey, it's Lukky" Thanks for the lessons

  • @Jingleboy14
    @Jingleboy14 Рік тому +42

    Great tutorial! One addition that people might find useful is clamping the camera angle i.e. setting a max / min angle so you can't make the camera go upside down. At 16:00 add the following in line 20 (under the camera_mount.rotation.x):
    camera_mount.rotation.x = clamp(camera_mount.rotation.x, deg_to_rad(-90), deg_to_rad(45))
    (If you want you can set variables for CLAMP_MAX (-90) and CLAMP_MIN (45) and tweak them til you get what you want.)

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

    Definitely one of my favourite Godot UA-camrs out there! Always excellent quality

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

    A tutorial that empowers and has motivated me learn more.

    • @lukky.
      @lukky.  Рік тому +7

      The biggest complement, thanks you🙏

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

    I've watched a lot of videos recently trying to find a more updated tutorial mainly for changes in newer versions of Godot scripting etc, but have always found you to be the best at getting someone started!

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

    This was really helpful to get a good base to experiment with. Easy to follow, some potential pitfalls were explained well. Great tutorial!

  • @AidanRhoden3D
    @AidanRhoden3D 6 місяців тому +1

    Awesome! Super helpful and easy to understand; thank you!
    In the physics process, when checking if the kick button was just pressed, I'd add "and is_on_floor()" to prevent kicking mid-air.

    • @fratlock
      @fratlock 4 місяці тому +1

      Funny, I let it kick mid air for a jumping kick and had to allow move_and_slide so that gravity could take over. Then I slowed it down as it hit the floor again.

  • @hhw8508
    @hhw8508 Рік тому +8

    Hello, I am a friend in China, I am a newcomer to Godit, and I love Godot
    Your videos are great too! Godot is also popular in China! Especially after 4.0, every one of your videos is great and special! Hope to continue to produce great videos!

  • @luci.1308
    @luci.1308 2 місяці тому +7

    For all those who want visuals.look_at(position + direction) ore smoother, put this variable under the extends CharacterBody3D:
    const SMOOTH_SPEED = 10.0
    Also below var direction := (transform.basis * Vector3(input_dir.x, 0, input_dir.y)).normalized() this other variable:
    var visual_dir = Vector3(input_dir.x, 0, input_dir.y).normalized()
    And finally instead of visuals.look_at(position + direction) this:
    visuals.rotation.y = lerp_angle(visuals.rotation.y, atan2(-visual_dir.x, -visual_dir.z), delta * SMOOTH_SPEED)

    • @aidenaho
      @aidenaho Місяць тому

      You are amazing!

    • @TruckOperator49
      @TruckOperator49 Місяць тому

      thank you man i would have spent forever

    • @connorjade5460
      @connorjade5460 Місяць тому

      Dude this is holy bible. I couldn't explain how much this problem has plagued me. Thank you soo much. But can you explain what does visual_dir does?

    • @Seleneium7
      @Seleneium7 10 днів тому

      @@connorjade5460 Looks like visual_dir stores our input data (w,a,s,d) into a Vector3 var.
      Which we use in the lerp_angle() function to tell visuals.rotation.y where to lerp to.

    • @connorjade5460
      @connorjade5460 10 днів тому

      @@Seleneium7 Okay I actually wrote the code which controls the player. That's why this line is not doing anything in my scene.

  • @BesideTheVoid
    @BesideTheVoid 28 днів тому +1

    So easy! Most tutorials use the AnimationNodeStateMachinePlayback or make their own multi state machine. Just set Default Blend Time and play the animation! THANKS

  • @Kingofther3gion
    @Kingofther3gion Рік тому +8

    Thanks for the tutorial. I have a problem with the character getting tilted when I start moving at like 45 degrees. It happened after I wrote "visuals.look_at(position + direction)".
    Edit: I found this in the comment section "visuals.rotation.y = lerp_angle(visuals.rotation.y,position.angle_to(position+direction),delta*rotation_speed)" wich is an alternative to the first line of code allowing for smooth rotation, it also fixed my initial problem. If anyone has the same problem use this instead, just declare a new "var rotation_speed = 10" at the top and it worked fine.

    • @KaranMeena-s5z
      @KaranMeena-s5z 11 місяців тому +1

      Visual position xyz 0 in inspector window

  • @zonnawolfy5794
    @zonnawolfy5794 4 місяці тому +1

    Man the background is such a vibee!

  • @BluePhoenixGames1
    @BluePhoenixGames1 23 дні тому +1

    great getting started tutorial!

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

    im so happy i found ur channel, u actually go through theses things in such nice detail, and i also love the slower tone of the videos. Thank u so much

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

    @Lukky thank you so much! This helped me a lot! I love the way you are explaining everything in detail.

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

    Thank you! This video moved me forward in my gamedev progress more than any of the tutorials I have watched on YT or paid for at other sources. Since I am an old man just entering gamedev at retirement (Dark Souls inspired gamer, sadly only discovering this art when Elden Ring was released), I have been trying to learn a lot of skills from drawing to coding, music, to modeling - so fun! I have not coded anything since my Fortran and Cobol days, (Pacal, C, Basic, etc...) and I sure wish there was a reference book for gdscript as opposed to the online documents, but my brain is finally starting to rewire for art and coding, despite my preferred learning method of books. With this little 3d controller tutorial I have been able to craft my real-world farm into godot with an adequate animated character model of myself. I decided that modeling my farm and working the farm with a 3d character would be a great way to learn gamedev fundamentals before venturing further. Oh, like a real fool, I modeled the terrain and building in Blender so that I could port them to both Ureal5 and godot to see which I prefer. Doing this made my head spin. I am sticking with godot for now, despite Unreal5 being much easier to set up the base farm and character, but I like coding, challenges and the small package of godot without the ridiculous delays and crashes of Unreal.
    Apologies for the long-winded comment but I am feeling more inspired and capable simply because of your excellent tutorial video.

    • @superrobo999
      @superrobo999 Місяць тому

      Good luck with your game friend, sounds like you're making great progress so far, gamedev is really hard but it's worth sticking with it. Best wishes

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

    Really appreciate how you go slow and explain your process. 100%

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

    I stumbled across your videos by accident - fantastic! on UA-cam, everyone is yelling and chattering so much in their videos. Starting to watch your videos at first I experienced an unusual sensation in my ears - as if I suddenly teleporting from a loud, noisy metropolis to the mountains, to calming nature. Your videos are just some educational ASMR. And most importantly, useful knowledge as a result. Please keep going 🙏! It's great. Huge respect for your work, man! Thank you.

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

    Great tutorial~! Only issue I've had is that the player character doesn't stop moving even when kicking, but other than that it works great~!

  • @xd7052
    @xd7052 Рік тому +9

    for those who don't know how to move all locally created mixamo animations just use the model and skeleton from one of those nodes and in the animation player nodes of the other scenes just copy and paste it to the animation player node of your preference (it has to be only one) entering manage animations there you paste it by touching the portfolios, if it doesn't even let you copy it you have to save the scene with (ctrl+s) there it lets you do that, I'll let you know don't know much because I spent a whole day looking for how to do that and in the end I discovered it
    para los que no sepan cómo se mueve todas las animaciones de mixamo creadas localmente solo tienen que usar el modelo y el esqueleto de uno de esos nodos y en los nodos de animation player de las demás escenas solo tienen que copiarlo y pegarlo al nodo animation player de su preferencia (tiene que ser uno solo) entrando en manage animations ahí lo pegan tocando en el portafolios, si no les deja ni copiarlo tienen que guardar la escena con (ctrl+s) ahí les deja hacer eso, les aviso a los que no sepan mucho porque estuve un día entero buscando como hacer eso y al final lo descubrí yo

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

      I spent 2 days trying to figure this one out and stumbled upon this afterI finally fixed it.

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

    This is exactly what I wanted to learn and you are very easy to understand and follow. Thank you!

  • @SunJaycy
    @SunJaycy 21 день тому +1

    for a smoother character turn, instead of using look_at delete that and use this instead
    visuals.rotation.y = lerp_angle(visuals.rotation.y, atan2(direction.x, direction.z), delta * 8.0)

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

    Thx you very much, not only i have learned how to set up 3rd person camera ( which was point of watching this video at first ) but also how to add animations , running and transitions.👍

  • @a.mikecampbell
    @a.mikecampbell 3 місяці тому

    I'm back to this tutorial for like the 5th time. Every time I start a new project, I come back ❤

    • @orwinsen4510
      @orwinsen4510 3 місяці тому

      so you never learn anithing

    • @a.mikecampbell
      @a.mikecampbell 3 місяці тому +2

      I learn something new each time. By revisiting the math, composition, and each time with an updated understanding of the “why” from my progress outside the tutorial, I get better. And if nothing else, Lukky is ASMR. You’re just being an ass.

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

    How do you not have more subs? This is the best simple no nonsense tutorial i've seen that's actually useful.

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

    Simple, and great
    thanks for this tutorial and please keep post more about godot 3d!

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

    Greta video. Thanks a lot. I'm gonna need this for remaking my unity game into Godot. Thanks! Didn't know Godot was SO MUCH SIMPLER than unity. Your explanation was on point. Thanks a lot!

  • @TheStickmahn
    @TheStickmahn Рік тому +39

    *If you don't want the visuals to snap to the directions, add these two lines of code instead of the tutorial code:*
    In _INPUT() add: visuals.rotate_y(deg_to_rad(event.relative.x*PUTSENSITIVITYHERE #

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

      Thanks a lot, I was mucking around with Asin and Atan2 for an hour earlier trying to get that done.

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

      No problem, me too tbh 0_0@@TheLastPhoen1x

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

      your a life saver

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

      no problem@@dareokoski8158

    • @yarop1794
      @yarop1794 Рік тому +4

      Thank you; had to change to atan2(-input_dir.x, -input_dir.y) for some reason.

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

    by far the best Godot tutorial out there, by far!!

  • @Shubham-yc6nz
    @Shubham-yc6nz Рік тому +3

    This video was amazing 🤩🤩

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

    This is gold man, much appreciated!

  • @JoJo_mjt
    @JoJo_mjt 25 днів тому +1

    thank you and may the gods of he outer world spare you soul and welcome you as a disciple

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

    Thanks for the guide, very well made. Please keep it up!

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

    This video was very informative.
    I'd love more exploration on melee combat for third person. I'd love to build something akin to Fable/Kingdom of Almar/etc. ARPG basically, but not sure how to approach things like skill-set moves that do more than swing a sword. Such as teleportation, speed-dashes, dodge rolls.
    Any continuation on this tutorial for action combat would be super useful.
    Thanks for the tutorials.

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

    @Lukky, wow! This is one of the best tutorials I have found, especially related to Godot. Looking forward to the next ones! Anything related to 3d games is great :D *It would be awesome to see how you set up the jumping animation with this style. It can be quite confusing to new people how to add extra animations with different requirements.

  • @ElGabroVero
    @ElGabroVero 4 місяці тому

    Very good tutorial!
    Dont forget guys: if the complexity of the character grows, try to implement a proper design pattern like state machine! Anyway, is an excellent starting point! Thx Lukky

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

    love the vid, thanks for the lesson!
    Could give you a quick optimizing and code cleaning tip
    for the walk/run segment I found it better to make a dictionnary and a flag variable to handle the entire process (I made it a walk run toggle but if you make the flag true only when shift is held down, the result is the same). This could be a good way to teach how to use dictionnaries
    #Replace the speed values with whatever fits better for you
    const MOVEMENTS = [
    { "animation": "walking", "speed": 1.725 },
    { "animation": "running", "speed": 3.0 }
    ]
    var toggleRun = false
    in the physics process:
    #you can change the if with your hold key version
    if Input.is_action_just_pressed("toggleRun"):
    toggleRun = !toggleRun
    ...
    if direction:
    if animation_player.current_animation != MOVEMENTS[int(toggleRun)]["animation"]:
    animation_player.play(MOVEMENTS[int(toggleRun)]["animation"])
    visuals.look_at(position + direction)
    velocity.x = direction.x * MOVEMENTS[int(toggleRun)]["speed"]
    velocity.z = direction.z * MOVEMENTS[int(toggleRun)]["speed"]
    else:
    if animation_player.current_animation != "idle":
    animation_player.play("idle")
    velocity.x = move_toward(velocity.x, 0, MOVEMENTS[int(toggleRun)]["speed"])
    velocity.z = move_toward(velocity.z, 0, MOVEMENTS[int(toggleRun)]["speed"])

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

    Thanks a lot!!! you helped me a lot with mixing animations!!!

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

    What a great tutorial ! Love it.

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

    this is what I was looking for .. big thanks :)

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

    God Bless you for teaching GODOT brother!

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

    great tutorial thank you!

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

    Life saver thank you man this helps so much

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

    I really appreciate this. Thank you

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

    There is a jitter/shake when colliding with the boxes. That's because the floor is too wide causing imprecision in the physics engine. We have to subdivide the floor in smaller pieces or use WordBoundaryShape instead.

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

      A quick fix is to switch the collision shape to a capsule but it will still jitter once in a while.

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

    love your videos, thanks for sharing

  •  Рік тому

    thanks for tutorial, awesome like!

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

    Verry good tut and resource thank you buddy!

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

    This is top notch! Thank you!!!

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

    Great video. Keep Up!!

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

    I thuroughjly enjoyed this tutorial :D I would like to see other tips and tricks for setting up 3rd person controls such as removing walking / running animation loop while in jump. but this solves 99% of what most beginners have to setup first. Anyways, keep up the excellent work! will be subscribing RN

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

    phenomenal work!

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

    seen image-line and i subbed

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

    I tell everyone Lukky makes the best & most understandable videos. And this is the fcked independent opinion))

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

    liked and subscribed. Keep up the good work plz.

  • @Adamthegeek70
    @Adamthegeek70 3 місяці тому

    I like this alot thank you!.

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

    You earned the sub & like mate. Cheers

  • @gawni1612
    @gawni1612 20 днів тому +1

    unintentional ASMR

  • @cmcdonough2
    @cmcdonough2 4 місяці тому

    Great tutorial thanks.

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

    Thank You for this very helpful information I could have died if this video was not made

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

    Amazing tutorial and nice voice :)

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

    Be great to se the FPS and Third controller merged into one tutorial where the player can swiitch the cameras and maybe a FREE camera where they can explore the world up until a certain distance away

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

    This is amazing man, thank you. Do you have any plans to expand this to more advanced 3rd person movement like jumping/climbing/fighting etc?

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

    Oh my god. I found just golden bubble of godot content, i hope godot will become next blender for game industry. Open source rules🤟

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

    I know, late comment, but I'd love to see a tutorial on how to add collision detection (hit/hurt box?) to the kick, so kicking a "target" would knock it back/over, and kicking a wall would maybe knock the player back or interrupt the animation.

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

    The easiest godot 4 tutorial i have seen so far explained everything as it is meant to be thank you so much @Lukky

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

    Thank you. This help me a lot 👍

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

    great tutorial mate!

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

    That damn wallpaper, gets me everytime

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

    @Lukky Thank you so much for this tutorial, it is a great addition to the community's array of learning resources. I have a special request, seeing you're aware of the Gears of War series - would you be willing to do a tutorial in Godot on how to create a Cover System similar to that seen in Gears?

  • @Josh-op6dl
    @Josh-op6dl Рік тому +2

    If you kick in the middle of the air you stay floating in the air, and this occurs because the "move_and_slide" also affects the player's gravity.
    I fixed this removing the "if !is_locked" from the "move_and_slide()" and adding in the "_physics_process(delta)" this line of code:
    if is_locked:
    walking_speed = 0.0
    running_speed = 0.0
    JUMP_VELOCITY = 0.0
    else:
    walking_speed = 3.0
    running_speed = 5.0
    JUMP_VELOCITY = 4.5
    If anyone knows a better solution please comment.

    • @SubdEUC
      @SubdEUC Місяць тому

      if not is_on_floor():
      velocity += get_gravity() * delta
      move_and_slide()

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

    32:05 - To contribute a bit, instead of the if !animation_player.is_playing(): unlocking fix, I did an "await" coroutine on the kick function. It goes....
    animation_play("kick")
    locked = true
    await get_tree().create_timer(1.5).timeout
    locked = false
    ....which, to me, seems a bit more un-glitchable (perhaps debate-ably compared to a dedicated timer and/or state machine but this way fulfills one thing at a time principles).

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

    Holy @$@#$! thanks. This is so helpful. Please continue making these tutorials, always useful. Maybe you could do one for gamepad controls?

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

    if you want to stop the camera clipping inside things add a springarm3d as a child to the camera_mount node. then add the camera as a child of the springarm3d node. then set a distance on the springarm3d node.

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

    This was awesome

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

    very helpful thank you

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

    Great tutorial!

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

    Pro-tip, for "source engine" sensitivity standards, the number of degrees you turn per mouse dot is 0.022 by default.
    There's no agreed standard for this, but this is as close as you're going to get to a standard.
    e.g.:
    # standard source engine metrics
    var degrees_per_mouse_dot = 0.022
    @export var mouse_sensitivity_x = 3
    @export var mouse_sensitivity_y = 3
    @export var mouse_invert_y = false
    @export var mouse_invert_x = false
    func _input(event):
    if( event is InputEventMouseMotion ):
    var invertX = -1 if mouse_invert_x else 1
    var invertY = -1 if mouse_invert_y else 1
    rotate_y( deg_to_rad( -event.relative.x * mouse_sensitivity_x * degrees_per_mouse_dot * invertX ) )
    camera_mount.rotate_x( deg_to_rad( - event.relative.y * mouse_sensitivity_y * degrees_per_mouse_dot * invertY ) )

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

    Thanks 👍 100% working

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

    Best tutorial yet

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

    Plz make a shotgun tutorial with the 4.0 stable tutorial you did.

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

    thanks so much dude!!

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

    This tutorial was exactly what I'm looking for, thanks for making it. Also, do you have any videos covering that shooter project you showed at the end?

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

    If anyone else had a problem where "Default blend time" was giving weird lag to animations, I fixed it by enabling "animation Looping" in the bottom right of the player when selecting the animation player

  • @sumibanerjee7801
    @sumibanerjee7801 Рік тому +4

    Love ur content bro
    Just one question
    How do you fit all the animation in one base?
    I tried a lot but I can't do it
    (I can download all the animations seperately though)
    Again,love ur content❤❤❤

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

    melhor tutorial, bom trabalho

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

    Beautiful code. And effective

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

    Awesome, can you show us the 3rd person project you are working on?

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

    This is kind of old, so maybe you've done some of this already and I just couldn't find it, but seeing how you add the hit box to the leg when your kicking would be nice!

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

    22:23 the character keeps looking ar randome-weird angles isntead of toward the direction she is walking-