Added /acn (seen /sayn)
This commit is contained in:
@@ -24,7 +24,7 @@ import com.redstoner.modules.Module;
|
|||||||
*
|
*
|
||||||
* @author Pepich */
|
* @author Pepich */
|
||||||
@AutoRegisterListener
|
@AutoRegisterListener
|
||||||
@Version(major = 2, minor = 0, revision = 1, compatible = 2)
|
@Version(major = 2, minor = 0, revision = 2, compatible = 2)
|
||||||
public class Adminchat implements Module, Listener
|
public class Adminchat implements Module, Listener
|
||||||
{
|
{
|
||||||
private static final char defaultKey = ',';
|
private static final char defaultKey = ',';
|
||||||
@@ -56,6 +56,14 @@ public class Adminchat implements Module, Listener
|
|||||||
" run ac_msg message;\n" +
|
" run ac_msg message;\n" +
|
||||||
" }\n" +
|
" }\n" +
|
||||||
"}\n" +
|
"}\n" +
|
||||||
|
"command acn {\n" +
|
||||||
|
" [string:name] [string:message...] {\n" +
|
||||||
|
" help Sends a message in Admin Chat;\n" +
|
||||||
|
" perm utils.ac;\n" +
|
||||||
|
" type console;\n" +
|
||||||
|
" run acn_msg name message;\n" +
|
||||||
|
" }\n" +
|
||||||
|
"}\n" +
|
||||||
" \n" +
|
" \n" +
|
||||||
"command ackey {\n" +
|
"command ackey {\n" +
|
||||||
" [string:key] {\n" +
|
" [string:key] {\n" +
|
||||||
@@ -105,6 +113,20 @@ public class Adminchat implements Module, Listener
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Command(hook = "acn_msg")
|
||||||
|
public boolean acnSay(CommandSender sender, String name, String message)
|
||||||
|
{
|
||||||
|
Utils.broadcast("§8[§cAC§8] §9" + name + "§8: §b", message, new BroadcastFilter()
|
||||||
|
{
|
||||||
|
@Override
|
||||||
|
public boolean sendTo(CommandSender recipient)
|
||||||
|
{
|
||||||
|
return recipient.hasPermission("utils.ac");
|
||||||
|
}
|
||||||
|
}, '&');
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
/** Let's a Player toggle their auto-cg status to allow for automatically sending chat messages to their chatgroup.
|
/** Let's a Player toggle their auto-cg status to allow for automatically sending chat messages to their chatgroup.
|
||||||
*
|
*
|
||||||
* @param sender the issuer of the command.
|
* @param sender the issuer of the command.
|
||||||
|
|||||||
Reference in New Issue
Block a user