From f4b57a9456eb9df494b1413f71912cefa81eeed2 Mon Sep 17 00:00:00 2001 From: Andrew Conlin Date: Mon, 7 Jul 2025 12:38:27 +0100 Subject: [PATCH] [2025-07-07] Add curly brackets to mouse and input coordinates C# code --- tutorials/inputs/mouse_and_input_coordinates.rst | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tutorials/inputs/mouse_and_input_coordinates.rst b/tutorials/inputs/mouse_and_input_coordinates.rst index fd3be77ca..ba7fb5679 100644 --- a/tutorials/inputs/mouse_and_input_coordinates.rst +++ b/tutorials/inputs/mouse_and_input_coordinates.rst @@ -44,9 +44,13 @@ for example: { // Mouse in viewport coordinates. if (@event is InputEventMouseButton eventMouseButton) + { GD.Print("Mouse Click/Unclick at: ", eventMouseButton.Position); + } else if (@event is InputEventMouseMotion eventMouseMotion) + { GD.Print("Mouse Motion at: ", eventMouseMotion.Position); + } // Print the size of the viewport. GD.Print("Viewport Resolution is: ", GetViewport().GetVisibleRect().Size);