Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- on join:
- set {AntiCheat::%player%::alerte::*} to 0
- set {AntiCheat::%player%::vl.FlyA} to 0
- command /AntiCheat [<text>]:
- aliases: ac
- trigger:
- if arg-1 is "alerte" or "alertes":
- if {AntiCheat::staff::alerte::*} contains player:
- remove player from {AntiCheat::staff::alerte::*}
- send "&8[&c!&8] &7Mode alerte: &cdésactivé" to player
- stop
- else:
- add player to {AntiCheat::staff::alerte::*}
- send "&8[&c!&8] &7Mode alerte: &aactivé" to player
- stop
- on anymove:
- if player's gamemode isn't adventure or survival:
- stop
- if player's flight mode is true:
- stop
- set {_p1} to location 0.5 west 0.5 south of 0.65 below player
- set {_p2} to location 0.5 east 0.5 north of player's location
- loop blocks within {_p1} to {_p2}:
- if loop-block isn't air:
- set {AntiCheat::%player%::is.in.Air} to false
- exit loop
- else:
- set {AntiCheat::%player%::is.in.Air} to true
- set {_YDiff} to y-location of player - {AntiCheat::%player%::last.y}
- #send "&fState: &7%{AntiCheat::%player%::is.in.Air}% &8; &fYDiff: &7%{_YDiff}% &8; &fLastYDiff: &7%{AntiCheat::%player%::last.diffy}%" to player
- if {AntiCheat::%player%::is.in.Air} is true:
- if "%{_YDiff}%" = "%{AntiCheat::%player%::last.diffy}%": # Je les ai mit en texte pour éviter des erreurs
- add 1 to {AntiCheat::%player%::vl.FlyA}
- if {AntiCheat::%player%::vl.FlyA} >= 2:
- Alerte(player, "Fly (A)", "&fState: &7%{AntiCheat::%player%::is.in.Air}% &8; &fYDiff: &7%{_YDiff}% &8; &fLastYDiff: &7%{AntiCheat::%player%::last.diffy}%")
- else:
- if {AntiCheat::%player%::vl.FlyA} >= 0.2:
- remove 0.2 from {AntiCheat::%player%::vl.FlyA}
- else:
- if {AntiCheat::%player%::vl.FlyA} >= 0.5:
- remove 0.5 from {AntiCheat::%player%::vl.FlyA}
- set {AntiCheat::%player%::last.diffy} to {_YDiff}
- set {AntiCheat::%player%::last.y} to y-location of player
- #━━━━━━━━━━━━━━━━━━━━━━ Alerte ━━━━━━━━━━━━━━━━━━━━━━#
- function Alerte(p: player, cheat: text, info: text):
- add 1 to {AntiCheat::%{_p}%::alerte::%{_cheat}%}
- send "&8[&c!&8] &f%{_p}% &7utilise un &f%{_cheat}% &c(%{AntiCheat::%{_p}%::alerte::%{_cheat}%}%) &8[%{_info}%&8]" to {AntiCheat::staff::alerte::*}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement