Might it be possible to add a onBreak with a player method to Blocks?
We right now just have onBreak(Item item) { ... } but might it be possible to add a method like onBreak(Item item, Player player) { ... }
Already existing examples
The Block method getBreakTime already offers theese 2 options:
getBreakTime (Item item, Player player) { ... }
getBreakTime(Item item) { ... }
Smoll workarounds
I know that you still can get the player with an onBlockBreakevent but,
It makes more sense to work it in the already existing onBreak method of a block ~ it also isn't maintainable for plugin devs to add many cases to the onBlockBreak event listener
❇ Feature Request | 特性请求
Description
Might it be possible to add a onBreak with a player method to Blocks? We right now just have
onBreak(Item item) { ... }
but might it be possible to add a method likeonBreak(Item item, Player player) { ... }
Already existing examples
The Block method
getBreakTime
already offers theese 2 options:getBreakTime (Item item, Player player) { ... }
getBreakTime(Item item) { ... }
Smoll workarounds
I know that you still can get the player with an
onBlockBreak
event but, It makes more sense to work it in the already existingonBreak
method of a block ~ it also isn't maintainable for plugin devs to add many cases to theonBlockBreak
event listenerfinal String
Have a good day