I'm not the best at skript and I don't entirely know what's going wrong, I just want a ClearLag skript with a Toggle and a manual thing where if you do the command it clears everything after like 10 seconds.
Here's the skript:
variables:
{clearlag.%player%} = "False"
command /clearlag on:
aliases: /cl on
permission: op
permission message: &cYou cannot execute this command!
trigger:
if {clearlag.%player%} is "False":
send player message "ClearLag turned on"
set {clearlag.%player%} to "True"
command /clearlag off:
aliases: /cl off
permission: op
permission message: &cYou cannot execute this command!
trigger:
if {clearlag.%player%} is "True":
send player message "ClearLag turned off"
set {clearlag.%player%} to "False"
command /clearlag manual:
aliases: /cl manual
permission: op
permission message: &cYou cannot execute this command!
trigger:
broadcast "Clearing dropped items in 10 seconds."
wait 5 seconds
broadcast "Clearing dropped items in 5 seconds."
wait 5 seconds
broadcast "Killed %size of dropped items% dropped items."
kill dropped items
If {clearlag.%player%} is "True":
every 10 minutes:
broadcast "Clearing dropped items in 10 seconds."
wait 5 seconds
broadcast "Clearing dropped items in 5 seconds."
wait 5 seconds
broadcast "Killed %size of dropped items% dropped items."
kill dropped items
Here's the skript:
variables:
{clearlag.%player%} = "False"
command /clearlag on:
aliases: /cl on
permission: op
permission message: &cYou cannot execute this command!
trigger:
if {clearlag.%player%} is "False":
send player message "ClearLag turned on"
set {clearlag.%player%} to "True"
command /clearlag off:
aliases: /cl off
permission: op
permission message: &cYou cannot execute this command!
trigger:
if {clearlag.%player%} is "True":
send player message "ClearLag turned off"
set {clearlag.%player%} to "False"
command /clearlag manual:
aliases: /cl manual
permission: op
permission message: &cYou cannot execute this command!
trigger:
broadcast "Clearing dropped items in 10 seconds."
wait 5 seconds
broadcast "Clearing dropped items in 5 seconds."
wait 5 seconds
broadcast "Killed %size of dropped items% dropped items."
kill dropped items
If {clearlag.%player%} is "True":
every 10 minutes:
broadcast "Clearing dropped items in 10 seconds."
wait 5 seconds
broadcast "Clearing dropped items in 5 seconds."
wait 5 seconds
broadcast "Killed %size of dropped items% dropped items."
kill dropped items