KaiKikuchi / QuickShop

A shop plugin for Bukkit
47 stars 41 forks source link

Adventure Mode Can not use to buy or sell #122

Closed tygh89071388 closed 7 years ago

tygh89071388 commented 7 years ago

/gamemode 2 Can not use to buy or sell

spigot-1.11.2

Come on the great author to help

KaiKikuchi commented 7 years ago

Try by giving them a tool that can break signs/chests.

KaiKikuchi commented 7 years ago

I tested this to see how it works in details.

This is caused by the vanilla client not sending any packet if the action is not allowed. So you have to fix this by forcing the player's client to send a packet for that action.

Minecraft 1.7.10 (and lower): You have to give them an item that can break signs, like a wooden axe.

Minecraft 1.8 (and greater): Give them an item that can breaks signs. You have to add an NBT tag to the item that allows that.

This gives you a stick that can be used to click the sign: /give kainomood stick 1 0 {CanDestroy:["wall_sign"]}

In any case, you need an actual protection that avoids breaking the sign. This can be achieved by adding mining fatigue level 255 to players holding that item, or by using a Bukkit protection plugin.