0 votes

i am working on making a save code using
this tutorial
and each time i attempt to use the

return save_dict

part, it says "Mixed tabs and spaces in indentation."
please help

Godot version 3.2
in Engine by (20 points)

1 Answer

0 votes

GDScript uses indentation. So after a function all code is indented by one tab. In the editor godot uses tabs for indentation.
But you have copied code from somewhere where spaces where used instead of tabs. (For example this Q&A)

But in my editor (3.2.3) when using spaces it autoconverts them to tabs on saving. But only with 4 spaces in a row. So mabe there are only 3 in your case or it is a setting which I enabled. The best salution is yust to delete all indentation of copied code an reindent it with tabs.

by (291 points)
Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read How to use this Q&A? before posting your first questions.
Social login is currently unavailable. If you've previously logged in with a Facebook or GitHub account, use the I forgot my password link in the login box to set a password for your account. If you still can't access your account, send an email to webmaster@godotengine.org with your username.