Cancel-block-break script

General discussion of Denizen-Bukkit, or even just Bukkit.
Post Reply
GloatyMadn
New
New
Posts: 1
Joined: March 11th, 2020, 12:52 pm

Cancel-block-break script

Post by GloatyMadn » March 31st, 2020, 6:49 am

Hello.
Please help,how make a cancel block-break script if player break blocks with a "§eExplosion pickaxe"
But if the player has permission item.explosionpickaxe he can use it.

I tried to search for instructions on how to write a script for denizen on version 1.12.2, but I didn't find anything, so I had to write topic here.

User avatar
mcmonkey
Site Admin
Site Admin
Posts: 267
Joined: August 5th, 2016, 7:27 pm
Location: Los Angeles, California, USA
Contact:

Re: Cancel-block-break script

Post by mcmonkey » April 1st, 2020, 12:39 am

GloatyMadn wrote:
March 31st, 2020, 6:49 am
Hello.
Please help,how make a cancel block-break script if player break blocks with a "§eExplosion pickaxe"
But if the player has permission item.explosionpickaxe he can use it.

I tried to search for instructions on how to write a script for denizen on version 1.12.2, but I didn't find anything, so I had to write topic here.
Check the beginner's guide @ https://guide.denizenscript.com/ and the support Discord @ https://discord.gg/Q6pZGSR and also maybe update your server to a modern version (ie 1.15.2)
Denizen lead developer. On Discord as mcmonkey#6666.

n0nnie
New
New
Posts: 29
Joined: January 10th, 2018, 3:19 am
Location: München - Germany
Contact:

Re: Cancel-block-break script

Post by n0nnie » April 4th, 2020, 12:16 pm

https://guide.denizenscript.com/guides/ ... sage-of-if

You might check if someone have this item in his hand if breaking a block.

Otherwise:
- determine cancelled

For example:

pickaxe_script:
events:
on player breaks block:
- if <put_in_players_thingis_here.not>:
- determine cancelled

Learn to write scripts by the youtube vids Monkey provided. What you want to achieve is not so hard to learn trust me

Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests