ClearLag skript doesn't work

  • 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.

UltiDK

New Member
Feb 10, 2017
9
0
0
28
Skript Version: 2.2
Skript Author: Me
Minecraft Version: 1.8.9

---
Full Code:


code_language.skript:
command /clearlag:
    permission: clearlag.use
    trigger:
        clear {_count}
        loop entities:
            loop-entity is a dropped item
            clear loop-entity
            add 1 to {_count}
        if {_count} is not set:
            set {_count} to 0
            message "&0[&2&lCrushyPvP&0] &2Clearlag startet!"
            wait 1 tick
            message "&0[&2&lCrushyPvP&0] &2Clearlag færdig! &8- &a%{_count}% &2entities blev fjernet!"

           
every 9 minutes:
    broadcast "&0[&2&lClearlag&0] &2Fjerner alle items på jorden om &a50 &2sekunder&2!"
    wait 40 seconds
    broadcast "&0[&2&lClearlag&0] &2Fjerner alle items på jorden om &a10&2 sekunder!" 
    wait 10 seconds
    make console execute command "/clearlag"
    broadcast "&0[&2&lClearlag&0] &2Fjernede &a%{_count}%&2 entities!"
   
   
   
   
command /cc:
    aliases: clearchat
    permission: staff.cc
    permission message: &4Du har ikke adgang til den kommando!
    trigger:
        loop 100 times:
            broadcast ""
        broadcast "&2-+-------------------------------+-"
        broadcast "&aChatten blev clearet!"
        broadcast "&2-+-------------------------------+-"

Errors on Reload:

code_language.skript:
[07:01:46 INFO]: [Skript] Reloading ClearLag.sk...
[07:01:46 ERROR]: indentation error: expected 12 spaces, but found 3 tabs (ClearLag.sk, line 11: message "&0[&2&lCrushyPvP&0] &2Clearlag startet!"')
[07:01:46 ERROR]: indentation error: expected 12 spaces, but found 3 tabs (ClearLag.sk, line 12: wait 1 tick')
[07:01:46 ERROR]: indentation error: expected 12 spaces, but found 3 tabs (ClearLag.sk, line 13: message "&0[&2&lCrushyPvP&0] &2Clearlag færdig! &8- &a%{_count}% &2entities blev fjernet!"')
[07:01:46 ERROR]: indentation error: expected 4 spaces, but found 1 tab (ClearLag.sk, line 22: broadcast "&0[&2&lClearlag&0] &2Fjernede &a%{_count}%&2 entities!"')
[07:01:46 INFO]: [Skript] Encountered 4 errors while reloading ClearLag.sk!

Console Errors: (if applicable)

code_language.skript:
ERROR HERE

Other Useful Info: Nothing.

Addons: Umbaska, SkRayFall, skQuery
ADDONS HERE

Troubleshooting:

Have you tried searching the docs? No
Have you tried searching the forums? No
What other methods have you tried to fix it?
 
So in skript you can use tabs or spaces for indentation, but you can't mix them together, the majority use tabs but when you copy and paste code from a website such as this one and you paste it into your text editor it detects the tabs as spaces. Basically you have to go through your script and make sure they are all tabs, its a huge pain in the ass and its been happening to me alot lately
 
So in skript you can use tabs or spaces for indentation, but you can't mix them together, the majority use tabs but when you copy and paste code from a website such as this one and you paste it into your text editor it detects the tabs as spaces. Basically you have to go through your script and make sure they are all tabs, its a huge pain in the ass and its been happening to me alot lately
So that meens, that if i use a host, and use Notepad++ to create my scripts, then i can't copy + paste it into the file manager on the website?
At my hosts text editor i can't use tab.
 
I'm glad that you're trying to help but spoonfeed the people won't help in any way and MartinOdum already explained well the problem.


You shouldn't have this problem if you copy them correctly.
i tend to have this problem in atom but i can usually use the space to tab addon to fix it, but i am curious. What is the correct way of copying it?
 
Status
Not open for further replies.