GDQuest / learn-gdscript

Learn Godot's GDScript programming language from zero, right in your browser, for free.
https://gdquest.github.io/learn-gdscript/
Other
2.05k stars 150 forks source link

Selecting and indenting lines of code then running the code may cause an error? #917

Open NathanLovato opened 7 months ago

NathanLovato commented 7 months ago

A user reported this problem by email:

In the Learn GDScript app, in the draw_three_squares practice problem, I first put

draw_square()
jump(300, 300)
draw_square()
jump(300, 300)
draw_square()

without indentation. Then I noticed that I was supposed to write a function, so I put func draw_three_squares(): in the line above. Then I selected the 5 lines drawing the squares and pressed Tab to indent them. Upon running this, I got an error about draw_s being an unknown function. The error disappeared when I selected all the indented lines, and pressed Ctrl X Ctrl V.