You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
30 lines
678 B
30 lines
678 B
3 years ago
|
/*
|
||
|
* To change this license header, choose License Headers in Project Properties.
|
||
|
* To change this template file, choose Tools | Templates
|
||
|
* and open the template in the editor.
|
||
|
*/
|
||
|
package moe.nekojimi.chords.commands;
|
||
|
|
||
|
import java.util.List;
|
||
|
import moe.nekojimi.chords.Main;
|
||
|
import net.dv8tion.jda.api.events.message.guild.GuildMessageReceivedEvent;
|
||
|
|
||
|
public class LeaveCommand extends Command
|
||
|
{
|
||
|
|
||
|
public LeaveCommand(Main bot)
|
||
|
{
|
||
|
super(bot, "leave");
|
||
|
}
|
||
|
|
||
|
@Override
|
||
|
public void call(GuildMessageReceivedEvent event, List<String> arg)
|
||
|
{
|
||
|
if (bot.getCurrentVoiceChannel() != null)
|
||
|
{
|
||
|
bot.disconnect();
|
||
|
}
|
||
|
}
|
||
|
|
||
|
}
|