You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
guild.updateCommands().addCommands(Commands.slash("ping", "Ping Pong!"), Commands.slash("request", "Request Access to the server"), Commands.slash("rps", "Play 'Rock, Paper, Scissors' with Cameron"), Commands.slash("say", "Make cameron say something").addOption(OptionType.STRING, "message", "The thing to Cameron will say", true).setDefaultEnabled(false), Commands.slash("sayembed", "Make cameron say something as an embed").addOptions(
79
-
newOptionData(OptionType.STRING, "color", "The color of the sidebar of the embed", true, true), newOptionData(OptionType.STRING, "title", "The title of the embed", true), newOptionData(OptionType.STRING, "message", "The thing cameron will say", true)).setDefaultEnabled(false), Commands.slash("pronouns", "Set your pronouns"), Commands.slash("whois", "Check the information of a certain user").addOption(OptionType.USER, "user", "The usre to get the information of", true), Commands.slash("report", "Report a user").addOptions(newOptionData(OptionType.USER, "user", "The user you're reporting.", true), newOptionData(OptionType.STRING, "reason", "The reason you're reporting them.", true)), Commands.slash("kick", "Kicks a user").addOptions(newOptionData(OptionType.USER, "user", "the user to kick", true), newOptionData(OptionType.STRING, "reason", "the reason you're kicking them", false)).setDefaultEnabled(false),
80
-
Commands.slash("ban", "Kicks a user").addOptions(
77
+
//Global commands don't seem to work, even after waiting for the alotted time, so for the time being I'm sticking to guild commands.
78
+
guild.updateCommands().addCommands(
79
+
Commands.slash("ping", "Ping Pong!"),
80
+
Commands.slash("request", "Request Access to the server"),
81
+
Commands.slash("rps", "Play 'Rock, Paper, Scissors' with Cameron"),
82
+
Commands.slash("say", "Make cameron say something")
83
+
.addOption(OptionType.STRING, "message", "The thing to Cameron will say", true)
84
+
.setDefaultEnabled(false),
85
+
Commands.slash("sayembed", "Make cameron say something as an embed")
86
+
.addOptions(
87
+
newOptionData(OptionType.STRING, "color", "The color of the sidebar of the embed", true, true),
88
+
newOptionData(OptionType.STRING, "title", "The title of the embed", true),
89
+
newOptionData(OptionType.STRING, "message", "The thing cameron will say", true))
90
+
.setDefaultEnabled(false),
91
+
Commands.slash("pronouns", "Set your pronouns"),
92
+
Commands.slash("whois", "Check the information of a certain user").addOption(OptionType.USER, "user", "The usre to get the information of", true),
93
+
Commands.slash("report", "Report a user")
94
+
.addOptions(
95
+
newOptionData(OptionType.USER, "user", "The user you're reporting.", true),
96
+
newOptionData(OptionType.STRING, "reason", "The reason you're reporting them.", true)),
97
+
Commands.slash("kick", "Kicks a user").addOptions(
81
98
newOptionData(OptionType.USER, "user", "the user to kick", true),
82
-
newOptionData(OptionType.STRING, "reason", "the reason you're kicking them", false),
83
-
newOptionData(OptionType.INTEGER, "delete_history_days", "The amount of days of recent message history from this user you want to delete.", false)).setDefaultEnabled(false)
99
+
newOptionData(OptionType.STRING, "reason", "the reason you're kicking them", false))
100
+
.setDefaultEnabled(false),
101
+
Commands.slash("ban", "Kicks a user")
102
+
.addOptions(
103
+
newOptionData(OptionType.USER, "user", "the user to kick", true),
104
+
newOptionData(OptionType.STRING, "reason", "the reason you're kicking them", false),
105
+
newOptionData(OptionType.INTEGER, "delete_history_days", "The amount of days of recent message history from this user you want to delete.", false))
106
+
.setDefaultEnabled(false),
107
+
Commands.slash("joinlist", "Request access to the Minecraft Server")
event.reply("The username you typed contains characters that can't be in a Minecraft username: " + stringBuilder.substring(0, stringBuilder.length() - 2) +
45
+
"Please check to make sure you spelled your username correctly.").setEphemeral(true).queue();
46
+
return;
47
+
}
48
+
if(jsonString.isEmpty()) {
49
+
event.reply("I can't find the minecraft username '" + username + "', check that it's spelled correctly.").setEphemeral(true).queue();
50
+
return;
51
+
}
52
+
Map<String, String> json = parseJson(jsonString);
53
+
if(json.containsKey("error")) {
54
+
event.reply("I can't find the minecraft username '" + username + "', check that it's spelled correctly.").setEphemeral(true).queue();
0 commit comments