Added which should reply with server prefix

This commit is contained in:
Savvy 2017-09-28 20:50:24 -04:00
parent 46d1c70da6
commit 7675fe3ec3

View File

@ -52,6 +52,11 @@ public class MessageEvent {
String s = event.getMessage().getContent().replace String s = event.getMessage().getContent().replace
("@" + event.getGuild().getSelfMember().getEffectiveName() + " ", ""); ("@" + event.getGuild().getSelfMember().getEffectiveName() + " ", "");
if (s.isEmpty()) return; if (s.isEmpty()) return;
if (s.equalsIgnoreCase("prefix")) {
new MessageBuilder(event.getGuild().getName() + "'s server prefix is `" + rixaGuild.getGuildSettings().getPrefix() + "`.").queue(event.getChannel());
return;
}
s = ((ConversationModule) rixaGuild.getModule("Conversations")).getChatBotSession().think(s); s = ((ConversationModule) rixaGuild.getModule("Conversations")).getChatBotSession().think(s);
if (s.isEmpty()) return; if (s.isEmpty()) return;
event.getChannel().sendMessage(s).queue(); event.getChannel().sendMessage(s).queue();