Difficulty in the Godot Docs, getting started, step by step guide?

I am having difficulty in the scripting section of the Godot Docs, getting started, step by step guide.

the task is to set up a button that changes some text within a label.
Simple enough I thought.

I was following the instructions, but when I went to run the script, I got an error.

this is and image of what I was told to write

this is what I wrote

after a bit of digging I found this in the search help for "connect()"

I noticed a couple of small differences with how it was written

one being the comma behind self, and the other being the quotation marks

when I retyped the code using this format it worked perfectly.

I guess that I am wondering if there is a mistake in the guide? If there has been an update in the code structure, and the guide has not been updated with it? Or if for some reason I just was not able to get the original code to work?

I am just getting started using Godot, and was a bit frustrated to be stuck with such a simple example.
I thought that if it is just a simple mistake maybe I could prevent it from happening again.

Comments

Leave a Comment

BoldItalicStrikethroughOrdered listUnordered list
Emoji
Image
Align leftAlign centerAlign rightToggle HTML viewToggle full pageToggle lights
Drop image/file