From b2a67e26cb085d4b02e142f4319d107ce9d6a52c Mon Sep 17 00:00:00 2001 From: Minenash Date: Sun, 23 Sep 2018 23:05:58 -0400 Subject: [PATCH] Added /chatn and /speakn --- src/com/redstoner/modules/chat/Chat.cmd | 8 ++++++++ src/com/redstoner/modules/chat/Chat.java | 9 ++++++++- 2 files changed, 16 insertions(+), 1 deletion(-) diff --git a/src/com/redstoner/modules/chat/Chat.cmd b/src/com/redstoner/modules/chat/Chat.cmd index fdd65e3..3091609 100644 --- a/src/com/redstoner/modules/chat/Chat.cmd +++ b/src/com/redstoner/modules/chat/Chat.cmd @@ -20,6 +20,14 @@ command chat { help A way to speak in normal chat with normal formatting if you have ACT or CGT on.; } } +command chatn { + alias speakn; + [string:name] [string:message...] { + perm utils.chatn; + run chatn name message; + help A way to speak in normal chat with normal formatting for console users.; + } +} command shrug { [string:message...] { perm utils.shrug; diff --git a/src/com/redstoner/modules/chat/Chat.java b/src/com/redstoner/modules/chat/Chat.java index 3c95609..1c7f8a1 100644 --- a/src/com/redstoner/modules/chat/Chat.java +++ b/src/com/redstoner/modules/chat/Chat.java @@ -28,7 +28,7 @@ import net.nemez.chatapi.ChatAPI; @Commands(CommandHolderType.File) @AutoRegisterListener -@Version(major = 4, minor = 1, revision = 0, compatible = 4) +@Version(major = 4, minor = 1, revision = 1, compatible = 4) public class Chat implements Module, Listener { private final Map defaults = new HashMap<>(); @@ -80,6 +80,13 @@ public class Chat implements Module, Listener return true; } + @Command(hook = "chatn") + public boolean chatn(CommandSender sender, String name, String message) + { + broadcastFormatted("chat", sender, message, name); + return true; + } + @Command(hook = "action") public boolean action(CommandSender sender, String message) {