Hi! I believe you know how to code Skript, I just wanted you to see if any part of my code is incorrect as I have been trying to fix it and I just can't.
I'm trying to do code a CPS check, but I can get a really high number by breaking a ton of blocks(holding) in creative. Is it possible to get the actual cps of a player. Thanks(btw, i'm adding 1 to a CPS counter every time a player clicks)
Code:
else if arg-1 is "toggle":
if player has permission "anticheat.toggle":
if {%player's uuid%.anticheat.notifications} is true:
message "&aNoSkill notifications have been turned off"
set {%player's uuid%.anticheat.notifications} to false
else:
message "&aNoSkill notifications have been turned on"
set {%player's uuid%.anticheat.notifications} to true
else:
message "&cYou do not have permission to run this command"
else if arg-1 is "violation":
if arg-2 is "add":
if arg-3 is set:
if arg-4 is set:
if arg-5 is set:
if arg-6 is set:
set {_p} to arg-3 parsed as an offline player
set {_v} to arg-4 parsed as a number
set {_r} to arg-5
set {_c} to arg-6
set {_ex} to arg-7
set {_p.uuid} to {_p}'s uuid
if {_p}'s ping is more than 300:
add {_v} / 2 to {%{_p.uuid}%.anticheat.violations.%{_r}%}
else:
add {_v} to {%{_p.uuid}%.anticheat.violations.%{_r}%}
if {%{_p.uuid}%.anticheat.violations.%{_r}%} is more or the same as {anticheat.violations.%{_r}%.max}:
set {%{_p.uuid}%.anticheat.violations.%{_r}%} to 0
if {_p} doesn't have permission "anticheat.ban.bypass":
execute console command "/minecraft:ban %{_p}% &a[NoSkill]&r %{_r}%"
add "&4Ban&r: %{_r}% Check: %{_c}% Ping: %{_p}'s ping% TPS: %tps% Extra: %{_ex}%" to {%{p.uuid}%.anticheat::bans}
add 1 to {anticheat.bans}
else:
loop all players:
if {%loop-player's uuid%.anticheat.notifications} is true:
message "&b[NoSkill] %{_p}% was detected for %{_r}%" to loop-player
add "&6Warning&r: %{_r}% Check: %{_c}% Ping: %{_p}'s ping% TPS: %tps% Extra: %{_ex}%" to {%{p.uuid}%.anticheat::warnings}
else if arg-1 is "gui":
anticheatgui(player)
All this code is being flagged for expected 0 spaces, found (number)
When I asked what the reach is on MH, I was told 4.25 diagonal/3 horizontal. I know I'm an idiot, but does that mean your position to the player, or something else(horizontal and diagonal, not the reach). Thanks
Because some people like it
For GenPVP, MineResetLite, any type of shop that takes items(Shopkeeper is a common one), an anticheat plugin, and a ban plugin so you can ban people.
on death:
set {back.%player'a uuid%} to player's location
send "&bYour location has been set for /back"
command /back:
permission: skript.back
permission message: &cYou don't have permission!
trigger:
teleport player to {back.%player's uuid%}
Fixed