Add ShopPlayer#sendMessage for formatted messages

This commit is contained in:
Eric 2019-08-18 14:03:48 +02:00
parent 8311221efc
commit dbcd52fefd

View File

@ -23,6 +23,16 @@ public interface ShopPlayer {
*/
Player getPlayer();
/**
* Sends a (formatted) message to this player
*
* @param message the message (a format string)
* @param args the arguments referenced by the format
*/
default void sendMessage(String message, Object... args) {
getPlayer().sendMessage(String.format(message, args));
}
/**
* Gets this player's flag
*