Solved Tabs/spaces

  • Welcome to skUnity!

    Welcome to skUnity! This is a forum where members of the Skript community can communicate and interact. Skript Resource Creators can post their Resources for all to see and use.

    If you haven't done so already, feel free to join our official Discord server to expand your level of interaction with the comminuty!

    Now, what are you waiting for? Join the community now!

  • LOOKING FOR A VERSION OF SKRIPT?

    You can always check out skUnity Downloads for downloads and any other information about Skript!

Status
Not open for further replies.

Donut

Well-Known Member
Mar 27, 2017
1,336
177
0
U.S.
Sometimes when I reload a script ill get an error saying "expected 4 spaces, but found 1 tab", so i make notepad++ replace tabs with spaces, then re-indent and everything works...

However, later on it will randomly say the opposite, "expected 1 tab but found 4 spaces", so I make notepad++ not replace tabs with spaces, re-indent and everything works... then later on it will yet again say "expected 4 spaces, but found 1 tab"...and so on. This cycle repeats and repeats.

This isn't related to a specific script but just scripts in general. There doesn't seem to be any pattern as to when it decides that it wants spaces and when it wants tabs. Is this a skript issue or a notepad++ issue? In either case, does anyone know what causes this or how to fix it?
 
Well, if it happens with the same script, that has been already correctly indented, then that may be an issue of your version of Skript rather than notepad++ itself, you could try other text editor like Sublime (which is 10 times better than notepad++) and see if you have the same issue.

Off-topic picture of the awesome-looking UI of Sublime Text with a custom theme (Enki - console syntax + Materialize Augmented Reaction theme).
2017-06-28_16-42-02.png
 
Well, if it happens with the same script, that has been already correctly indented, then that may be an issue of your version of Skript rather than notepad++ itself, you could try other text editor like Sublime (which is 10 times better than notepad++) and see if you have the same issue.

Off-topic picture of the awesome-looking UI of Sublime Text with a custom theme (Enki - console syntax + Materialize Augmented Reaction theme).
View attachment 919
Alright thanks, I'll try that editor.
[doublepost=1499478707,1499477886][/doublepost]Everything is working with sublime but as I said before, there doesn't seem to be any rhyme or reason to when I get the indentation error. I'll mark this as solved for now unless the error shows up again.

Thanks again for the sublime recommendation. I obviously haven't used it much yet, but what I have used so far is great.:emoji_slight_smile:
 
Alright thanks, I'll try that editor.
[doublepost=1499478707,1499477886][/doublepost]Everything is working with sublime but as I said before, there doesn't seem to be any rhyme or reason to when I get the indentation error. I'll mark this as solved for now unless the error shows up again.

Thanks again for the sublime recommendation. I obviously haven't used it much yet, but what I have used so far is great.:emoji_slight_smile:

I also get this error and this is what I've found out:

It happens when certain spaces are spaced and some are tabbed, meaning even if it has 5 spaces whether you use spaces or tabs, it needs to be consistent. If some things are spaced, then it needs to all be spaced, if some are tabbed, they all need to be tabbed.
 
I also get this error and this is what I've found out:

It happens when certain spaces are spaced and some are tabbed, meaning even if it has 5 spaces whether you use spaces or tabs, it needs to be consistent. If some things are spaced, then it needs to all be spaced, if some are tabbed, they all need to be tabbed.
Hmmm I thought I was always using all tabs/all spaces... probably notepad screwing something up.

Thanks for the info
 
Status
Not open for further replies.