|
@ -8,7 +8,6 @@ import net.dv8tion.jda.api.entities.VoiceChannel; |
|
|
public class SayCommand extends YoshiCommand { |
|
|
public class SayCommand extends YoshiCommand { |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
protected final String[] requiredArguments = {"text", "channel"}; |
|
|
protected final String[] requiredArguments = {"text", "channel"}; |
|
|
|
|
|
|
|
|
|
|
|
|
|
@ -19,7 +18,9 @@ public class SayCommand extends YoshiCommand { |
|
|
@Override |
|
|
@Override |
|
|
public boolean execute() { |
|
|
public boolean execute() { |
|
|
if (!super.execute()) return false; |
|
|
if (!super.execute()) return false; |
|
|
|
|
|
|
|
|
|
|
|
context.getEvent().getMessage().getTextChannel().sendMessage( |
|
|
|
|
|
"Danke, " + context.getEvent().getMessage().getAuthor().getName() + ". Ich werde nun " + |
|
|
|
|
|
"abspielen:\n" + context.getArgument("text")).queue(); |
|
|
return YoshiBot.getInstance().sayTTS(context.getArgument("text"), getVoiceChannelByParam()); |
|
|
return YoshiBot.getInstance().sayTTS(context.getArgument("text"), getVoiceChannelByParam()); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|