Compare commits
No commits in common. "7ae4790d5cfed4ca3bb73bcb632ff23026ce3a84" and "656dff4b26fa5ef69d5c327a5e04cdac318f2d11" have entirely different histories.
7ae4790d5c
...
656dff4b26
@ -2,9 +2,9 @@ package wtf.beatrice.hidekobot;
|
|||||||
|
|
||||||
import net.dv8tion.jda.api.interactions.commands.Command;
|
import net.dv8tion.jda.api.interactions.commands.Command;
|
||||||
import org.jetbrains.annotations.Nullable;
|
import org.jetbrains.annotations.Nullable;
|
||||||
import wtf.beatrice.hidekobot.datasource.ConfigurationSource;
|
|
||||||
import wtf.beatrice.hidekobot.datasource.DatabaseSource;
|
import wtf.beatrice.hidekobot.datasource.DatabaseSource;
|
||||||
import wtf.beatrice.hidekobot.listeners.MessageLogger;
|
import wtf.beatrice.hidekobot.listeners.MessageLogger;
|
||||||
|
import wtf.beatrice.hidekobot.datasource.ConfigurationSource;
|
||||||
import wtf.beatrice.hidekobot.util.Logger;
|
import wtf.beatrice.hidekobot.util.Logger;
|
||||||
|
|
||||||
import java.awt.*;
|
import java.awt.*;
|
||||||
|
@ -6,7 +6,6 @@ import net.dv8tion.jda.api.OnlineStatus;
|
|||||||
import net.dv8tion.jda.api.entities.Activity;
|
import net.dv8tion.jda.api.entities.Activity;
|
||||||
import net.dv8tion.jda.api.requests.GatewayIntent;
|
import net.dv8tion.jda.api.requests.GatewayIntent;
|
||||||
import sun.misc.Signal;
|
import sun.misc.Signal;
|
||||||
import wtf.beatrice.hidekobot.datasource.ConfigurationSource;
|
|
||||||
import wtf.beatrice.hidekobot.datasource.DatabaseSource;
|
import wtf.beatrice.hidekobot.datasource.DatabaseSource;
|
||||||
import wtf.beatrice.hidekobot.listeners.ButtonInteractionListener;
|
import wtf.beatrice.hidekobot.listeners.ButtonInteractionListener;
|
||||||
import wtf.beatrice.hidekobot.listeners.MessageListener;
|
import wtf.beatrice.hidekobot.listeners.MessageListener;
|
||||||
@ -15,6 +14,7 @@ import wtf.beatrice.hidekobot.listeners.SlashCommandListener;
|
|||||||
import wtf.beatrice.hidekobot.runnables.CommandsUpdateTask;
|
import wtf.beatrice.hidekobot.runnables.CommandsUpdateTask;
|
||||||
import wtf.beatrice.hidekobot.runnables.ExpiredMessageTask;
|
import wtf.beatrice.hidekobot.runnables.ExpiredMessageTask;
|
||||||
import wtf.beatrice.hidekobot.runnables.HeartBeatTask;
|
import wtf.beatrice.hidekobot.runnables.HeartBeatTask;
|
||||||
|
import wtf.beatrice.hidekobot.datasource.ConfigurationSource;
|
||||||
import wtf.beatrice.hidekobot.util.Logger;
|
import wtf.beatrice.hidekobot.util.Logger;
|
||||||
import wtf.beatrice.hidekobot.util.SlashCommandUtil;
|
import wtf.beatrice.hidekobot.util.SlashCommandUtil;
|
||||||
|
|
||||||
|
@ -34,10 +34,7 @@ public class BotInfoCommand
|
|||||||
if(botAvatarUrl != null) embedBuilder.setThumbnail(botAvatarUrl);
|
if(botAvatarUrl != null) embedBuilder.setThumbnail(botAvatarUrl);
|
||||||
|
|
||||||
// help field
|
// help field
|
||||||
long ownerId = Cache.getBotOwnerId();
|
embedBuilder.addField("Getting started", "Type `/help` for help!", false);
|
||||||
embedBuilder.addField("Getting started",
|
|
||||||
"This instance is run by <@" + ownerId + ">.\nType `/help` for help! ",
|
|
||||||
false);
|
|
||||||
|
|
||||||
// commands list field
|
// commands list field
|
||||||
StringBuilder commandsListBuilder = new StringBuilder();
|
StringBuilder commandsListBuilder = new StringBuilder();
|
||||||
|
@ -17,7 +17,7 @@ import wtf.beatrice.hidekobot.Cache;
|
|||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
public class ClearCommand
|
public class ClearChatCommand
|
||||||
{
|
{
|
||||||
|
|
||||||
public void runSlashCommand(@NotNull SlashCommandInteractionEvent event)
|
public void runSlashCommand(@NotNull SlashCommandInteractionEvent event)
|
@ -2,7 +2,7 @@ package wtf.beatrice.hidekobot.listeners;
|
|||||||
|
|
||||||
import net.dv8tion.jda.api.events.interaction.component.ButtonInteractionEvent;
|
import net.dv8tion.jda.api.events.interaction.component.ButtonInteractionEvent;
|
||||||
import net.dv8tion.jda.api.hooks.ListenerAdapter;
|
import net.dv8tion.jda.api.hooks.ListenerAdapter;
|
||||||
import wtf.beatrice.hidekobot.commands.slash.ClearCommand;
|
import wtf.beatrice.hidekobot.commands.slash.ClearChatCommand;
|
||||||
import wtf.beatrice.hidekobot.commands.slash.CoinFlipCommand;
|
import wtf.beatrice.hidekobot.commands.slash.CoinFlipCommand;
|
||||||
|
|
||||||
public class ButtonInteractionListener extends ListenerAdapter
|
public class ButtonInteractionListener extends ListenerAdapter
|
||||||
@ -18,7 +18,7 @@ public class ButtonInteractionListener extends ListenerAdapter
|
|||||||
case "coinflip_reflip" -> new CoinFlipCommand().buttonReFlip(event);
|
case "coinflip_reflip" -> new CoinFlipCommand().buttonReFlip(event);
|
||||||
|
|
||||||
// clearchat command
|
// clearchat command
|
||||||
case "clear_dismiss" -> new ClearCommand().dismissMessage(event);
|
case "clear_dismiss" -> new ClearChatCommand().dismissMessage(event);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -14,7 +14,7 @@ public class SlashCommandListener extends ListenerAdapter
|
|||||||
switch (event.getName().toLowerCase()) {
|
switch (event.getName().toLowerCase()) {
|
||||||
case "avatar" -> new AvatarCommand().runSlashCommand(event);
|
case "avatar" -> new AvatarCommand().runSlashCommand(event);
|
||||||
case "botinfo" -> new BotInfoCommand().runSlashCommand(event);
|
case "botinfo" -> new BotInfoCommand().runSlashCommand(event);
|
||||||
case "clear" -> new ClearCommand().runSlashCommand(event);
|
case "clear" -> new ClearChatCommand().runSlashCommand(event);
|
||||||
case "coinflip" -> new CoinFlipCommand().runSlashCommand(event);
|
case "coinflip" -> new CoinFlipCommand().runSlashCommand(event);
|
||||||
case "die" -> new DieCommand().runSlashCommand(event);
|
case "die" -> new DieCommand().runSlashCommand(event);
|
||||||
case "help" -> new HelpCommand().runSlashCommand(event);
|
case "help" -> new HelpCommand().runSlashCommand(event);
|
||||||
|
Loading…
Reference in New Issue
Block a user