TechLover3000 Posted May 9, 2021 Share Posted May 9, 2021 I have been trying to make a Minehut server which has a PvP arena, so currently I am trying to make sure no one can grief any of the blocks. Here's a sample Skript code that I am using as the non grief code (I replace the '(item name)' with the name of the item, e.g. spruce planks): on break of (item name): if player's gamemode is survival: send "&c&lHey!&r You can't break that block there!" to player cancel event Recently I ran into a problem with this code with dark oak signs (as seen in the video at the bottom). Basically, it only cancels the event if the sign is at a certain orientation, i.e. it will not cancel the event if the sign is on a wall. I have been using the code below to make it so that people cannot grief the signs and this code works for other items (if you replace 'dark oak signs' with the item name, plural) such as spruce planks, spruce logs and spruce leaves. on break of dark oak signs: if player's gamemode is survival: send "&c&lHey!&r You can't break that block there!" to player cancel event I am pretty sure the problem with some of the signs not cancelling the event is the fact the some of them are on walls, and some are not. Also, is there a piece of Skript code which disables PvP? Thanks! TechLover3000 skript signs not working.mp4 Link to comment Share on other sites More sharing options...
BanditEagle Posted May 9, 2021 Share Posted May 9, 2021 The orientation of a block shouldn't matter when it is being checked to see if it is broken. Can you try to place a sign on the wall in survival and try to break it in survival, and see what that does? If I have helped you out in your post or you liked what I posted, please upvote and react to my post! It helps me a lot! Some Minehut Links: Server Rules • Staff Applications • News & Updates • Reports • Appeals Minehut: VIP (07/04/2021 --> Current)Elestra/Versa Realms: Manager (12/04/2021 --> Current) If you have any questions contact me!My Discord: BanditEagle#2481My Spigot Profile: https://www.spigotmc.org/members/banditeagle.935281/My IGN: BanditEagle Link to comment Share on other sites More sharing options...
Pocan Posted May 12, 2021 Share Posted May 12, 2021 You can create a variable and check if it's set or not on break: if {antigrief::%uuid of player%} is set: cancel event Link to comment Share on other sites More sharing options...
ChunkerDunkers Posted May 14, 2021 Share Posted May 14, 2021 Maybe try to add a world to your skript. As Pocan said, variables also work. Hello, I'm Nolan! Cool Links Vote Please - bit.ly/3tMXajE MC Server - bit.ly/3hqYAOy Please leave a like if I helped! 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