added ability to send command denied message as action bar in bukkit and waterfall

This commit is contained in:
2024-12-17 17:14:50 +01:00
parent b4fda1cb9e
commit 7a707068e2
9 changed files with 41 additions and 7 deletions
+1 -1
View File
@@ -6,7 +6,7 @@
<parent>
<groupId>eu.endermite.commandwhitelist</groupId>
<artifactId>CommandWhitelist</artifactId>
<version>2.10.0</version>
<version>2.11.0</version>
</parent>
<artifactId>Bukkit</artifactId>
@@ -34,7 +34,14 @@ public class PlayerCommandPreProcessListener implements Listener {
messageWithoutSlash,
config.prefix + CommandWhitelistBukkit.getCommandDeniedMessage(label)
);
audiences.player(player).sendMessage(message);
switch (config.messageType) {
case CHAT:
audiences.player(player).sendMessage(message);
break;
case ACTIONBAR:
audiences.player(player).sendActionBar(message);
break;
}
return;
}