From 7f90c575a93d1acfcd0046e54414d29de9d12b4f Mon Sep 17 00:00:00 2001 From: Cat Flynn Date: Tue, 6 Dec 2022 19:56:45 +0000 Subject: [PATCH] Update input_examples.rst The C# `InputKeyEvent` doesn't have a `.KeyCode` property - it has `.ScanCode`. https://docs.godotengine.org/en/stable/classes/class_inputeventkey.html#class-inputeventkey --- tutorials/inputs/input_examples.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tutorials/inputs/input_examples.rst b/tutorials/inputs/input_examples.rst index 9a351573086..96972c14acf 100644 --- a/tutorials/inputs/input_examples.rst +++ b/tutorials/inputs/input_examples.rst @@ -203,7 +203,7 @@ the :kbd:`T`: { if (inputEvent is InputEventKey keyEvent && keyEvent.Pressed) { - if ((KeyList)keyEvent.Keycode == KeyList.T) + if ((KeyList)keyEvent.Scancode == KeyList.T) { GD.Print("T was pressed"); }