From 85e4a83e75721f8d38fd80c2f99383748acdc7b7 Mon Sep 17 00:00:00 2001 From: Pixdigit Date: Tue, 25 Apr 2023 22:41:36 +0200 Subject: [PATCH 1/2] Replace legacy setget in tool tutorial Replace reference to legacy setget keyword and replace it with the new setter style in the "Running Code in the Editor" tutorial. --- tutorials/plugins/running_code_in_the_editor.rst | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/tutorials/plugins/running_code_in_the_editor.rst b/tutorials/plugins/running_code_in_the_editor.rst index 4285afb96ce..7a48663bdb9 100644 --- a/tutorials/plugins/running_code_in_the_editor.rst +++ b/tutorials/plugins/running_code_in_the_editor.rst @@ -180,8 +180,7 @@ run the game, it will spin counter-clockwise. Editing variables ----------------- -Add and export a variable speed to the script. The function set_speed after -``setget`` is executed with your input to change the variable. Modify +Add and export a variable speed to the script. To update the speed and also reset the rotation angle add a setter ``set(new_speed)`` which is executed with the input from the inspector. Modify ``_process()`` to include the rotation speed. .. tabs:: From 6ec1b84a23da77f6424c60ba90a4766b828d239b Mon Sep 17 00:00:00 2001 From: Yuri Sizov <11782833+YuriSizov@users.noreply.github.com> Date: Wed, 26 Apr 2023 11:24:23 +0300 Subject: [PATCH 2/2] Apply code review suggestion --- tutorials/plugins/running_code_in_the_editor.rst | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tutorials/plugins/running_code_in_the_editor.rst b/tutorials/plugins/running_code_in_the_editor.rst index 7a48663bdb9..cd762e1765c 100644 --- a/tutorials/plugins/running_code_in_the_editor.rst +++ b/tutorials/plugins/running_code_in_the_editor.rst @@ -180,7 +180,8 @@ run the game, it will spin counter-clockwise. Editing variables ----------------- -Add and export a variable speed to the script. To update the speed and also reset the rotation angle add a setter ``set(new_speed)`` which is executed with the input from the inspector. Modify +Add and export a variable speed to the script. To update the speed and also reset the rotation +angle add a setter ``set(new_speed)`` which is executed with the input from the inspector. Modify ``_process()`` to include the rotation speed. .. tabs::