Godot: Input handling

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

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

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

    I also want to mention, you can use something like `event.is_action_pressed("inventory")` inside of these methods.

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

      That's what I was wondering since it seems more flexible to do it that way.

  • @idk-g5o4q
    @idk-g5o4q 3 года назад +16

    "what up nerds" 1 second in and I'm laughing my ass off

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

      Idk why but it's the greatest intro to a tutorial i've ever witnessed

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

      reminds me of Technoblade. #TechnobladeNeverDies

  • @Fredricon
    @Fredricon Год назад +8

    The get_tree().set_input_as_handled() method has changed to get_viewport().set_input_as_handled() in Godot 4.0. FYI.

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

    Thanks for the breakdown. Make sure to share on fb and reddit.

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

    thank you sooooo much !! best explaination on these input functions !!!

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

    Ah! I'm 4 minutes in and learning a lot!

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

    Hey! Nice summary. Would it be fair to say the Input singleton gets updated first then these fire? Is there performance gains in marking events handled earlier (or if only using the Input method)?

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

      No, it would not be fair to say that. And any performance gains that you would find would be so minuscule that you would would really be trying to squeeze things - which at that point, I'd say you should be looking elsewhere.

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

      @@duroxxigar Awesome - thanks for confirming! Always interesting to hear how inner workings work

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

    How did you comment the block of code? (5:42)

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

      Ctrl + K by default

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

      @@duroxxigar thx

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

    Nice video! In which order are the viewports handled? Is this also bottom to top?

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

      Yea, it'll still be bottom to top. Remember, you have the root viewport which will receive the input first. It will then go to the bottom most node and start going up the tree.

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

    Great video 🔥

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

    how to do a key swap in godot

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

    Thanks, its very helpfull

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

    thank you, this video helped me understand better. although it hurts me internally that you pronounce "gui" as "gooey"

    • @luke-phi
      @luke-phi 4 месяца назад

      How do you pronounce it? I only ever hear or say gooey

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

    You don't have to be so nervous🤗

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

    wow, never knew that

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

    yes