forked from Fascinated/Bat
impl basic help command
This commit is contained in:
@ -7,6 +7,7 @@ import lombok.NonNull;
|
||||
import lombok.extern.log4j.Log4j2;
|
||||
import net.dv8tion.jda.api.events.guild.member.GuildMemberJoinEvent;
|
||||
import net.dv8tion.jda.api.events.guild.member.GuildMemberRemoveEvent;
|
||||
import net.dv8tion.jda.api.events.interaction.component.StringSelectInteractionEvent;
|
||||
import net.dv8tion.jda.api.events.message.MessageReceivedEvent;
|
||||
import net.dv8tion.jda.api.hooks.ListenerAdapter;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
@ -89,4 +90,17 @@ public class EventService extends ListenerAdapter {
|
||||
listener.onGuildMessageReceive(guild, user, event);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onStringSelectInteraction(StringSelectInteractionEvent event) {
|
||||
if (event.getUser().isBot()) {
|
||||
return;
|
||||
}
|
||||
BatGuild guild = event.getGuild() != null ? guildService.getGuild(event.getGuild().getId()) : null;
|
||||
BatUser user = userService.getUser(event.getUser().getId());
|
||||
|
||||
for (EventListener listener : LISTENERS) {
|
||||
listener.onStringSelectInteraction(guild, user, event);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user