seamzers Posted February 5, 2023 Share Posted February 5, 2023 so basically im trying to make a skript where if the player hasnt moved from when the block they were at when they joined then they cant chat. heres my current code: #this is just a anti-spam that it uses on chat: if {%player%::message} isn't set: set {%player%::message} to false if {%player%::message} is false: wait 2 ticks set {%player%::message} to true wait 2 seconds set {%player%::message} to false on chat: if {%player%::message} is true: cancel event send "&cPlease Wait 2 Seconds Until You Chat Again" to player #this is the skript not working ↓↓↓↓↓↓↓ on join: if player's location is x10722, y137, z9628: set {%player%::message} to false the error message i get is: Link to comment Share on other sites More sharing options...
iamsif Posted February 7, 2023 Share Posted February 7, 2023 (edited) Your code is very messy, try this (not tested) on chat: if {playersjoinlocation::%player's uuid%} is player's location: send "&cMove before chatting!" else: delete {playersjoinlocation::%player's uuid%} on join: set {playersjoinlocation::%player's uuid%} to player's location on quit: delete {playersjoinlocation::%player's uuid%} Edited February 7, 2023 by iamsif Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now