-
-
Notifications
You must be signed in to change notification settings - Fork 75
Closed
Labels
enhancementNew feature or requestNew feature or requestimplemented for next releaseThis has been implemented in the current dev build for the next public releaseThis has been implemented in the current dev build for the next public release
Description
Description
I'd like to send error messages, using my custom message class, which implements ComponentLike interface.
At the moment, my error handling in commands looks like this:
if (!player.hasTown())
throw CommandAPIBukkit.failWithAdventureComponent(message(ERR_WITHOUT_TOWN).asComponent());After implementing suggested feature, my error handling would be:
if (!player.hasTown())
throw CommandAPIBukkit.failWithAdventureComponent(message(ERR_WITHOUT_TOWN));The second option looks much easier and prettier.
Expected code
CommandAPIBukkit#failWithAdventureComponent(ComponentLike)Extra details
No response
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or requestimplemented for next releaseThis has been implemented in the current dev build for the next public releaseThis has been implemented in the current dev build for the next public release