diff --git a/.github/workflows/maven.yml b/.github/workflows/maven.yml
index d925b7d..446998e 100644
--- a/.github/workflows/maven.yml
+++ b/.github/workflows/maven.yml
@@ -32,6 +32,7 @@ jobs:
local: ./target/Hadder-Build.jar
remote: /root/bots/Hadder/Hadder-Build.jar
host: ${{ secrets.HOST }}
+ port: ${{ secrets.PORT }}
username: ${{ secrets.USERNAME }}
password: ${{ secrets.PASSWORD }}
- name: executing remote ssh commands using password
diff --git a/example-config.json b/example-config.json
index cd6ecaa..d3e3e2c 100644
--- a/example-config.json
+++ b/example-config.json
@@ -11,19 +11,7 @@
"Tokens": {
"BotToken": "",
"Giphy": "",
- "GitHub": "",
- "MythicalBotList": "",
- "BotsForDiscord": "",
- "DiscordBotList": "",
- "DiscordBoats": "",
- "YetAnotherBotList": "",
- "DiscordExtremeList": "",
- "DiscordBotReviews": "",
- "DiscordBots": "",
- "BotListSpace": "",
- "DiscordBots2": "",
- "CloudList": "",
- "Arcane": ""
+ "GitHub": ""
},
"Clyde": ""
}
diff --git a/pom.xml b/pom.xml
index b4bcae0..f7fd1e2 100644
--- a/pom.xml
+++ b/pom.xml
@@ -6,7 +6,7 @@
4.0.0
Hadder
Hadder
- 1.3.26
+ 2.0.0
Hadder
2019
Hadder is a multi-purpose Discord bot.
@@ -69,17 +69,12 @@
net.dv8tion
JDA
- 4.2.0_231
+ 4.2.0_247
org.json
json
- 20201115
-
-
- com.rethinkdb
- rethinkdb-driver
- 2.4.4
+ 20210307
org.slf4j
@@ -89,23 +84,28 @@
club.minnced
discord-webhooks
- 0.5.4
+ 0.5.6
org.kohsuke
github-api
- 1.123
+ 1.125
com.sedmelluq
lavaplayer
- 1.3.72
+ 1.3.73
com.fasterxml.jackson.core
jackson-annotations
2.12.2
+
+ org.mongodb
+ mongodb-driver-sync
+ 4.2.2
+
@@ -130,7 +130,7 @@
Hadder-Build
- com.bbn.hadder.Hadder
+ one.bbn.hadder.Hadder
@@ -169,7 +169,7 @@
Hadder-Build
- com.bbn.hadder.Hadder
+ one.bbn.hadder.Hadder
diff --git a/src/main/java/com/bbn/hadder/db/Rethink.java b/src/main/java/com/bbn/hadder/db/Rethink.java
deleted file mode 100644
index a4b1c1e..0000000
--- a/src/main/java/com/bbn/hadder/db/Rethink.java
+++ /dev/null
@@ -1,176 +0,0 @@
-/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
- *
- * Licensed under the GNU Affero General Public License, Version 3.0;
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * https://www.gnu.org/licenses/agpl-3.0.en.html
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.bbn.hadder.db;
-
-import com.bbn.hadder.core.Config;
-import com.rethinkdb.RethinkDB;
-import com.rethinkdb.gen.exc.ReqlNonExistenceError;
-import com.rethinkdb.gen.exc.ReqlOpFailedError;
-import com.rethinkdb.net.Connection;
-import org.json.JSONException;
-import org.json.JSONObject;
-
-import java.lang.reflect.Field;
-
-public class Rethink {
- private final RethinkDB r = RethinkDB.r;
- private Connection conn;
- private final Config config;
-
- public Rethink(Config config) {
- this.config = config;
- }
-
- public void connect() {
- try {
- conn = r.connection()
- .hostname(config.getDatabaseIP())
- .db(config.getDatabaseName())
- .port(config.getDatabasePort())
- .user(config.getDatabaseUsername(), config.getDatabasePassword())
- .connect();
- System.out.println("DB CONNECTED");
- } catch (Exception e) {
- e.printStackTrace();
- System.out.println("DB CONNECTION FAILED");
- }
- }
-
- public Object getByID(String table, String where, String column) {
- return r.table(table).get(where).getField(column).run(conn).first();
- }
-
- public JSONObject getObjectByID(String table, String id) {
- String response = String.valueOf(r.table(table).get(id).toJson().run(conn).first());
- try {
- return new JSONObject(response);
- } catch (JSONException e) {
- insertUser(id);
- String response2 = String.valueOf(r.table(table).get(id).toJson().run(conn).first());
- try {
- return new JSONObject(response2);
- } catch (JSONException ex) {
- ex.printStackTrace();
- return null;
- }
- }
- }
-
- public void insert(String table, Object object) {
- try {
- r.table(table).insert(object).run(conn);
- } catch (ClassCastException e) {
- e.printStackTrace();
- }
- }
-
- public void remove(String table, String where, String value) {
- r.table(table).filter(row -> row.g(where.toLowerCase()).eq(value)).delete().run(conn);
- }
-
- public void setup() {
- try {
- r.dbCreate("Hadder").run(conn);
- } catch (ReqlOpFailedError e) {
- System.out.println(e.getMessage());
- }
- try {
- r.tableCreate("server").run(conn);
- } catch (ReqlOpFailedError e) {
- System.out.println(e.getMessage());
- }
- try {
- r.tableCreate("user").run(conn);
- } catch (ReqlOpFailedError e) {
- System.out.println(e.getMessage());
- }
- try {
- r.tableCreate("stars").run(conn);
- } catch (ReqlOpFailedError e) {
- System.out.println(e.getMessage());
- }
- }
-
- public void insertGuild(String id) {
- this.insert("server", r
- .hashMap("id", id)
- .with("prefix", "h.")
- .with("message_id", "")
- .with("role_id", "")
- .with("invite_detect", false)
- .with("starboard", "")
- .with("neededstars", "4")
- );
- }
-
- public void insertUser(String id) {
- this.insert("user", r
- .hashMap("id", id)
- .with("prefix", "h.")
- .with("language", "en")
- .with("blacklisted", "none"));
- }
-
- public void insertStarboardMessage(String message_id, String guild_id, String starboard_message_id) {
- this.insert("stars", r.hashMap("id", message_id).with("guild", guild_id).with("starboardmsg", starboard_message_id));
- }
-
- public String getStarboardMessage(String message_id) {
- return (String) this.getByID("stars", message_id, "starboardmsg");
- }
-
- public void removeStarboardMessage(String message_id) {
- this.remove("stars", "id", message_id);
- }
-
- public boolean hasStarboardMessage(String message_id) {
- try {
- this.getByID("stars", message_id, "guild");
- return true;
- } catch (ReqlNonExistenceError e) {
- return false;
- }
- }
-
- public void push(RethinkServer server) {
- JSONObject object = new JSONObject();
- for (Field field : server.getClass().getDeclaredFields()) {
- if (!field.getName().equals("rethink")) {
- try {
- object.put(field.getName(), field.get(server));
- } catch (IllegalAccessException e) {
- e.printStackTrace();
- }
- }
- }
- r.table("server").get(server.getId()).update(object.toMap()).run(conn);
- }
-
- public void push(RethinkUser user) {
- JSONObject object = new JSONObject();
- for (Field field : user.getClass().getDeclaredFields()) {
- if (!field.getName().equals("rethink")) {
- try {
- object.put(field.getName(), field.get(user));
- } catch (IllegalAccessException e) {
- e.printStackTrace();
- }
- }
- }
- r.table("user").get(user.getId()).update(object.toMap()).run(conn);
- }
-}
diff --git a/src/main/java/com/bbn/hadder/utils/BotList.java b/src/main/java/com/bbn/hadder/utils/BotList.java
deleted file mode 100644
index 04374c8..0000000
--- a/src/main/java/com/bbn/hadder/utils/BotList.java
+++ /dev/null
@@ -1,215 +0,0 @@
-/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
- *
- * Licensed under the GNU Affero General Public License, Version 3.0;
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * https://www.gnu.org/licenses/agpl-3.0.en.html
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package com.bbn.hadder.utils;
-
-import com.bbn.hadder.Hadder;
-import com.bbn.hadder.core.Config;
-import okhttp3.MediaType;
-import okhttp3.OkHttpClient;
-import okhttp3.Request;
-import okhttp3.RequestBody;
-import org.json.JSONObject;
-
-import java.io.IOException;
-import java.nio.file.Files;
-import java.nio.file.Paths;
-
-public class BotList {
-
- private static String MythicalBotList = "https://mythicalbots.xyz/api/bot/637002314162372639";
- private static String BotsForDiscord = "https://botsfordiscord.com/api/bot/637002314162372639";
- private static String DiscordBotList = "https://discordbotlist.com/api/bots/637002314162372639/stats";
- private static String DiscordBoats = "https://discord.boats/api/v2/bot/637002314162372639";
- private static String YetAnotherBotList = "https://yabl.xyz/api/bot/637002314162372639/stats";
- private static String DiscordExtremeList = "https://api.discordextremelist.xyz/v1/bot/637002314162372639";
- private static String DiscordBots = "https://top.gg/api/bots/637002314162372639/stats";
- private static String BotListSpace = "https://api.botlist.space/v1/bots/637002314162372639";
- private static String DiscordBots2 = "https://discord.bots.gg/api/v1/bots/637002314162372639/stats";
- private static String ArcaneBotCenter = "https://arcane-center.xyz/api/637002314162372639/stats";
-
- private Config config;
-
- public BotList(Config config) {
- this.config = config;
- }
-
- public void post() {
- if (Files.notExists(Paths.get("./DEBUG"))) {
- JSONObject json = new JSONObject();
- json.put("server_count", Hadder.shardManager.getGuilds().size());
- json.put("guildCount", Hadder.shardManager.getGuilds().size());
- json.put("guilds", Hadder.shardManager.getGuilds().size());
- json.put("count", Hadder.shardManager.getGuilds().size());
- json.put("users", Hadder.shardManager.getUsers().size());
- json.put("shard_count", Hadder.shardManager.getShards().size());
- json.put("shardCount", Hadder.shardManager.getShards().size());
- json.put("member_count", Hadder.shardManager.getUsers().size());
-
- RequestBody body = RequestBody.create(MediaType.parse("application/json"), json.toString());
-
- // Mythical Bot List
-
- Request mythicalbotlist = new Request.Builder()
- .url(MythicalBotList)
- .post(body)
- .addHeader("Authorization", config.getMythicalBotListToken())
- .build();
-
- try {
- new OkHttpClient().newCall(mythicalbotlist).execute().close();
- System.out.println("Successfully posted count for the Mythical Bot List!");
- } catch (IOException e) {
- e.printStackTrace();
- }
-
- // BotsForDiscord
-
- Request botsfordiscord = new Request.Builder()
- .url(BotsForDiscord)
- .post(body)
- .addHeader("Authorization", config.getBotsForDiscordToken())
- .build();
-
- try {
- new OkHttpClient().newCall(botsfordiscord).execute().close();
- System.out.println("Successfully posted count to Bots For Discord!");
- } catch (IOException e) {
- e.printStackTrace();
- }
-
- // Discord Bot List
-
- Request discordbotlist = new Request.Builder()
- .url(DiscordBotList)
- .post(body)
- .addHeader("Authorization", "Bot " + config.getDiscordBotListToken())
- .build();
-
- try {
- new OkHttpClient().newCall(discordbotlist).execute().close();
- System.out.println("Successfully posted count for the Discord Bot List!");
- } catch (IOException e) {
- e.printStackTrace();
- }
-
- // Discord Boats
-
- Request discordboats = new Request.Builder()
- .url(DiscordBoats)
- .post(body)
- .addHeader("Authorization", config.getDiscordBoatsToken())
- .build();
-
- try {
- new OkHttpClient().newCall(discordboats).execute().close();
- System.out.println("Successfully posted count to Discord Boats!");
- } catch (IOException e) {
- e.printStackTrace();
- }
-
- // Yet Another Bot List
-
- Request yetanotherbotlist = new Request.Builder()
- .url(YetAnotherBotList)
- .post(body)
- .addHeader("Authorization", config.getYetAnotherBotListToken())
- .build();
-
- try {
- new OkHttpClient().newCall(yetanotherbotlist).execute().close();
- System.out.println("Successfully posted count to Yet Another Bot List!");
- } catch (IOException e) {
- e.printStackTrace();
- }
-
- // Discord Extreme List
-
- Request discordextremelist = new Request.Builder()
- .url(DiscordExtremeList)
- .post(body)
- .addHeader("Authorization", config.getDiscordExtremeListToken())
- .build();
-
- try {
- new OkHttpClient().newCall(discordextremelist).execute().close();
- System.out.println("Successfully posted count for the Discord Extreme List!");
- } catch (IOException e) {
- e.printStackTrace();
- }
-
- // Discord Bots
-
- Request discordbots = new Request.Builder()
- .url(DiscordBots)
- .post(body)
- .addHeader("Authorization", config.getDiscordBotsToken())
- .build();
-
- try {
- new OkHttpClient().newCall(discordbots).execute().close();
- System.out.println("Successfully posted count to Discord Bots!");
- } catch (IOException e) {
- e.printStackTrace();
- }
-
- // BotListSpace
-
- Request botlistspace = new Request.Builder()
- .url(BotListSpace)
- .post(body)
- .addHeader("Authorization", config.getBotListSpaceToken())
- .build();
-
- try {
- new OkHttpClient().newCall(botlistspace).execute().close();
- System.out.println("Successfully posted count to BotList.Space!");
- } catch (IOException e) {
- e.printStackTrace();
- }
-
- // Discord Bots 2
-
- Request discordbots2 = new Request.Builder()
- .url(DiscordBots2)
- .post(body)
- .addHeader("Authorization", config.getDiscordBots2Token())
- .build();
-
- try {
- new OkHttpClient().newCall(discordbots2).execute().close();
- System.out.println("Successfully posted count to discord.bots.gg!");
- } catch (IOException e) {
- e.printStackTrace();
- }
-
- // Arcane Bot Center
-
- Request arcane = new Request.Builder()
- .url(ArcaneBotCenter)
- .post(body)
- .addHeader("Authorization", config.getArcaneToken())
- .build();
-
- try {
- new OkHttpClient().newCall(arcane).execute().close();
- System.out.println("Successfully posted count to the Arcane Bot Center!");
- } catch (IOException e) {
- e.printStackTrace();
- }
- }
- }
-}
diff --git a/src/main/java/com/bbn/hadder/Hadder.java b/src/main/java/one/bbn/hadder/Hadder.java
similarity index 77%
rename from src/main/java/com/bbn/hadder/Hadder.java
rename to src/main/java/one/bbn/hadder/Hadder.java
index ba59d44..28764d2 100644
--- a/src/main/java/com/bbn/hadder/Hadder.java
+++ b/src/main/java/one/bbn/hadder/Hadder.java
@@ -14,25 +14,26 @@
* limitations under the License.
*/
-package com.bbn.hadder;
+package one.bbn.hadder;
-import com.bbn.hadder.audio.AudioManager;
-import com.bbn.hadder.commands.fun.AvatarCommand;
-import com.bbn.hadder.commands.fun.ClydeCommand;
-import com.bbn.hadder.commands.fun.GifCommand;
-import com.bbn.hadder.commands.fun.MemeCommand;
-import com.bbn.hadder.commands.general.*;
-import com.bbn.hadder.commands.misc.*;
-import com.bbn.hadder.commands.moderation.*;
-import com.bbn.hadder.commands.music.*;
-import com.bbn.hadder.commands.nsfw.*;
-import com.bbn.hadder.commands.owner.*;
-import com.bbn.hadder.commands.settings.LanguageCommand;
-import com.bbn.hadder.commands.settings.UserPrefixCommand;
-import com.bbn.hadder.core.CommandHandler;
-import com.bbn.hadder.core.Config;
-import com.bbn.hadder.db.Rethink;
-import com.bbn.hadder.listener.*;
+import net.dv8tion.jda.api.utils.cache.CacheFlag;
+import one.bbn.hadder.audio.AudioManager;
+import one.bbn.hadder.commands.fun.AvatarCommand;
+import one.bbn.hadder.commands.fun.ClydeCommand;
+import one.bbn.hadder.commands.fun.GifCommand;
+import one.bbn.hadder.commands.fun.MemeCommand;
+import one.bbn.hadder.commands.general.*;
+import one.bbn.hadder.commands.misc.*;
+import one.bbn.hadder.commands.moderation.*;
+import one.bbn.hadder.commands.music.*;
+import one.bbn.hadder.commands.nsfw.*;
+import one.bbn.hadder.commands.owner.*;
+import one.bbn.hadder.commands.settings.LanguageCommand;
+import one.bbn.hadder.commands.settings.UserPrefixCommand;
+import one.bbn.hadder.core.CommandHandler;
+import one.bbn.hadder.core.Config;
+import one.bbn.hadder.db.Mongo;
+import one.bbn.hadder.listener.*;
import net.dv8tion.jda.api.OnlineStatus;
import net.dv8tion.jda.api.entities.Activity;
import net.dv8tion.jda.api.requests.GatewayIntent;
@@ -55,10 +56,10 @@ public class Hadder {
if (!config.fileExists()) config.create();
config.load();
- Rethink rethink = new Rethink(config);
- rethink.connect();
+ Mongo mongo = new Mongo(config);
+ mongo.connect();
- DefaultShardManagerBuilder builder = DefaultShardManagerBuilder.create(GatewayIntent.getIntents(GatewayIntent.ALL_INTENTS));
+ DefaultShardManagerBuilder builder = DefaultShardManagerBuilder.create(GatewayIntent.getIntents(14053));
builder.setAutoReconnect(true);
builder.setShardsTotal(1);
@@ -67,6 +68,7 @@ public class Hadder {
builder.setActivity(Activity.listening("h.help"));
builder.setStatus(OnlineStatus.DO_NOT_DISTURB);
builder.setToken(config.getBotToken());
+ builder.disableCache(CacheFlag.ACTIVITY, CacheFlag.EMOTE, CacheFlag.CLIENT_STATUS);
HelpCommand helpCommand = new HelpCommand();
AudioManager audioManager = new AudioManager();
@@ -137,14 +139,14 @@ public class Hadder {
new CoronaCommand()), config, helpCommand);
builder.addEventListeners(
- new MentionListener(rethink, config),
- new PrivateMessageListener(rethink),
- new CommandListener(rethink, commandHandler, audioManager),
- new GuildListener(rethink, config),
- new ReadyListener(rethink, config),
- new InviteLinkListener(rethink),
- new RulesListener(rethink),
- new StarboardListener(rethink),
+ new MentionListener(mongo, config),
+ new PrivateMessageListener(mongo),
+ new CommandListener(mongo, commandHandler, audioManager),
+ new GuildListener(mongo, config),
+ new ReadyListener(config),
+ new InviteLinkListener(mongo),
+ new RulesListener(mongo),
+ new StarboardListener(mongo),
new VoiceLeaveListener(audioManager),
new OwnerMessageListener(config));
diff --git a/src/main/java/com/bbn/hadder/audio/AudioInfo.java b/src/main/java/one/bbn/hadder/audio/AudioInfo.java
similarity index 92%
rename from src/main/java/com/bbn/hadder/audio/AudioInfo.java
rename to src/main/java/one/bbn/hadder/audio/AudioInfo.java
index 7568b60..477bfa1 100644
--- a/src/main/java/com/bbn/hadder/audio/AudioInfo.java
+++ b/src/main/java/one/bbn/hadder/audio/AudioInfo.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-package com.bbn.hadder.audio;
+package one.bbn.hadder.audio;
import com.sedmelluq.discord.lavaplayer.track.AudioTrack;
import net.dv8tion.jda.api.entities.Member;
diff --git a/src/main/java/com/bbn/hadder/audio/AudioManager.java b/src/main/java/one/bbn/hadder/audio/AudioManager.java
similarity index 97%
rename from src/main/java/com/bbn/hadder/audio/AudioManager.java
rename to src/main/java/one/bbn/hadder/audio/AudioManager.java
index 28c75c5..6dce995 100644
--- a/src/main/java/com/bbn/hadder/audio/AudioManager.java
+++ b/src/main/java/one/bbn/hadder/audio/AudioManager.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,10 +14,10 @@
* limitations under the License.
*/
-package com.bbn.hadder.audio;
+package one.bbn.hadder.audio;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.MessageEditor;
import com.sedmelluq.discord.lavaplayer.player.AudioLoadResultHandler;
import com.sedmelluq.discord.lavaplayer.player.AudioPlayer;
import com.sedmelluq.discord.lavaplayer.player.AudioPlayerManager;
diff --git a/src/main/java/com/bbn/hadder/audio/AudioPlayerSendHandler.java b/src/main/java/one/bbn/hadder/audio/AudioPlayerSendHandler.java
similarity index 97%
rename from src/main/java/com/bbn/hadder/audio/AudioPlayerSendHandler.java
rename to src/main/java/one/bbn/hadder/audio/AudioPlayerSendHandler.java
index eb4f330..6d249c9 100644
--- a/src/main/java/com/bbn/hadder/audio/AudioPlayerSendHandler.java
+++ b/src/main/java/one/bbn/hadder/audio/AudioPlayerSendHandler.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-package com.bbn.hadder.audio;
+package one.bbn.hadder.audio;
import com.sedmelluq.discord.lavaplayer.player.AudioPlayer;
import com.sedmelluq.discord.lavaplayer.track.playback.AudioFrame;
diff --git a/src/main/java/com/bbn/hadder/audio/TrackManager.java b/src/main/java/one/bbn/hadder/audio/TrackManager.java
similarity index 97%
rename from src/main/java/com/bbn/hadder/audio/TrackManager.java
rename to src/main/java/one/bbn/hadder/audio/TrackManager.java
index 423cc35..b26be3f 100644
--- a/src/main/java/com/bbn/hadder/audio/TrackManager.java
+++ b/src/main/java/one/bbn/hadder/audio/TrackManager.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-package com.bbn.hadder.audio;
+package one.bbn.hadder.audio;
import com.sedmelluq.discord.lavaplayer.player.AudioPlayer;
import com.sedmelluq.discord.lavaplayer.player.event.AudioEventAdapter;
diff --git a/src/main/java/com/bbn/hadder/commands/Command.java b/src/main/java/one/bbn/hadder/commands/Command.java
similarity index 89%
rename from src/main/java/com/bbn/hadder/commands/Command.java
rename to src/main/java/one/bbn/hadder/commands/Command.java
index ae80476..894f70f 100644
--- a/src/main/java/com/bbn/hadder/commands/Command.java
+++ b/src/main/java/one/bbn/hadder/commands/Command.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands;
+package one.bbn.hadder.commands;
public interface Command {
void executed(String[] args, CommandEvent e);
diff --git a/src/main/java/com/bbn/hadder/commands/CommandEvent.java b/src/main/java/one/bbn/hadder/commands/CommandEvent.java
similarity index 66%
rename from src/main/java/com/bbn/hadder/commands/CommandEvent.java
rename to src/main/java/one/bbn/hadder/commands/CommandEvent.java
index ad56b79..8aedb09 100644
--- a/src/main/java/com/bbn/hadder/commands/CommandEvent.java
+++ b/src/main/java/one/bbn/hadder/commands/CommandEvent.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,17 +14,17 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands;
+package one.bbn.hadder.commands;
-import com.bbn.hadder.audio.AudioManager;
-import com.bbn.hadder.commands.general.HelpCommand;
-import com.bbn.hadder.core.CommandHandler;
-import com.bbn.hadder.core.Config;
-import com.bbn.hadder.db.Rethink;
-import com.bbn.hadder.db.RethinkServer;
-import com.bbn.hadder.db.RethinkUser;
-import com.bbn.hadder.utils.EventWaiter;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.audio.AudioManager;
+import one.bbn.hadder.commands.general.HelpCommand;
+import one.bbn.hadder.core.CommandHandler;
+import one.bbn.hadder.core.Config;
+import one.bbn.hadder.db.Mongo;
+import one.bbn.hadder.db.MongoServer;
+import one.bbn.hadder.db.MongoUser;
+import one.bbn.hadder.utils.EventWaiter;
+import one.bbn.hadder.utils.MessageEditor;
import net.dv8tion.jda.api.JDA;
import net.dv8tion.jda.api.entities.Message;
import net.dv8tion.jda.api.events.message.MessageReceivedEvent;
@@ -33,34 +33,34 @@ import javax.annotation.Nonnull;
public class CommandEvent extends MessageReceivedEvent {
- private Rethink rethink;
+ private Mongo mongo;
private Config config;
private CommandHandler commandHandler;
private HelpCommand helpCommand;
private MessageEditor messageEditor;
private EventWaiter eventWaiter;
private AudioManager audioManager;
- private RethinkUser rethinkUser;
- private RethinkServer rethinkServer;
+ private MongoUser mongoUser;
+ private MongoServer mongoServer;
- public CommandEvent(@Nonnull JDA api, long responseNumber, @Nonnull Message message, Rethink rethink, Config config,
+ public CommandEvent(@Nonnull JDA api, long responseNumber, @Nonnull Message message, Mongo mongo, Config config,
CommandHandler commandHandler, HelpCommand helpCommand, MessageEditor messageEditor,
- EventWaiter eventWaiter, AudioManager audioManager, RethinkUser rethinkUser,
- RethinkServer rethinkServer) {
+ EventWaiter eventWaiter, AudioManager audioManager, MongoUser mongoUser,
+ MongoServer mongoServer) {
super(api, responseNumber, message);
- this.rethink = rethink;
+ this.mongo = mongo;
this.config = config;
this.commandHandler = commandHandler;
this.helpCommand = helpCommand;
this.messageEditor = messageEditor;
this.eventWaiter = eventWaiter;
this.audioManager = audioManager;
- this.rethinkUser = rethinkUser;
- this.rethinkServer = rethinkServer;
+ this.mongoUser = mongoUser;
+ this.mongoServer = mongoServer;
}
- public Rethink getRethink() {
- return rethink;
+ public Mongo getMongo() {
+ return mongo;
}
public Config getConfig() {
@@ -87,11 +87,11 @@ public class CommandEvent extends MessageReceivedEvent {
return audioManager;
}
- public RethinkServer getRethinkServer() {
- return rethinkServer;
+ public MongoServer getMongoServer() {
+ return mongoServer;
}
- public RethinkUser getRethinkUser() {
- return rethinkUser;
+ public MongoUser getMongoUser() {
+ return mongoUser;
}
}
diff --git a/src/main/java/com/bbn/hadder/commands/fun/AvatarCommand.java b/src/main/java/one/bbn/hadder/commands/fun/AvatarCommand.java
similarity index 95%
rename from src/main/java/com/bbn/hadder/commands/fun/AvatarCommand.java
rename to src/main/java/one/bbn/hadder/commands/fun/AvatarCommand.java
index 361284b..1007f61 100644
--- a/src/main/java/com/bbn/hadder/commands/fun/AvatarCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/fun/AvatarCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,11 +14,11 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.fun;
+package one.bbn.hadder.commands.fun;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.MessageEditor;
import net.dv8tion.jda.api.entities.User;
import okhttp3.OkHttpClient;
import okhttp3.Request;
diff --git a/src/main/java/com/bbn/hadder/commands/fun/ClydeCommand.java b/src/main/java/one/bbn/hadder/commands/fun/ClydeCommand.java
similarity index 88%
rename from src/main/java/com/bbn/hadder/commands/fun/ClydeCommand.java
rename to src/main/java/one/bbn/hadder/commands/fun/ClydeCommand.java
index 0101020..d80576f 100644
--- a/src/main/java/com/bbn/hadder/commands/fun/ClydeCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/fun/ClydeCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,15 +14,15 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.fun;
+package one.bbn.hadder.commands.fun;
import club.minnced.discord.webhook.WebhookClient;
import club.minnced.discord.webhook.WebhookClientBuilder;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.core.Perm;
-import com.bbn.hadder.core.Perms;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.core.Perm;
+import one.bbn.hadder.core.Perms;
+import one.bbn.hadder.utils.MessageEditor;
import net.dv8tion.jda.api.Permission;
import net.dv8tion.jda.api.entities.Icon;
import net.dv8tion.jda.api.entities.TextChannel;
@@ -40,7 +40,7 @@ public class ClydeCommand implements Command {
if (args.length > 0) {
if (e.getGuild().getSelfMember().hasPermission(Permission.MANAGE_WEBHOOKS)) {
TextChannel channel = e.getMessage().getTextChannel();
- String content = e.getMessage().getContentRaw().replace(e.getRethinkServer().getPrefix(), "").replace(e.getRethinkUser().getPrefix(), "").replace("clyde", "");
+ String content = e.getMessage().getContentRaw().replace(e.getMongoServer().getPrefix(), "").replace(e.getMongoUser().getPrefix(), "").replace("clyde", "");
Webhook webhook = channel.createWebhook(e.getConfig().getClydeName()).complete();
try {
diff --git a/src/main/java/com/bbn/hadder/commands/fun/GifCommand.java b/src/main/java/one/bbn/hadder/commands/fun/GifCommand.java
similarity index 92%
rename from src/main/java/com/bbn/hadder/commands/fun/GifCommand.java
rename to src/main/java/one/bbn/hadder/commands/fun/GifCommand.java
index 239e681..015d2d3 100644
--- a/src/main/java/com/bbn/hadder/commands/fun/GifCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/fun/GifCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,11 +14,11 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.fun;
+package one.bbn.hadder.commands.fun;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.MessageEditor;
import okhttp3.OkHttpClient;
import okhttp3.Request;
import okhttp3.Response;
diff --git a/src/main/java/com/bbn/hadder/commands/fun/MemeCommand.java b/src/main/java/one/bbn/hadder/commands/fun/MemeCommand.java
similarity index 91%
rename from src/main/java/com/bbn/hadder/commands/fun/MemeCommand.java
rename to src/main/java/one/bbn/hadder/commands/fun/MemeCommand.java
index 3bf9ebc..345edc1 100644
--- a/src/main/java/com/bbn/hadder/commands/fun/MemeCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/fun/MemeCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,11 +14,11 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.fun;
+package one.bbn.hadder.commands.fun;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.MessageEditor;
import okhttp3.OkHttpClient;
import okhttp3.Request;
import okhttp3.Response;
diff --git a/src/main/java/com/bbn/hadder/commands/general/AboutCommand.java b/src/main/java/one/bbn/hadder/commands/general/AboutCommand.java
similarity index 88%
rename from src/main/java/com/bbn/hadder/commands/general/AboutCommand.java
rename to src/main/java/one/bbn/hadder/commands/general/AboutCommand.java
index 4bb3188..09678dd 100644
--- a/src/main/java/com/bbn/hadder/commands/general/AboutCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/general/AboutCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,11 +14,11 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.general;
+package one.bbn.hadder.commands.general;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.MessageEditor;
public class AboutCommand implements Command {
diff --git a/src/main/java/com/bbn/hadder/commands/general/EqualsCommand.java b/src/main/java/one/bbn/hadder/commands/general/EqualsCommand.java
similarity index 91%
rename from src/main/java/com/bbn/hadder/commands/general/EqualsCommand.java
rename to src/main/java/one/bbn/hadder/commands/general/EqualsCommand.java
index 2144fd7..c197c49 100644
--- a/src/main/java/com/bbn/hadder/commands/general/EqualsCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/general/EqualsCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,12 +14,12 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.general;
+package one.bbn.hadder.commands.general;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.EventWaiter;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.EventWaiter;
+import one.bbn.hadder.utils.MessageEditor;
public class EqualsCommand implements Command {
diff --git a/src/main/java/com/bbn/hadder/commands/general/HelpCommand.java b/src/main/java/one/bbn/hadder/commands/general/HelpCommand.java
similarity index 90%
rename from src/main/java/com/bbn/hadder/commands/general/HelpCommand.java
rename to src/main/java/one/bbn/hadder/commands/general/HelpCommand.java
index d643576..a449d14 100644
--- a/src/main/java/com/bbn/hadder/commands/general/HelpCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/general/HelpCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,11 +14,11 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.general;
+package one.bbn.hadder.commands.general;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.MessageEditor;
import net.dv8tion.jda.api.EmbedBuilder;
import net.dv8tion.jda.api.Permission;
@@ -79,10 +79,10 @@ public class HelpCommand implements Command {
StringBuilder b = new StringBuilder();
b.append(e.getMessageEditor().getTerm("commands.general.help.description")).append(" ").append(e.getMessageEditor().getTerm(cmd.description())).append("\n");
if (cmd.usage() != null) {
- b.append(e.getMessageEditor().getTerm("commands.general.help.usage")).append(" ").append(e.getRethinkServer().getPrefix()).append(name).append(" ").append(cmd.usage()).append("\n");
+ b.append(e.getMessageEditor().getTerm("commands.general.help.usage")).append(" ").append(e.getMongoServer().getPrefix()).append(name).append(" ").append(cmd.usage()).append("\n");
}
if (cmd.example() != null) {
- b.append(e.getMessageEditor().getTerm("commands.general.help.example")).append(" ").append(e.getRethinkServer().getPrefix()).append(name).append(" ").append(cmd.example());
+ b.append(e.getMessageEditor().getTerm("commands.general.help.example")).append(" ").append(e.getMongoServer().getPrefix()).append(name).append(" ").append(cmd.example());
}
e.getChannel().sendMessage(e.getMessageEditor().getMessage(
MessageEditor.MessageType.INFO)
diff --git a/src/main/java/com/bbn/hadder/commands/general/InviteCommand.java b/src/main/java/one/bbn/hadder/commands/general/InviteCommand.java
similarity index 88%
rename from src/main/java/com/bbn/hadder/commands/general/InviteCommand.java
rename to src/main/java/one/bbn/hadder/commands/general/InviteCommand.java
index feabf9a..900a249 100644
--- a/src/main/java/com/bbn/hadder/commands/general/InviteCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/general/InviteCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,11 +14,11 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.general;
+package one.bbn.hadder.commands.general;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.MessageEditor;
public class InviteCommand implements Command {
diff --git a/src/main/java/com/bbn/hadder/commands/general/PingCommand.java b/src/main/java/one/bbn/hadder/commands/general/PingCommand.java
similarity index 85%
rename from src/main/java/com/bbn/hadder/commands/general/PingCommand.java
rename to src/main/java/one/bbn/hadder/commands/general/PingCommand.java
index cfec2b2..eef7207 100644
--- a/src/main/java/com/bbn/hadder/commands/general/PingCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/general/PingCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,11 +14,11 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.general;
+package one.bbn.hadder.commands.general;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.MessageEditor;
public class PingCommand implements Command {
diff --git a/src/main/java/com/bbn/hadder/commands/misc/CodeCommand.java b/src/main/java/one/bbn/hadder/commands/misc/CodeCommand.java
similarity index 93%
rename from src/main/java/com/bbn/hadder/commands/misc/CodeCommand.java
rename to src/main/java/one/bbn/hadder/commands/misc/CodeCommand.java
index 443331c..4905c1b 100644
--- a/src/main/java/com/bbn/hadder/commands/misc/CodeCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/misc/CodeCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,11 +14,11 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.misc;
+package one.bbn.hadder.commands.misc;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.MessageEditor;
import okhttp3.OkHttpClient;
import okhttp3.Request;
import okhttp3.Response;
diff --git a/src/main/java/com/bbn/hadder/commands/misc/CoronaCommand.java b/src/main/java/one/bbn/hadder/commands/misc/CoronaCommand.java
similarity index 91%
rename from src/main/java/com/bbn/hadder/commands/misc/CoronaCommand.java
rename to src/main/java/one/bbn/hadder/commands/misc/CoronaCommand.java
index 3f357ae..85a270c 100644
--- a/src/main/java/com/bbn/hadder/commands/misc/CoronaCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/misc/CoronaCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,11 +14,11 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.misc;
+package one.bbn.hadder.commands.misc;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.MessageEditor;
import okhttp3.OkHttpClient;
import okhttp3.Request;
import okhttp3.Response;
diff --git a/src/main/java/com/bbn/hadder/commands/misc/FeedbackCommand.java b/src/main/java/one/bbn/hadder/commands/misc/FeedbackCommand.java
similarity index 92%
rename from src/main/java/com/bbn/hadder/commands/misc/FeedbackCommand.java
rename to src/main/java/one/bbn/hadder/commands/misc/FeedbackCommand.java
index 68bbb77..849f526 100644
--- a/src/main/java/com/bbn/hadder/commands/misc/FeedbackCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/misc/FeedbackCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,12 +14,12 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.misc;
+package one.bbn.hadder.commands.misc;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.EventWaiter;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.EventWaiter;
+import one.bbn.hadder.utils.MessageEditor;
import org.kohsuke.github.GHIssue;
import org.kohsuke.github.GHRepository;
import org.kohsuke.github.GitHub;
diff --git a/src/main/java/com/bbn/hadder/commands/misc/GitHubCommand.java b/src/main/java/one/bbn/hadder/commands/misc/GitHubCommand.java
similarity index 96%
rename from src/main/java/com/bbn/hadder/commands/misc/GitHubCommand.java
rename to src/main/java/one/bbn/hadder/commands/misc/GitHubCommand.java
index 606c9bb..08646dd 100644
--- a/src/main/java/com/bbn/hadder/commands/misc/GitHubCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/misc/GitHubCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,11 +14,11 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.misc;
+package one.bbn.hadder.commands.misc;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.MessageEditor;
import okhttp3.OkHttpClient;
import okhttp3.Request;
import okhttp3.Response;
diff --git a/src/main/java/com/bbn/hadder/commands/misc/MoveAllCommand.java b/src/main/java/one/bbn/hadder/commands/misc/MoveAllCommand.java
similarity index 94%
rename from src/main/java/com/bbn/hadder/commands/misc/MoveAllCommand.java
rename to src/main/java/one/bbn/hadder/commands/misc/MoveAllCommand.java
index 1ac3464..e382064 100644
--- a/src/main/java/com/bbn/hadder/commands/misc/MoveAllCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/misc/MoveAllCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,13 +14,13 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.misc;
+package one.bbn.hadder.commands.misc;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.core.Perm;
-import com.bbn.hadder.core.Perms;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.core.Perm;
+import one.bbn.hadder.core.Perms;
+import one.bbn.hadder.utils.MessageEditor;
import org.apache.commons.lang3.StringUtils;
@Perms(Perm.VOICE_MOVE_OTHERS)
diff --git a/src/main/java/com/bbn/hadder/commands/misc/ProfileCommand.java b/src/main/java/one/bbn/hadder/commands/misc/ProfileCommand.java
similarity index 94%
rename from src/main/java/com/bbn/hadder/commands/misc/ProfileCommand.java
rename to src/main/java/one/bbn/hadder/commands/misc/ProfileCommand.java
index 87d1901..78d017a 100644
--- a/src/main/java/com/bbn/hadder/commands/misc/ProfileCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/misc/ProfileCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,11 +14,11 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.misc;
+package one.bbn.hadder.commands.misc;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.MessageEditor;
import net.dv8tion.jda.api.EmbedBuilder;
import net.dv8tion.jda.api.entities.User;
import org.apache.commons.lang3.StringUtils;
diff --git a/src/main/java/com/bbn/hadder/commands/misc/ScreenShareCommand.java b/src/main/java/one/bbn/hadder/commands/misc/ScreenShareCommand.java
similarity index 91%
rename from src/main/java/com/bbn/hadder/commands/misc/ScreenShareCommand.java
rename to src/main/java/one/bbn/hadder/commands/misc/ScreenShareCommand.java
index 65cd24d..f789f4a 100644
--- a/src/main/java/com/bbn/hadder/commands/misc/ScreenShareCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/misc/ScreenShareCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,13 +14,12 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.misc;
+package one.bbn.hadder.commands.misc;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.EventWaiter;
-import com.bbn.hadder.utils.MessageEditor;
-import com.bbn.hadder.utils.MessageEditor.MessageType;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.EventWaiter;
+import one.bbn.hadder.utils.MessageEditor;
import net.dv8tion.jda.api.EmbedBuilder;
import net.dv8tion.jda.api.entities.VoiceChannel;
@@ -44,7 +43,7 @@ public class ScreenShareCommand implements Command {
} else {
List vcs = e.getGuild().getVoiceChannelsByName(String.join(" ", args), true);
if (vcs.size() > 1) {
- EmbedBuilder eb = e.getMessageEditor().getMessage(MessageType.WARNING, "commands.misc.screenshare.channel.error.title", "commands.misc.screenshare.channel.error.description");
+ EmbedBuilder eb = e.getMessageEditor().getMessage(MessageEditor.MessageType.WARNING, "commands.misc.screenshare.channel.error.title", "commands.misc.screenshare.channel.error.description");
for (int i = 0; i < vcs.size(); i++) {
VoiceChannel voiceChannel = vcs.get(i);
eb.addField(i + ": " + voiceChannel.getName(), voiceChannel.getId(), false);
diff --git a/src/main/java/com/bbn/hadder/commands/misc/ServerStatsCommand.java b/src/main/java/one/bbn/hadder/commands/misc/ServerStatsCommand.java
similarity index 94%
rename from src/main/java/com/bbn/hadder/commands/misc/ServerStatsCommand.java
rename to src/main/java/one/bbn/hadder/commands/misc/ServerStatsCommand.java
index 9d31c5c..b51df9b 100644
--- a/src/main/java/com/bbn/hadder/commands/misc/ServerStatsCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/misc/ServerStatsCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,11 +14,11 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.misc;
+package one.bbn.hadder.commands.misc;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.MessageEditor;
import net.dv8tion.jda.api.EmbedBuilder;
import java.util.Date;
diff --git a/src/main/java/com/bbn/hadder/commands/moderation/BanCommand.java b/src/main/java/one/bbn/hadder/commands/moderation/BanCommand.java
similarity index 94%
rename from src/main/java/com/bbn/hadder/commands/moderation/BanCommand.java
rename to src/main/java/one/bbn/hadder/commands/moderation/BanCommand.java
index d179018..f3c779a 100644
--- a/src/main/java/com/bbn/hadder/commands/moderation/BanCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/moderation/BanCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,13 +14,13 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.moderation;
+package one.bbn.hadder.commands.moderation;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.core.Perm;
-import com.bbn.hadder.core.Perms;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.core.Perm;
+import one.bbn.hadder.core.Perms;
+import one.bbn.hadder.utils.MessageEditor;
import net.dv8tion.jda.api.entities.Member;
@Perms(Perm.BAN_MEMBERS)
diff --git a/src/main/java/com/bbn/hadder/commands/moderation/ClearCommand.java b/src/main/java/one/bbn/hadder/commands/moderation/ClearCommand.java
similarity index 94%
rename from src/main/java/com/bbn/hadder/commands/moderation/ClearCommand.java
rename to src/main/java/one/bbn/hadder/commands/moderation/ClearCommand.java
index d595aa7..923da57 100644
--- a/src/main/java/com/bbn/hadder/commands/moderation/ClearCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/moderation/ClearCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,13 +14,13 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.moderation;
+package one.bbn.hadder.commands.moderation;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.core.Perm;
-import com.bbn.hadder.core.Perms;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.core.Perm;
+import one.bbn.hadder.core.Perms;
+import one.bbn.hadder.utils.MessageEditor;
import net.dv8tion.jda.api.Permission;
import net.dv8tion.jda.api.entities.Message;
diff --git a/src/main/java/com/bbn/hadder/commands/moderation/EditRulesCommand.java b/src/main/java/one/bbn/hadder/commands/moderation/EditRulesCommand.java
similarity index 87%
rename from src/main/java/com/bbn/hadder/commands/moderation/EditRulesCommand.java
rename to src/main/java/one/bbn/hadder/commands/moderation/EditRulesCommand.java
index 7b6b70b..757bf53 100644
--- a/src/main/java/com/bbn/hadder/commands/moderation/EditRulesCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/moderation/EditRulesCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,13 +14,13 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.moderation;
+package one.bbn.hadder.commands.moderation;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.core.Perm;
-import com.bbn.hadder.core.Perms;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.core.Perm;
+import one.bbn.hadder.core.Perms;
+import one.bbn.hadder.utils.MessageEditor;
import net.dv8tion.jda.api.entities.TextChannel;
@Perms(Perm.MANAGE_SERVER)
@@ -28,7 +28,7 @@ public class EditRulesCommand implements Command {
@Override
public void executed(String[] args, CommandEvent e) {
- if (e.getRethinkServer().getMessageID().length() == 18) {
+ if (e.getMongoServer().getMessageID().length() == 18) {
e.getTextChannel().sendMessage(e.getMessageEditor().getMessage(MessageEditor.MessageType.INFO,
"commands.moderation.editrules.message.title",
"commands.moderation.editrules.message.description").build()).queue();
@@ -68,13 +68,13 @@ public class EditRulesCommand implements Command {
} else {
e.getTextChannel().sendMessage(e.getMessageEditor().getMessage(MessageEditor.MessageType.ERROR,
"commands.moderation.editrules.error.title", "",
- "commands.moderation.editrules.error.description", e.getRethinkServer().getPrefix()).build()).queue();
+ "commands.moderation.editrules.error.description", e.getMongoServer().getPrefix()).build()).queue();
}
}
public void checkChannel(CommandEvent e, String rules, TextChannel channel) {
try {
- channel.retrieveMessageById(e.getRethinkServer().getMessageID()).queue();
+ channel.retrieveMessageById(e.getMongoServer().getMessageID()).queue();
setRules(e, rules, channel);
e.getTextChannel().sendMessage(e.getMessageEditor().getMessage(MessageEditor.MessageType.INFO,
"commands.moderation.editrules.success.title",
@@ -87,7 +87,7 @@ public class EditRulesCommand implements Command {
}
public void setRules(CommandEvent e, String rules, TextChannel channel) {
- channel.retrieveMessageById(e.getRethinkServer().getMessageID()).complete().editMessage(e.getMessageEditor().getMessage(MessageEditor.MessageType.INFO)
+ channel.retrieveMessageById(e.getMongoServer().getMessageID()).complete().editMessage(e.getMessageEditor().getMessage(MessageEditor.MessageType.INFO)
.setTitle("Rules")
.setDescription(rules)
.build()).queue();
diff --git a/src/main/java/com/bbn/hadder/commands/moderation/InviteDetectCommand.java b/src/main/java/one/bbn/hadder/commands/moderation/InviteDetectCommand.java
similarity index 83%
rename from src/main/java/com/bbn/hadder/commands/moderation/InviteDetectCommand.java
rename to src/main/java/one/bbn/hadder/commands/moderation/InviteDetectCommand.java
index 8b876d1..2fe4f67 100644
--- a/src/main/java/com/bbn/hadder/commands/moderation/InviteDetectCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/moderation/InviteDetectCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,13 +14,13 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.moderation;
+package one.bbn.hadder.commands.moderation;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.core.Perm;
-import com.bbn.hadder.core.Perms;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.core.Perm;
+import one.bbn.hadder.core.Perms;
+import one.bbn.hadder.utils.MessageEditor;
@Perms(Perm.MANAGE_SERVER)
public class InviteDetectCommand implements Command {
@@ -31,15 +31,15 @@ public class InviteDetectCommand implements Command {
String opinion = args[0].toLowerCase();
switch (opinion) {
case "on":
- if (!e.getRethinkServer().hasInviteDetect()) {
- e.getRethinkServer().setInviteDetect(true);
+ if (!e.getMongoServer().hasInviteDetect()) {
+ e.getMongoServer().setInviteDetect(true);
e.getTextChannel().sendMessage(
e.getMessageEditor().getMessage(
MessageEditor.MessageType.INFO,
"commands.moderation.invitedetect.activate.success.title",
"commands.moderation.invitedetect.activate.success.description")
.build()).queue();
- e.getRethinkServer().push();
+ e.getMongoServer().push();
} else {
e.getTextChannel().sendMessage(e.getMessageEditor().getMessage(
MessageEditor.MessageType.ERROR,
@@ -50,14 +50,14 @@ public class InviteDetectCommand implements Command {
break;
case "off":
- if (e.getRethinkServer().hasInviteDetect()) {
- e.getRethinkServer().setInviteDetect(false);
+ if (e.getMongoServer().hasInviteDetect()) {
+ e.getMongoServer().setInviteDetect(false);
e.getTextChannel().sendMessage(e.getMessageEditor().getMessage(
MessageEditor.MessageType.INFO,
"commands.moderation.invitedetect.deactivate.success.title",
"commands.moderation.invitedetect.deactivate.success.description")
.build()).queue();
- e.getRethinkServer().push();
+ e.getMongoServer().push();
} else {
e.getTextChannel().sendMessage(e.getMessageEditor().getMessage(
MessageEditor.MessageType.ERROR,
diff --git a/src/main/java/com/bbn/hadder/commands/moderation/KickCommand.java b/src/main/java/one/bbn/hadder/commands/moderation/KickCommand.java
similarity index 94%
rename from src/main/java/com/bbn/hadder/commands/moderation/KickCommand.java
rename to src/main/java/one/bbn/hadder/commands/moderation/KickCommand.java
index 5784644..d94224d 100644
--- a/src/main/java/com/bbn/hadder/commands/moderation/KickCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/moderation/KickCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,13 +14,13 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.moderation;
+package one.bbn.hadder.commands.moderation;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.core.Perm;
-import com.bbn.hadder.core.Perms;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.core.Perm;
+import one.bbn.hadder.core.Perms;
+import one.bbn.hadder.utils.MessageEditor;
import net.dv8tion.jda.api.entities.Member;
@Perms(Perm.KICK_MEMBERS)
diff --git a/src/main/java/com/bbn/hadder/commands/moderation/NickCommand.java b/src/main/java/one/bbn/hadder/commands/moderation/NickCommand.java
similarity index 87%
rename from src/main/java/com/bbn/hadder/commands/moderation/NickCommand.java
rename to src/main/java/one/bbn/hadder/commands/moderation/NickCommand.java
index 40415bd..8d277fa 100644
--- a/src/main/java/com/bbn/hadder/commands/moderation/NickCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/moderation/NickCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,13 +14,13 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.moderation;
+package one.bbn.hadder.commands.moderation;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.core.Perm;
-import com.bbn.hadder.core.Perms;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.core.Perm;
+import one.bbn.hadder.core.Perms;
+import one.bbn.hadder.utils.MessageEditor;
import net.dv8tion.jda.api.Permission;
import net.dv8tion.jda.api.entities.Member;
@@ -34,8 +34,8 @@ public class NickCommand implements Command {
if (!e.getMessage().getMentionedMembers().get(0).getId().equals(e.getGuild().getSelfMember().getId())) {
if (e.getGuild().getSelfMember().canInteract(e.getMessage().getMentionedMembers().get(0))) {
if (args.length > 1) {
- if (e.getMessage().getContentRaw().startsWith(e.getRethinkUser().getPrefix())) {
- e.getGuild().modifyNickname(e.getMessage().getMentionedMembers().get(0), e.getMessage().getContentRaw().replaceFirst(e.getRethinkUser().getPrefix() + "nick " + args[0], "")).reason("Nicked by " + e.getAuthor().getAsTag()).queue();
+ if (e.getMessage().getContentRaw().startsWith(e.getMongoUser().getPrefix())) {
+ e.getGuild().modifyNickname(e.getMessage().getMentionedMembers().get(0), e.getMessage().getContentRaw().replaceFirst(e.getMongoUser().getPrefix() + "nick " + args[0], "")).reason("Nicked by " + e.getAuthor().getAsTag()).queue();
e.getTextChannel().sendMessage(
e.getMessageEditor().getMessage(
MessageEditor.MessageType.INFO,
@@ -44,8 +44,8 @@ public class NickCommand implements Command {
"commands.moderation.nick.success.description",
e.getMessage().getMentionedMembers().get(0).getUser().getAsTag()
).build()).queue();
- } else if (e.getMessage().getContentRaw().startsWith(e.getRethinkServer().getPrefix())) {
- e.getGuild().modifyNickname(e.getMessage().getMentionedMembers().get(0), e.getMessage().getContentRaw().replaceFirst(e.getRethinkServer().getPrefix() + "nick " + args[0], "")).reason("Nicked by " + e.getAuthor().getAsTag()).queue();
+ } else if (e.getMessage().getContentRaw().startsWith(e.getMongoServer().getPrefix())) {
+ e.getGuild().modifyNickname(e.getMessage().getMentionedMembers().get(0), e.getMessage().getContentRaw().replaceFirst(e.getMongoServer().getPrefix() + "nick " + args[0], "")).reason("Nicked by " + e.getAuthor().getAsTag()).queue();
e.getTextChannel().sendMessage(
e.getMessageEditor().getMessage(
MessageEditor.MessageType.INFO,
@@ -59,8 +59,8 @@ public class NickCommand implements Command {
e.getTextChannel().sendMessage(e.getMessageEditor().getMessage(MessageEditor.MessageType.NO_SELF_PERMISSION).build()).queue();
}
} else {
- if (e.getMessage().getContentRaw().startsWith(e.getRethinkUser().getPrefix())) {
- e.getGuild().getSelfMember().modifyNickname(e.getMessage().getContentRaw().replaceFirst(e.getRethinkUser().getPrefix() + "nick " + args[0], "")).reason("Nicked by " + e.getAuthor().getAsTag()).queue();
+ if (e.getMessage().getContentRaw().startsWith(e.getMongoUser().getPrefix())) {
+ e.getGuild().getSelfMember().modifyNickname(e.getMessage().getContentRaw().replaceFirst(e.getMongoUser().getPrefix() + "nick " + args[0], "")).reason("Nicked by " + e.getAuthor().getAsTag()).queue();
e.getTextChannel().sendMessage(
e.getMessageEditor().getMessage(
MessageEditor.MessageType.INFO,
@@ -68,8 +68,8 @@ public class NickCommand implements Command {
"✅",
"commands.moderation.nick.myself.success.description",
"").build()).queue();
- } else if (e.getMessage().getContentRaw().startsWith(e.getRethinkServer().getPrefix())) {
- e.getGuild().getSelfMember().modifyNickname(e.getMessage().getContentRaw().replaceFirst(e.getRethinkServer().getPrefix() + "nick " + args[0], "")).reason("Nicked by " + e.getAuthor().getAsTag()).queue();
+ } else if (e.getMessage().getContentRaw().startsWith(e.getMongoServer().getPrefix())) {
+ e.getGuild().getSelfMember().modifyNickname(e.getMessage().getContentRaw().replaceFirst(e.getMongoServer().getPrefix() + "nick " + args[0], "")).reason("Nicked by " + e.getAuthor().getAsTag()).queue();
e.getTextChannel().sendMessage(
e.getMessageEditor().getMessage(
MessageEditor.MessageType.INFO,
diff --git a/src/main/java/com/bbn/hadder/commands/moderation/PrefixCommand.java b/src/main/java/one/bbn/hadder/commands/moderation/PrefixCommand.java
similarity index 83%
rename from src/main/java/com/bbn/hadder/commands/moderation/PrefixCommand.java
rename to src/main/java/one/bbn/hadder/commands/moderation/PrefixCommand.java
index 7b4737b..26e578a 100644
--- a/src/main/java/com/bbn/hadder/commands/moderation/PrefixCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/moderation/PrefixCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,13 +14,13 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.moderation;
+package one.bbn.hadder.commands.moderation;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.core.Perm;
-import com.bbn.hadder.core.Perms;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.core.Perm;
+import one.bbn.hadder.core.Perms;
+import one.bbn.hadder.utils.MessageEditor;
@Perms(Perm.MANAGE_SERVER)
public class PrefixCommand implements Command {
@@ -29,8 +29,8 @@ public class PrefixCommand implements Command {
public void executed(String[] args, CommandEvent e) {
if (args.length == 1) {
if (!args[0].contains("\"")) {
- e.getRethinkServer().setPrefix(args[0]);
- e.getRethinkServer().push();
+ e.getMongoServer().setPrefix(args[0]);
+ e.getMongoServer().push();
e.getTextChannel().sendMessage(e.getMessageEditor().getMessage(
MessageEditor.MessageType.INFO,
"commands.moderation.prefix.success.title",
diff --git a/src/main/java/com/bbn/hadder/commands/moderation/RegionChangeCommand.java b/src/main/java/one/bbn/hadder/commands/moderation/RegionChangeCommand.java
similarity index 95%
rename from src/main/java/com/bbn/hadder/commands/moderation/RegionChangeCommand.java
rename to src/main/java/one/bbn/hadder/commands/moderation/RegionChangeCommand.java
index a72c608..220dcdb 100644
--- a/src/main/java/com/bbn/hadder/commands/moderation/RegionChangeCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/moderation/RegionChangeCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,13 +14,13 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.moderation;
+package one.bbn.hadder.commands.moderation;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.core.Perm;
-import com.bbn.hadder.core.Perms;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.core.Perm;
+import one.bbn.hadder.core.Perms;
+import one.bbn.hadder.utils.MessageEditor;
import net.dv8tion.jda.api.Permission;
import net.dv8tion.jda.api.Region;
diff --git a/src/main/java/com/bbn/hadder/commands/moderation/RoleCommand.java b/src/main/java/one/bbn/hadder/commands/moderation/RoleCommand.java
similarity index 95%
rename from src/main/java/com/bbn/hadder/commands/moderation/RoleCommand.java
rename to src/main/java/one/bbn/hadder/commands/moderation/RoleCommand.java
index 9094bcd..13d6923 100644
--- a/src/main/java/com/bbn/hadder/commands/moderation/RoleCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/moderation/RoleCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,13 +14,13 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.moderation;
+package one.bbn.hadder.commands.moderation;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.core.Perm;
-import com.bbn.hadder.core.Perms;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.core.Perm;
+import one.bbn.hadder.core.Perms;
+import one.bbn.hadder.utils.MessageEditor;
import net.dv8tion.jda.api.Permission;
import net.dv8tion.jda.api.entities.Member;
import net.dv8tion.jda.api.entities.Role;
diff --git a/src/main/java/com/bbn/hadder/commands/moderation/RulesCommand.java b/src/main/java/one/bbn/hadder/commands/moderation/RulesCommand.java
similarity index 95%
rename from src/main/java/com/bbn/hadder/commands/moderation/RulesCommand.java
rename to src/main/java/one/bbn/hadder/commands/moderation/RulesCommand.java
index e797080..33f8a20 100644
--- a/src/main/java/com/bbn/hadder/commands/moderation/RulesCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/moderation/RulesCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,14 +14,14 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.moderation;
+package one.bbn.hadder.commands.moderation;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.core.Perm;
-import com.bbn.hadder.core.Perms;
-import com.bbn.hadder.utils.EventWaiter;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.core.Perm;
+import one.bbn.hadder.core.Perms;
+import one.bbn.hadder.utils.EventWaiter;
+import one.bbn.hadder.utils.MessageEditor;
import net.dv8tion.jda.api.Permission;
import net.dv8tion.jda.api.entities.Emote;
import net.dv8tion.jda.api.entities.Message;
@@ -174,8 +174,8 @@ public class RulesCommand implements Command {
.build()).queue();
ex.printStackTrace();
}
- e.getRethinkServer().updateRules(rules.getId(), role.getId(), aemote.toString(), demote.toString());
- e.getRethinkServer().push();
+ e.getMongoServer().updateRules(rules.getId(), role.getId(), aemote.toString(), demote.toString());
+ e.getMongoServer().push();
} else {
e.getTextChannel().sendMessage(
e.getMessageEditor().getMessage(
@@ -220,8 +220,8 @@ public class RulesCommand implements Command {
.build()).queue();
ex.printStackTrace();
}
- e.getRethinkServer().updateRules(rules.getId(), role.getId(), aemote, demote);
- e.getRethinkServer().push();
+ e.getMongoServer().updateRules(rules.getId(), role.getId(), aemote, demote);
+ e.getMongoServer().push();
} else {
e.getTextChannel().sendMessage(
e.getMessageEditor().getMessage(
diff --git a/src/main/java/com/bbn/hadder/commands/moderation/StarboardCommand.java b/src/main/java/one/bbn/hadder/commands/moderation/StarboardCommand.java
similarity index 78%
rename from src/main/java/com/bbn/hadder/commands/moderation/StarboardCommand.java
rename to src/main/java/one/bbn/hadder/commands/moderation/StarboardCommand.java
index 11af987..6737627 100644
--- a/src/main/java/com/bbn/hadder/commands/moderation/StarboardCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/moderation/StarboardCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,11 +14,11 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.moderation;
+package one.bbn.hadder.commands.moderation;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.MessageEditor;
import net.dv8tion.jda.api.entities.TextChannel;
public class StarboardCommand implements Command {
@@ -26,7 +26,7 @@ public class StarboardCommand implements Command {
@Override
public void executed(String[] args, CommandEvent e) {
if (e.getMessage().getMentionedChannels().size() == 1) {
- e.getRethinkServer().setStarboard(e.getMessage().getMentionedChannels().get(0).getId());
+ e.getMongoServer().setStarboard(e.getMessage().getMentionedChannels().get(0).getId());
e.getChannel().sendMessage(
e.getMessageEditor().getMessage(
MessageEditor.MessageType.INFO,
@@ -37,16 +37,16 @@ public class StarboardCommand implements Command {
if (args.length > 0) {
TextChannel channel = e.getGuild().getTextChannelById(args[0]);
if (channel != null) {
- e.getRethinkServer().setStarboard(channel.getId());
+ e.getMongoServer().setStarboard(channel.getId());
}
} else e.getHelpCommand().sendHelp(this, e);
}
if (args.length == 2) {
- e.getRethinkServer().setNeededStars(args[1]);
+ e.getMongoServer().setNeededStars(args[1]);
}
- e.getRethinkServer().push();
+ e.getMongoServer().push();
}
@Override
diff --git a/src/main/java/com/bbn/hadder/commands/music/BassCommand.java b/src/main/java/one/bbn/hadder/commands/music/BassCommand.java
similarity index 92%
rename from src/main/java/com/bbn/hadder/commands/music/BassCommand.java
rename to src/main/java/one/bbn/hadder/commands/music/BassCommand.java
index 45fa9f8..222132a 100644
--- a/src/main/java/com/bbn/hadder/commands/music/BassCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/music/BassCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,11 +14,11 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.music;
+package one.bbn.hadder.commands.music;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.MessageEditor;
import com.sedmelluq.discord.lavaplayer.filter.equalizer.EqualizerFactory;
public class BassCommand implements Command {
diff --git a/src/main/java/com/bbn/hadder/commands/music/EchoCommand.java b/src/main/java/one/bbn/hadder/commands/music/EchoCommand.java
similarity index 87%
rename from src/main/java/com/bbn/hadder/commands/music/EchoCommand.java
rename to src/main/java/one/bbn/hadder/commands/music/EchoCommand.java
index 3af61a9..4a17818 100644
--- a/src/main/java/com/bbn/hadder/commands/music/EchoCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/music/EchoCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,12 +14,12 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.music;
+package one.bbn.hadder.commands.music;
-import com.bbn.hadder.audio.AudioPlayerSendHandler;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.audio.AudioPlayerSendHandler;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.MessageEditor;
import net.dv8tion.jda.api.entities.Guild;
import net.dv8tion.jda.api.managers.AudioManager;
diff --git a/src/main/java/com/bbn/hadder/commands/music/InfoCommand.java b/src/main/java/one/bbn/hadder/commands/music/InfoCommand.java
similarity index 90%
rename from src/main/java/com/bbn/hadder/commands/music/InfoCommand.java
rename to src/main/java/one/bbn/hadder/commands/music/InfoCommand.java
index 6096550..48b50f5 100644
--- a/src/main/java/com/bbn/hadder/commands/music/InfoCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/music/InfoCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,11 +14,11 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.music;
+package one.bbn.hadder.commands.music;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.MessageEditor;
import com.sedmelluq.discord.lavaplayer.track.AudioTrack;
public class InfoCommand implements Command {
diff --git a/src/main/java/com/bbn/hadder/commands/music/JoinCommand.java b/src/main/java/one/bbn/hadder/commands/music/JoinCommand.java
similarity index 95%
rename from src/main/java/com/bbn/hadder/commands/music/JoinCommand.java
rename to src/main/java/one/bbn/hadder/commands/music/JoinCommand.java
index 4f3a850..f735fa0 100644
--- a/src/main/java/com/bbn/hadder/commands/music/JoinCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/music/JoinCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,11 +14,11 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.music;
+package one.bbn.hadder.commands.music;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.MessageEditor;
import net.dv8tion.jda.api.entities.VoiceChannel;
import net.dv8tion.jda.api.exceptions.InsufficientPermissionException;
import net.dv8tion.jda.api.managers.AudioManager;
diff --git a/src/main/java/com/bbn/hadder/commands/music/LoopCommand.java b/src/main/java/one/bbn/hadder/commands/music/LoopCommand.java
similarity index 92%
rename from src/main/java/com/bbn/hadder/commands/music/LoopCommand.java
rename to src/main/java/one/bbn/hadder/commands/music/LoopCommand.java
index 1189845..b55f13f 100644
--- a/src/main/java/com/bbn/hadder/commands/music/LoopCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/music/LoopCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,11 +14,11 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.music;
+package one.bbn.hadder.commands.music;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.MessageEditor;
public class LoopCommand implements Command {
diff --git a/src/main/java/com/bbn/hadder/commands/music/PauseCommand.java b/src/main/java/one/bbn/hadder/commands/music/PauseCommand.java
similarity index 91%
rename from src/main/java/com/bbn/hadder/commands/music/PauseCommand.java
rename to src/main/java/one/bbn/hadder/commands/music/PauseCommand.java
index 3dcf47e..bf88b0b 100644
--- a/src/main/java/com/bbn/hadder/commands/music/PauseCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/music/PauseCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,11 +14,11 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.music;
+package one.bbn.hadder.commands.music;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.MessageEditor;
public class PauseCommand implements Command {
@@ -35,7 +35,7 @@ public class PauseCommand implements Command {
} else {
e.getTextChannel().sendMessage(e.getMessageEditor().getMessage(MessageEditor.MessageType.ERROR,
"commands.music.pause.error.paused.title", "",
- "commands.music.pause.error.paused.description", e.getRethinkServer().getPrefix())
+ "commands.music.pause.error.paused.description", e.getMongoServer().getPrefix())
.build()).queue();
}
} else {
diff --git a/src/main/java/com/bbn/hadder/commands/music/PlayCommand.java b/src/main/java/one/bbn/hadder/commands/music/PlayCommand.java
similarity index 92%
rename from src/main/java/com/bbn/hadder/commands/music/PlayCommand.java
rename to src/main/java/one/bbn/hadder/commands/music/PlayCommand.java
index 45c3855..32a7d3d 100644
--- a/src/main/java/com/bbn/hadder/commands/music/PlayCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/music/PlayCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,11 +14,11 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.music;
+package one.bbn.hadder.commands.music;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.MessageEditor;
import net.dv8tion.jda.api.entities.Message;
import net.dv8tion.jda.api.exceptions.InsufficientPermissionException;
@@ -30,7 +30,7 @@ public class PlayCommand implements Command {
public void executed(String[] args, CommandEvent e) {
if (args.length > 0) {
if (e.getMember().getVoiceState().inVoiceChannel()) {
- String input = e.getMessage().getContentRaw().replaceFirst(e.getRethinkServer().getPrefix() + "play ", "").replaceFirst(e.getRethinkUser().getPrefix() + "play ", "");
+ String input = e.getMessage().getContentRaw().replaceFirst(e.getMongoServer().getPrefix() + "play ", "").replaceFirst(e.getMongoUser().getPrefix() + "play ", "");
try {
new URL(input).toURI();
Message msg = e.getTextChannel().sendMessage(e.getMessageEditor().getMessage(MessageEditor.MessageType.INFO,
diff --git a/src/main/java/com/bbn/hadder/commands/music/QueueCommand.java b/src/main/java/one/bbn/hadder/commands/music/QueueCommand.java
similarity index 90%
rename from src/main/java/com/bbn/hadder/commands/music/QueueCommand.java
rename to src/main/java/one/bbn/hadder/commands/music/QueueCommand.java
index 185e91d..b68f90b 100644
--- a/src/main/java/com/bbn/hadder/commands/music/QueueCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/music/QueueCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,12 +14,12 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.music;
+package one.bbn.hadder.commands.music;
-import com.bbn.hadder.audio.AudioInfo;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.audio.AudioInfo;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.MessageEditor;
import java.util.Set;
diff --git a/src/main/java/com/bbn/hadder/commands/music/RecordCommand.java b/src/main/java/one/bbn/hadder/commands/music/RecordCommand.java
similarity index 93%
rename from src/main/java/com/bbn/hadder/commands/music/RecordCommand.java
rename to src/main/java/one/bbn/hadder/commands/music/RecordCommand.java
index 9f540cf..f6eaafd 100644
--- a/src/main/java/com/bbn/hadder/commands/music/RecordCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/music/RecordCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,12 +14,12 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.music;
+package one.bbn.hadder.commands.music;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.core.Perm;
-import com.bbn.hadder.core.Perms;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.core.Perm;
+import one.bbn.hadder.core.Perms;
import net.dv8tion.jda.api.audio.AudioReceiveHandler;
import net.dv8tion.jda.api.audio.AudioSendHandler;
import net.dv8tion.jda.api.audio.UserAudio;
diff --git a/src/main/java/com/bbn/hadder/commands/music/SkipCommand.java b/src/main/java/one/bbn/hadder/commands/music/SkipCommand.java
similarity index 93%
rename from src/main/java/com/bbn/hadder/commands/music/SkipCommand.java
rename to src/main/java/one/bbn/hadder/commands/music/SkipCommand.java
index 5695395..183f554 100644
--- a/src/main/java/com/bbn/hadder/commands/music/SkipCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/music/SkipCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,11 +14,11 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.music;
+package one.bbn.hadder.commands.music;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.MessageEditor;
public class SkipCommand implements Command {
diff --git a/src/main/java/com/bbn/hadder/commands/music/StopCommand.java b/src/main/java/one/bbn/hadder/commands/music/StopCommand.java
similarity index 92%
rename from src/main/java/com/bbn/hadder/commands/music/StopCommand.java
rename to src/main/java/one/bbn/hadder/commands/music/StopCommand.java
index 96a1811..717395f 100644
--- a/src/main/java/com/bbn/hadder/commands/music/StopCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/music/StopCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,11 +14,11 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.music;
+package one.bbn.hadder.commands.music;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.MessageEditor;
public class StopCommand implements Command {
diff --git a/src/main/java/com/bbn/hadder/commands/music/VolumeCommand.java b/src/main/java/one/bbn/hadder/commands/music/VolumeCommand.java
similarity index 93%
rename from src/main/java/com/bbn/hadder/commands/music/VolumeCommand.java
rename to src/main/java/one/bbn/hadder/commands/music/VolumeCommand.java
index dec010d..077a3db 100644
--- a/src/main/java/com/bbn/hadder/commands/music/VolumeCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/music/VolumeCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,11 +14,11 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.music;
+package one.bbn.hadder.commands.music;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.MessageEditor;
import org.jsoup.internal.StringUtil;
public class VolumeCommand implements Command {
diff --git a/src/main/java/com/bbn/hadder/commands/nsfw/AnalCommand.java b/src/main/java/one/bbn/hadder/commands/nsfw/AnalCommand.java
similarity index 86%
rename from src/main/java/com/bbn/hadder/commands/nsfw/AnalCommand.java
rename to src/main/java/one/bbn/hadder/commands/nsfw/AnalCommand.java
index 8d51300..f15e62b 100644
--- a/src/main/java/com/bbn/hadder/commands/nsfw/AnalCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/nsfw/AnalCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,12 +14,12 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.nsfw;
+package one.bbn.hadder.commands.nsfw;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.Http;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.Http;
+import one.bbn.hadder.utils.MessageEditor;
public class AnalCommand implements Command {
diff --git a/src/main/java/com/bbn/hadder/commands/nsfw/BDSMCommand.java b/src/main/java/one/bbn/hadder/commands/nsfw/BDSMCommand.java
similarity index 86%
rename from src/main/java/com/bbn/hadder/commands/nsfw/BDSMCommand.java
rename to src/main/java/one/bbn/hadder/commands/nsfw/BDSMCommand.java
index 8cc55d3..d27d060 100644
--- a/src/main/java/com/bbn/hadder/commands/nsfw/BDSMCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/nsfw/BDSMCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,12 +14,12 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.nsfw;
+package one.bbn.hadder.commands.nsfw;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.Http;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.Http;
+import one.bbn.hadder.utils.MessageEditor;
public class BDSMCommand implements Command {
diff --git a/src/main/java/com/bbn/hadder/commands/nsfw/BlowjobCommand.java b/src/main/java/one/bbn/hadder/commands/nsfw/BlowjobCommand.java
similarity index 86%
rename from src/main/java/com/bbn/hadder/commands/nsfw/BlowjobCommand.java
rename to src/main/java/one/bbn/hadder/commands/nsfw/BlowjobCommand.java
index b2a3b4f..9bfe68a 100644
--- a/src/main/java/com/bbn/hadder/commands/nsfw/BlowjobCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/nsfw/BlowjobCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,12 +14,12 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.nsfw;
+package one.bbn.hadder.commands.nsfw;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.Http;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.Http;
+import one.bbn.hadder.utils.MessageEditor;
public class BlowjobCommand implements Command {
diff --git a/src/main/java/com/bbn/hadder/commands/nsfw/BoobsCommand.java b/src/main/java/one/bbn/hadder/commands/nsfw/BoobsCommand.java
similarity index 86%
rename from src/main/java/com/bbn/hadder/commands/nsfw/BoobsCommand.java
rename to src/main/java/one/bbn/hadder/commands/nsfw/BoobsCommand.java
index 9344148..ede391e 100644
--- a/src/main/java/com/bbn/hadder/commands/nsfw/BoobsCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/nsfw/BoobsCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,12 +14,12 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.nsfw;
+package one.bbn.hadder.commands.nsfw;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.Http;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.Http;
+import one.bbn.hadder.utils.MessageEditor;
public class BoobsCommand implements Command {
diff --git a/src/main/java/com/bbn/hadder/commands/nsfw/CumCommand.java b/src/main/java/one/bbn/hadder/commands/nsfw/CumCommand.java
similarity index 86%
rename from src/main/java/com/bbn/hadder/commands/nsfw/CumCommand.java
rename to src/main/java/one/bbn/hadder/commands/nsfw/CumCommand.java
index 9f45457..b8ff0f9 100644
--- a/src/main/java/com/bbn/hadder/commands/nsfw/CumCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/nsfw/CumCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,12 +14,12 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.nsfw;
+package one.bbn.hadder.commands.nsfw;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.Http;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.Http;
+import one.bbn.hadder.utils.MessageEditor;
public class CumCommand implements Command {
diff --git a/src/main/java/com/bbn/hadder/commands/nsfw/EroticCommand.java b/src/main/java/one/bbn/hadder/commands/nsfw/EroticCommand.java
similarity index 86%
rename from src/main/java/com/bbn/hadder/commands/nsfw/EroticCommand.java
rename to src/main/java/one/bbn/hadder/commands/nsfw/EroticCommand.java
index 8e1d25f..91fcba8 100644
--- a/src/main/java/com/bbn/hadder/commands/nsfw/EroticCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/nsfw/EroticCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,12 +14,12 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.nsfw;
+package one.bbn.hadder.commands.nsfw;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.Http;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.Http;
+import one.bbn.hadder.utils.MessageEditor;
public class EroticCommand implements Command {
diff --git a/src/main/java/com/bbn/hadder/commands/nsfw/FeetCommand.java b/src/main/java/one/bbn/hadder/commands/nsfw/FeetCommand.java
similarity index 86%
rename from src/main/java/com/bbn/hadder/commands/nsfw/FeetCommand.java
rename to src/main/java/one/bbn/hadder/commands/nsfw/FeetCommand.java
index 2771465..074b541 100644
--- a/src/main/java/com/bbn/hadder/commands/nsfw/FeetCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/nsfw/FeetCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,12 +14,12 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.nsfw;
+package one.bbn.hadder.commands.nsfw;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.Http;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.Http;
+import one.bbn.hadder.utils.MessageEditor;
public class FeetCommand implements Command {
diff --git a/src/main/java/com/bbn/hadder/commands/nsfw/FingeringCommand.java b/src/main/java/one/bbn/hadder/commands/nsfw/FingeringCommand.java
similarity index 87%
rename from src/main/java/com/bbn/hadder/commands/nsfw/FingeringCommand.java
rename to src/main/java/one/bbn/hadder/commands/nsfw/FingeringCommand.java
index 613aeb6..edfb20d 100644
--- a/src/main/java/com/bbn/hadder/commands/nsfw/FingeringCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/nsfw/FingeringCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,12 +14,12 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.nsfw;
+package one.bbn.hadder.commands.nsfw;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.Http;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.Http;
+import one.bbn.hadder.utils.MessageEditor;
public class FingeringCommand implements Command {
diff --git a/src/main/java/com/bbn/hadder/commands/nsfw/LickingCommand.java b/src/main/java/one/bbn/hadder/commands/nsfw/LickingCommand.java
similarity index 86%
rename from src/main/java/com/bbn/hadder/commands/nsfw/LickingCommand.java
rename to src/main/java/one/bbn/hadder/commands/nsfw/LickingCommand.java
index 2cca595..f51cb2a 100644
--- a/src/main/java/com/bbn/hadder/commands/nsfw/LickingCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/nsfw/LickingCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,12 +14,12 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.nsfw;
+package one.bbn.hadder.commands.nsfw;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.Http;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.Http;
+import one.bbn.hadder.utils.MessageEditor;
public class LickingCommand implements Command {
diff --git a/src/main/java/com/bbn/hadder/commands/nsfw/PornCommand.java b/src/main/java/one/bbn/hadder/commands/nsfw/PornCommand.java
similarity index 86%
rename from src/main/java/com/bbn/hadder/commands/nsfw/PornCommand.java
rename to src/main/java/one/bbn/hadder/commands/nsfw/PornCommand.java
index eebcb33..90f76ca 100644
--- a/src/main/java/com/bbn/hadder/commands/nsfw/PornCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/nsfw/PornCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,12 +14,12 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.nsfw;
+package one.bbn.hadder.commands.nsfw;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.Http;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.Http;
+import one.bbn.hadder.utils.MessageEditor;
public class PornCommand implements Command {
diff --git a/src/main/java/com/bbn/hadder/commands/nsfw/PussyCommand.java b/src/main/java/one/bbn/hadder/commands/nsfw/PussyCommand.java
similarity index 86%
rename from src/main/java/com/bbn/hadder/commands/nsfw/PussyCommand.java
rename to src/main/java/one/bbn/hadder/commands/nsfw/PussyCommand.java
index d00dad8..1968706 100644
--- a/src/main/java/com/bbn/hadder/commands/nsfw/PussyCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/nsfw/PussyCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,12 +14,12 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.nsfw;
+package one.bbn.hadder.commands.nsfw;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.Http;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.Http;
+import one.bbn.hadder.utils.MessageEditor;
public class PussyCommand implements Command {
diff --git a/src/main/java/com/bbn/hadder/commands/nsfw/RandomPornCommand.java b/src/main/java/one/bbn/hadder/commands/nsfw/RandomPornCommand.java
similarity index 87%
rename from src/main/java/com/bbn/hadder/commands/nsfw/RandomPornCommand.java
rename to src/main/java/one/bbn/hadder/commands/nsfw/RandomPornCommand.java
index 40ffca4..7218f58 100644
--- a/src/main/java/com/bbn/hadder/commands/nsfw/RandomPornCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/nsfw/RandomPornCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,12 +14,12 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.nsfw;
+package one.bbn.hadder.commands.nsfw;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.Http;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.Http;
+import one.bbn.hadder.utils.MessageEditor;
public class RandomPornCommand implements Command {
diff --git a/src/main/java/com/bbn/hadder/commands/nsfw/SoloCommand.java b/src/main/java/one/bbn/hadder/commands/nsfw/SoloCommand.java
similarity index 86%
rename from src/main/java/com/bbn/hadder/commands/nsfw/SoloCommand.java
rename to src/main/java/one/bbn/hadder/commands/nsfw/SoloCommand.java
index c7652fd..7e4c4bf 100644
--- a/src/main/java/com/bbn/hadder/commands/nsfw/SoloCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/nsfw/SoloCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,12 +14,12 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.nsfw;
+package one.bbn.hadder.commands.nsfw;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.Http;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.Http;
+import one.bbn.hadder.utils.MessageEditor;
public class SoloCommand implements Command {
diff --git a/src/main/java/com/bbn/hadder/commands/nsfw/SpankCommand.java b/src/main/java/one/bbn/hadder/commands/nsfw/SpankCommand.java
similarity index 86%
rename from src/main/java/com/bbn/hadder/commands/nsfw/SpankCommand.java
rename to src/main/java/one/bbn/hadder/commands/nsfw/SpankCommand.java
index bac668d..e607acd 100644
--- a/src/main/java/com/bbn/hadder/commands/nsfw/SpankCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/nsfw/SpankCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,12 +14,12 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.nsfw;
+package one.bbn.hadder.commands.nsfw;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.Http;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.Http;
+import one.bbn.hadder.utils.MessageEditor;
public class SpankCommand implements Command {
diff --git a/src/main/java/com/bbn/hadder/commands/nsfw/TransCommand.java b/src/main/java/one/bbn/hadder/commands/nsfw/TransCommand.java
similarity index 86%
rename from src/main/java/com/bbn/hadder/commands/nsfw/TransCommand.java
rename to src/main/java/one/bbn/hadder/commands/nsfw/TransCommand.java
index 9beea46..0a3a45c 100644
--- a/src/main/java/com/bbn/hadder/commands/nsfw/TransCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/nsfw/TransCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,12 +14,12 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.nsfw;
+package one.bbn.hadder.commands.nsfw;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.Http;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.Http;
+import one.bbn.hadder.utils.MessageEditor;
public class TransCommand implements Command {
diff --git a/src/main/java/com/bbn/hadder/commands/owner/BlacklistCommand.java b/src/main/java/one/bbn/hadder/commands/owner/BlacklistCommand.java
similarity index 85%
rename from src/main/java/com/bbn/hadder/commands/owner/BlacklistCommand.java
rename to src/main/java/one/bbn/hadder/commands/owner/BlacklistCommand.java
index 4d5da6c..dd7098f 100644
--- a/src/main/java/com/bbn/hadder/commands/owner/BlacklistCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/owner/BlacklistCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,14 +14,14 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.owner;
+package one.bbn.hadder.commands.owner;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.core.Perm;
-import com.bbn.hadder.core.Perms;
-import com.bbn.hadder.db.RethinkUser;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.core.Perm;
+import one.bbn.hadder.core.Perms;
+import one.bbn.hadder.db.MongoUser;
+import one.bbn.hadder.utils.MessageEditor;
import net.dv8tion.jda.api.entities.User;
import java.util.ArrayList;
@@ -41,8 +41,8 @@ public class BlacklistCommand implements Command {
case "add":
case "remove":
if (args.length == 3 && e.getMessage().getMentionedUsers().size() == 1) {
- RethinkUser u = new RethinkUser(e.getRethink().getObjectByID("user", e.getMessage().getMentionedUsers().get(0).getId()), e.getRethink());
- String blacklisted = e.getRethinkUser().getBlacklisted();
+ MongoUser u = new MongoUser(e.getMongo().getObjectByID("user", e.getMessage().getMentionedUsers().get(0).getId()), e.getMongo());
+ String blacklisted = e.getMongoUser().getBlacklisted();
List commands = new ArrayList<>();
if (!"none".equals(blacklisted)) commands.addAll(Arrays.asList(blacklisted.split(",")));
if (args[0].equalsIgnoreCase("add")) commands.addAll(Arrays.asList(args[1].split(",")));
@@ -65,7 +65,7 @@ public class BlacklistCommand implements Command {
StringBuilder stringBuilder = new StringBuilder();
for (User user : e.getJDA().getUsers()) {
if (!user.getId().equals(e.getJDA().getSelfUser().getId())) {
- RethinkUser u = new RethinkUser(e.getRethink().getObjectByID("user", user.getId()), e.getRethink());
+ MongoUser u = new MongoUser(e.getMongo().getObjectByID("user", user.getId()), e.getMongo());
String blacklisted = u.getBlacklisted();
if (!"none".equals(blacklisted)) {
stringBuilder.append(user.getAsTag()).append(" (").append(user.getId()).append(") - ").append(blacklisted).append("\n");
diff --git a/src/main/java/com/bbn/hadder/commands/owner/EvalCommand.java b/src/main/java/one/bbn/hadder/commands/owner/EvalCommand.java
similarity index 92%
rename from src/main/java/com/bbn/hadder/commands/owner/EvalCommand.java
rename to src/main/java/one/bbn/hadder/commands/owner/EvalCommand.java
index 5d0f8f7..4a34368 100644
--- a/src/main/java/com/bbn/hadder/commands/owner/EvalCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/owner/EvalCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,14 +14,14 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.owner;
+package one.bbn.hadder.commands.owner;
-import com.bbn.hadder.Hadder;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.core.Perm;
-import com.bbn.hadder.core.Perms;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.Hadder;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.core.Perm;
+import one.bbn.hadder.core.Perms;
+import one.bbn.hadder.utils.MessageEditor;
import javax.script.ScriptEngine;
import javax.script.ScriptEngineManager;
@@ -45,7 +45,7 @@ public class EvalCommand implements Command {
}
engine.put("msg".toLowerCase(), e.getMessage());
engine.put("shardmanager".toLowerCase(), Hadder.shardManager);
- engine.put("rethink".toLowerCase(), e.getRethink());
+ engine.put("rethink".toLowerCase(), e.getMongo());
engine.put("e".toLowerCase(), e);
engine.put("jda".toLowerCase(), e.getJDA());
engine.put("message".toLowerCase(), e.getMessage());
diff --git a/src/main/java/com/bbn/hadder/commands/owner/GuildLeaveCommand.java b/src/main/java/one/bbn/hadder/commands/owner/GuildLeaveCommand.java
similarity index 87%
rename from src/main/java/com/bbn/hadder/commands/owner/GuildLeaveCommand.java
rename to src/main/java/one/bbn/hadder/commands/owner/GuildLeaveCommand.java
index 0db2850..ea325e5 100644
--- a/src/main/java/com/bbn/hadder/commands/owner/GuildLeaveCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/owner/GuildLeaveCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,13 +14,13 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.owner;
+package one.bbn.hadder.commands.owner;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.core.Perm;
-import com.bbn.hadder.core.Perms;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.core.Perm;
+import one.bbn.hadder.core.Perms;
+import one.bbn.hadder.utils.MessageEditor;
import net.dv8tion.jda.api.entities.Guild;
@Perms(Perm.BOT_OWNER)
diff --git a/src/main/java/com/bbn/hadder/commands/owner/RebootCommand.java b/src/main/java/one/bbn/hadder/commands/owner/RebootCommand.java
similarity index 82%
rename from src/main/java/com/bbn/hadder/commands/owner/RebootCommand.java
rename to src/main/java/one/bbn/hadder/commands/owner/RebootCommand.java
index 7ae5ff9..81ad9a4 100644
--- a/src/main/java/com/bbn/hadder/commands/owner/RebootCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/owner/RebootCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,12 +14,12 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.owner;
+package one.bbn.hadder.commands.owner;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.core.Perm;
-import com.bbn.hadder.core.Perms;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.core.Perm;
+import one.bbn.hadder.core.Perms;
@Perms(Perm.BOT_OWNER)
public class RebootCommand implements Command {
diff --git a/src/main/java/com/bbn/hadder/commands/owner/ShutdownCommand.java b/src/main/java/one/bbn/hadder/commands/owner/ShutdownCommand.java
similarity index 82%
rename from src/main/java/com/bbn/hadder/commands/owner/ShutdownCommand.java
rename to src/main/java/one/bbn/hadder/commands/owner/ShutdownCommand.java
index b8357a8..6c763af 100644
--- a/src/main/java/com/bbn/hadder/commands/owner/ShutdownCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/owner/ShutdownCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,13 +14,13 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.owner;
+package one.bbn.hadder.commands.owner;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.core.Perm;
-import com.bbn.hadder.core.Perms;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.core.Perm;
+import one.bbn.hadder.core.Perms;
+import one.bbn.hadder.utils.MessageEditor;
@Perms(Perm.BOT_OWNER)
public class ShutdownCommand implements Command {
diff --git a/src/main/java/com/bbn/hadder/commands/owner/TestCommand.java b/src/main/java/one/bbn/hadder/commands/owner/TestCommand.java
similarity index 83%
rename from src/main/java/com/bbn/hadder/commands/owner/TestCommand.java
rename to src/main/java/one/bbn/hadder/commands/owner/TestCommand.java
index b484b6a..41f8a37 100644
--- a/src/main/java/com/bbn/hadder/commands/owner/TestCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/owner/TestCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,11 +14,11 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.owner;
+package one.bbn.hadder.commands.owner;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.MessageEditor.MessageType;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.MessageEditor.MessageType;
public class TestCommand implements Command {
diff --git a/src/main/java/com/bbn/hadder/commands/settings/LanguageCommand.java b/src/main/java/one/bbn/hadder/commands/settings/LanguageCommand.java
similarity index 90%
rename from src/main/java/com/bbn/hadder/commands/settings/LanguageCommand.java
rename to src/main/java/one/bbn/hadder/commands/settings/LanguageCommand.java
index eea064a..2c587d7 100644
--- a/src/main/java/com/bbn/hadder/commands/settings/LanguageCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/settings/LanguageCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,11 +14,11 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.settings;
+package one.bbn.hadder.commands.settings;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.MessageEditor;
public class LanguageCommand implements Command {
@@ -58,14 +58,14 @@ public class LanguageCommand implements Command {
}
public void setLanguage(String language_code, String language, CommandEvent e) {
- e.getRethinkUser().setLanguage(language_code);
+ e.getMongoUser().setLanguage(language_code);
e.getTextChannel()
.sendMessage(
e.getMessageEditor()
.getMessage(MessageEditor.MessageType.INFO, "commands.settings.language.success.title",
"", "commands.settings.language.success.description", language)
.build()).queue();
- e.getRethinkUser().push();
+ e.getMongoUser().push();
}
@Override
diff --git a/src/main/java/com/bbn/hadder/commands/settings/UserPrefixCommand.java b/src/main/java/one/bbn/hadder/commands/settings/UserPrefixCommand.java
similarity index 82%
rename from src/main/java/com/bbn/hadder/commands/settings/UserPrefixCommand.java
rename to src/main/java/one/bbn/hadder/commands/settings/UserPrefixCommand.java
index 21e6d06..1fc691f 100644
--- a/src/main/java/com/bbn/hadder/commands/settings/UserPrefixCommand.java
+++ b/src/main/java/one/bbn/hadder/commands/settings/UserPrefixCommand.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,24 +14,24 @@
* limitations under the License.
*/
-package com.bbn.hadder.commands.settings;
+package one.bbn.hadder.commands.settings;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.utils.MessageEditor;
public class UserPrefixCommand implements Command {
public void executed(String[] args, CommandEvent e) {
if (args.length == 1) {
- e.getRethinkUser().setPrefix(args[0]);
+ e.getMongoUser().setPrefix(args[0]);
e.getTextChannel()
.sendMessage(e.getMessageEditor()
.getMessage(MessageEditor.MessageType.INFO, "commands.settings.prefix.success.title", "",
"commands.settings.prefix.success.description", args[0])
.build())
.queue();
- e.getRethinkUser().push();
+ e.getMongoUser().push();
} else e.getHelpCommand().sendHelp(this, e);
}
diff --git a/src/main/java/com/bbn/hadder/core/CommandHandler.java b/src/main/java/one/bbn/hadder/core/CommandHandler.java
similarity index 80%
rename from src/main/java/com/bbn/hadder/core/CommandHandler.java
rename to src/main/java/one/bbn/hadder/core/CommandHandler.java
index 39a000a..6575c33 100644
--- a/src/main/java/com/bbn/hadder/core/CommandHandler.java
+++ b/src/main/java/one/bbn/hadder/core/CommandHandler.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,17 +14,17 @@
* limitations under the License.
*/
-package com.bbn.hadder.core;
+package one.bbn.hadder.core;
-import com.bbn.hadder.audio.AudioManager;
-import com.bbn.hadder.commands.Command;
-import com.bbn.hadder.commands.CommandEvent;
-import com.bbn.hadder.commands.general.HelpCommand;
-import com.bbn.hadder.db.Rethink;
-import com.bbn.hadder.db.RethinkServer;
-import com.bbn.hadder.db.RethinkUser;
-import com.bbn.hadder.utils.EventWaiter;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.audio.AudioManager;
+import one.bbn.hadder.commands.Command;
+import one.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.commands.general.HelpCommand;
+import one.bbn.hadder.db.Mongo;
+import one.bbn.hadder.db.MongoServer;
+import one.bbn.hadder.db.MongoUser;
+import one.bbn.hadder.utils.EventWaiter;
+import one.bbn.hadder.utils.MessageEditor;
import net.dv8tion.jda.api.events.message.MessageReceivedEvent;
import java.util.Arrays;
@@ -42,7 +42,7 @@ public class CommandHandler {
this.helpCommand = helpCommand;
}
- public void handle(MessageReceivedEvent event, Rethink rethink, String prefix, AudioManager audioManager, RethinkUser rethinkUser, RethinkServer rethinkServer) {
+ public void handle(MessageReceivedEvent event, Mongo mongo, String prefix, AudioManager audioManager, MongoUser mongoUser, MongoServer mongoServer) {
String invoke = event.getMessage().getContentRaw().replaceFirst(prefix, "").split(" ")[0];
for (Command cmd : commandList) {
for (String label : cmd.labels()) {
@@ -53,8 +53,8 @@ public class CommandHandler {
String[] args = argString.split(" ");
if (args.length > 0 && args[0].equals("")) args = new String[0];
- CommandEvent commandEvent = new CommandEvent(event.getJDA(), event.getResponseNumber(), event.getMessage(), rethink,
- config, this, helpCommand, new MessageEditor(rethinkUser, event.getAuthor()), new EventWaiter(), audioManager, rethinkUser, rethinkServer);
+ CommandEvent commandEvent = new CommandEvent(event.getJDA(), event.getResponseNumber(), event.getMessage(), mongo,
+ config, this, helpCommand, new MessageEditor(mongoUser, event.getAuthor()), new EventWaiter(), audioManager, mongoUser, mongoServer);
if (cmd.getClass().getAnnotations().length > 0 && !Arrays.asList(cmd.getClass().getAnnotations()).contains(Perms.class)) {
for (Perm perm : cmd.getClass().getAnnotation(Perms.class).value()) {
if (!perm.check(commandEvent)) {
@@ -68,7 +68,7 @@ public class CommandHandler {
}
boolean run = true;
- String blacklisted = rethinkUser.getBlacklisted();
+ String blacklisted = mongoUser.getBlacklisted();
if (!"none".equals(blacklisted)) {
for (String BLLabel : blacklisted.split(",")) {
if (Arrays.asList(cmd.labels()).contains(BLLabel)) {
diff --git a/src/main/java/com/bbn/hadder/core/Config.java b/src/main/java/one/bbn/hadder/core/Config.java
similarity index 98%
rename from src/main/java/com/bbn/hadder/core/Config.java
rename to src/main/java/one/bbn/hadder/core/Config.java
index 2af7ff2..a2c1389 100644
--- a/src/main/java/com/bbn/hadder/core/Config.java
+++ b/src/main/java/one/bbn/hadder/core/Config.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-package com.bbn.hadder.core;
+package one.bbn.hadder.core;
import org.json.JSONObject;
import org.json.JSONStringer;
diff --git a/src/main/java/com/bbn/hadder/core/Perm.java b/src/main/java/one/bbn/hadder/core/Perm.java
similarity index 96%
rename from src/main/java/com/bbn/hadder/core/Perm.java
rename to src/main/java/one/bbn/hadder/core/Perm.java
index 2c5b4bb..a872918 100644
--- a/src/main/java/com/bbn/hadder/core/Perm.java
+++ b/src/main/java/one/bbn/hadder/core/Perm.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,9 +14,9 @@
* limitations under the License.
*/
-package com.bbn.hadder.core;
+package one.bbn.hadder.core;
-import com.bbn.hadder.commands.CommandEvent;
+import one.bbn.hadder.commands.CommandEvent;
import net.dv8tion.jda.api.Permission;
public enum Perm {
diff --git a/src/main/java/com/bbn/hadder/core/Perms.java b/src/main/java/one/bbn/hadder/core/Perms.java
similarity index 90%
rename from src/main/java/com/bbn/hadder/core/Perms.java
rename to src/main/java/one/bbn/hadder/core/Perms.java
index a5c2efe..b442577 100644
--- a/src/main/java/com/bbn/hadder/core/Perms.java
+++ b/src/main/java/one/bbn/hadder/core/Perms.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-package com.bbn.hadder.core;
+package one.bbn.hadder.core;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
diff --git a/src/main/java/one/bbn/hadder/db/Mongo.java b/src/main/java/one/bbn/hadder/db/Mongo.java
new file mode 100644
index 0000000..62aecd0
--- /dev/null
+++ b/src/main/java/one/bbn/hadder/db/Mongo.java
@@ -0,0 +1,148 @@
+/*
+ * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ *
+ * Licensed under the GNU Affero General Public License, Version 3.0;
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * https://www.gnu.org/licenses/agpl-3.0.en.html
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package one.bbn.hadder.db;
+
+import com.mongodb.BasicDBObject;
+import com.mongodb.client.*;
+import one.bbn.hadder.core.Config;
+import org.bson.Document;
+import org.json.JSONObject;
+
+import java.lang.reflect.Field;
+import java.util.NoSuchElementException;
+
+public class Mongo {
+
+ MongoDatabase db;
+ Config config;
+
+ public Mongo(Config config) {
+ this.config = config;
+ }
+
+ public void connect() {
+ db = MongoClients.create("mongodb://" + config.getDatabaseUsername() + ":" + config.getDatabasePassword() + "@" + config.getDatabaseIP() + ":" + config.getDatabasePort() + "/?authSource=admin").getDatabase("Hadder");
+ }
+
+ public Object getByID(String collection_name, String where, String what, String column) {
+ MongoCollection collection = db.getCollection(collection_name);
+ BasicDBObject whereQuery = new BasicDBObject();
+ whereQuery.put(where, what);
+ FindIterable it = collection.find(whereQuery);
+ return it.cursor().next().get(column);
+ }
+
+ public JSONObject getObjectByID(String collection, String id) {
+ BasicDBObject whereQuery = new BasicDBObject();
+ whereQuery.put("id", id);
+ try {
+ String response = db.getCollection(collection).find(whereQuery).cursor().next().toJson();
+ return new JSONObject(response);
+ } catch (NoSuchElementException e) {
+ insertUser(id);
+ String response2 = db.getCollection(collection).find(whereQuery).cursor().next().toJson();
+ return new JSONObject(response2);
+ }
+ }
+
+ public void remove(String table, String where, String value) {
+ BasicDBObject whereQuery = new BasicDBObject();
+ whereQuery.put(where, value);
+ db.getCollection(table).deleteOne(whereQuery);
+ }
+
+ public void insert(String table, Document doc) {
+ db.getCollection(table).insertOne(doc);
+ }
+
+ public void insertUser(String id) {
+ this.insert("user", new Document("id", id)
+ .append("prefix", "h.")
+ .append("language", "en")
+ .append("blacklisted", "none"));
+ }
+
+ public void insertGuild(String id) {
+ this.insert("server", new Document("id", id)
+ .append("prefix", "h.")
+ .append("message_id", "")
+ .append("role_id", "")
+ .append("invite_detect", false)
+ .append("starboard", "")
+ .append("neededstars", "4")
+ );
+ }
+
+ public void push(MongoServer server) {
+ Document object = new Document();
+ for (Field field : server.getClass().getDeclaredFields()) {
+ if (!field.getName().equals("mongo")) {
+ try {
+ object.append(field.getName(), field.get(server));
+ } catch (IllegalAccessException e) {
+ e.printStackTrace();
+ }
+ }
+ }
+
+ BasicDBObject whereQuery = new BasicDBObject();
+ whereQuery.put("id", server.getId());
+
+ BasicDBObject updateObject = new BasicDBObject();
+ updateObject.put("$set", object);
+
+ db.getCollection("server").updateOne(whereQuery, updateObject);
+ }
+
+ public void push(MongoUser user) {
+ Document object = new Document();
+ for (Field field : user.getClass().getDeclaredFields()) {
+ if (!field.getName().equals("mongo")) {
+ try {
+ object.append(field.getName(), field.get(user));
+ } catch (IllegalAccessException e) {
+ e.printStackTrace();
+ }
+ }
+ }
+
+ BasicDBObject whereQuery = new BasicDBObject();
+ whereQuery.put("id", user.getId());
+
+ BasicDBObject updateObject = new BasicDBObject();
+ updateObject.put("$set", object);
+
+ db.getCollection("user").updateOne(whereQuery, updateObject);
+ }
+
+ public boolean hasStarboardMessage(String message_id) {
+ this.getByID("stars", "id", message_id, "guild");
+ return true;
+ }
+
+ public void insertStarboardMessage(String message_id, String guild_id, String starboard_message_id) {
+ this.insert("stars", new Document("id", message_id).append("guild", guild_id).append("starboardmsg", starboard_message_id));
+ }
+
+ public String getStarboardMessage(String message_id) {
+ return (String) this.getByID("stars", "id", message_id, "starboardmsg");
+ }
+
+ public void removeStarboardMessage(String message_id) {
+ this.remove("stars", "id", message_id);
+ }
+}
diff --git a/src/main/java/com/bbn/hadder/db/RethinkServer.java b/src/main/java/one/bbn/hadder/db/MongoServer.java
similarity index 92%
rename from src/main/java/com/bbn/hadder/db/RethinkServer.java
rename to src/main/java/one/bbn/hadder/db/MongoServer.java
index 0993922..77844c0 100644
--- a/src/main/java/com/bbn/hadder/db/RethinkServer.java
+++ b/src/main/java/one/bbn/hadder/db/MongoServer.java
@@ -14,15 +14,15 @@
* limitations under the License.
*/
-package com.bbn.hadder.db;
+package one.bbn.hadder.db;
import org.json.JSONObject;
import java.lang.reflect.Field;
-public class RethinkServer {
+public class MongoServer {
- private Rethink rethink;
+ private Mongo mongo;
public String accept_emote = "";
public String decline_emote = "";
@@ -34,9 +34,9 @@ public class RethinkServer {
public String role_id = "";
public String starboard = "";
- public RethinkServer(JSONObject object, Rethink rethink) {
+ public MongoServer(JSONObject object, Mongo mongo) {
for (Field field : this.getClass().getDeclaredFields()) {
- if (!field.getName().equals("rethink")) {
+ if (!field.getName().equals("mongo")) {
try {
if (object.has(field.getName()))
field.set(this, object.get(field.getName()));
@@ -45,7 +45,7 @@ public class RethinkServer {
}
}
}
- this.rethink = rethink;
+ this.mongo = mongo;
}
public String getAcceptEmote() {
@@ -128,6 +128,6 @@ public class RethinkServer {
}
public void push() {
- rethink.push(this);
+ mongo.push(this);
}
}
diff --git a/src/main/java/com/bbn/hadder/db/RethinkUser.java b/src/main/java/one/bbn/hadder/db/MongoUser.java
similarity index 84%
rename from src/main/java/com/bbn/hadder/db/RethinkUser.java
rename to src/main/java/one/bbn/hadder/db/MongoUser.java
index ba65bc3..af86c4f 100644
--- a/src/main/java/com/bbn/hadder/db/RethinkUser.java
+++ b/src/main/java/one/bbn/hadder/db/MongoUser.java
@@ -14,24 +14,24 @@
* limitations under the License.
*/
-package com.bbn.hadder.db;
+package one.bbn.hadder.db;
import org.json.JSONObject;
import java.lang.reflect.Field;
-public class RethinkUser {
+public class MongoUser {
- private Rethink rethink;
+ private Mongo mongo;
public String id;
public String prefix = "h.";
public String language = "en";
public String blacklisted = "none";
- public RethinkUser(JSONObject object, Rethink rethink) {
+ public MongoUser(JSONObject object, Mongo mongo) {
for (Field field : this.getClass().getDeclaredFields()) {
- if (!field.getName().equals("rethink")) {
+ if (!field.getName().equals("mongo")) {
try {
if (object.has(field.getName()))
field.set(this, object.getString(field.getName()));
@@ -40,11 +40,11 @@ public class RethinkUser {
}
}
}
- this.rethink = rethink;
+ this.mongo = mongo;
}
- public Rethink getRethink() {
- return rethink;
+ public Mongo getMongo() {
+ return mongo;
}
public String getId() {
@@ -76,6 +76,6 @@ public class RethinkUser {
}
public void push() {
- rethink.push(this);
+ mongo.push(this);
}
}
diff --git a/src/main/java/com/bbn/hadder/listener/CommandListener.java b/src/main/java/one/bbn/hadder/listener/CommandListener.java
similarity index 77%
rename from src/main/java/com/bbn/hadder/listener/CommandListener.java
rename to src/main/java/one/bbn/hadder/listener/CommandListener.java
index 521912c..2dca246 100644
--- a/src/main/java/com/bbn/hadder/listener/CommandListener.java
+++ b/src/main/java/one/bbn/hadder/listener/CommandListener.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,13 +14,13 @@
* limitations under the License.
*/
-package com.bbn.hadder.listener;
+package one.bbn.hadder.listener;
-import com.bbn.hadder.audio.AudioManager;
-import com.bbn.hadder.core.CommandHandler;
-import com.bbn.hadder.db.Rethink;
-import com.bbn.hadder.db.RethinkServer;
-import com.bbn.hadder.db.RethinkUser;
+import one.bbn.hadder.audio.AudioManager;
+import one.bbn.hadder.core.CommandHandler;
+import one.bbn.hadder.db.Mongo;
+import one.bbn.hadder.db.MongoServer;
+import one.bbn.hadder.db.MongoUser;
import net.dv8tion.jda.api.EmbedBuilder;
import net.dv8tion.jda.api.Permission;
import net.dv8tion.jda.api.entities.ChannelType;
@@ -33,12 +33,12 @@ import java.time.Instant;
public class CommandListener extends ListenerAdapter {
- private final Rethink rethink;
+ private final Mongo mongo;
private final CommandHandler handler;
private final AudioManager audioManager;
- public CommandListener(Rethink rethink, CommandHandler handler, AudioManager audioManager) {
- this.rethink = rethink;
+ public CommandListener(Mongo mongo, CommandHandler handler, AudioManager audioManager) {
+ this.mongo = mongo;
this.handler = handler;
this.audioManager = audioManager;
}
@@ -48,19 +48,19 @@ public class CommandListener extends ListenerAdapter {
if (e.isFromType(ChannelType.TEXT) && !e.getAuthor().isBot()) {
if (e.getGuild().getSelfMember().hasPermission(Permission.MESSAGE_WRITE)) {
if (e.getGuild().getSelfMember().hasPermission(Permission.MESSAGE_EMBED_LINKS)) {
- RethinkUser rethinkUser = new RethinkUser(rethink.getObjectByID("user", e.getAuthor().getId()), rethink);
- RethinkServer rethinkServer = new RethinkServer(rethink.getObjectByID("server", e.getGuild().getId()), rethink);
- rethinkUser.push();
- rethinkServer.push();
+ MongoUser mongoUser = new MongoUser(mongo.getObjectByID("user", e.getAuthor().getId()), mongo);
+ MongoServer mongoServer = new MongoServer(mongo.getObjectByID("server", e.getGuild().getId()), mongo);
+ mongoUser.push();
+ mongoServer.push();
String[] prefixes = {
- rethinkUser.getPrefix(), rethinkServer.getPrefix(),
+ mongoUser.getPrefix(), mongoServer.getPrefix(),
e.getGuild().getSelfMember().getAsMention() + " ", e.getGuild().getSelfMember().getAsMention(),
e.getGuild().getSelfMember().getAsMention().replace("@", "@!") + " ",
e.getGuild().getSelfMember().getAsMention().replace("@", "@!")
};
for (String prefix : prefixes) {
if (e.getMessage().getContentRaw().startsWith(prefix)) {
- handler.handle(e, rethink, prefix, audioManager, rethinkUser, rethinkServer);
+ handler.handle(e, mongo, prefix, audioManager, mongoUser, mongoServer);
return;
}
}
diff --git a/src/main/java/com/bbn/hadder/listener/GuildListener.java b/src/main/java/one/bbn/hadder/listener/GuildListener.java
similarity index 77%
rename from src/main/java/com/bbn/hadder/listener/GuildListener.java
rename to src/main/java/one/bbn/hadder/listener/GuildListener.java
index 1d09b4f..a940ed3 100644
--- a/src/main/java/com/bbn/hadder/listener/GuildListener.java
+++ b/src/main/java/one/bbn/hadder/listener/GuildListener.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,13 +14,12 @@
* limitations under the License.
*/
-package com.bbn.hadder.listener;
+package one.bbn.hadder.listener;
-import com.bbn.hadder.core.Config;
-import com.bbn.hadder.db.Rethink;
-import com.bbn.hadder.utils.BotList;
-import com.bbn.hadder.utils.MessageEditor;
-import net.dv8tion.jda.api.entities.Member;
+import one.bbn.hadder.core.Config;
+import one.bbn.hadder.db.Mongo;
+import one.bbn.hadder.utils.BotList;
+import one.bbn.hadder.utils.MessageEditor;
import net.dv8tion.jda.api.events.guild.GuildJoinEvent;
import net.dv8tion.jda.api.events.guild.GuildLeaveEvent;
import net.dv8tion.jda.api.events.guild.member.GuildMemberJoinEvent;
@@ -30,24 +29,16 @@ import java.time.Instant;
public class GuildListener extends ListenerAdapter {
- private final Rethink rethink;
+ private final Mongo mongo;
private final Config config;
- public GuildListener(Rethink rethink, Config config) {
- this.rethink = rethink;
+ public GuildListener(Mongo mongo, Config config) {
+ this.mongo = mongo;
this.config = config;
}
public void onGuildJoin(GuildJoinEvent e) {
- new Thread(() -> {
- for (Member member : e.getGuild().getMembers()) {
- if (!member.getUser().getId().equals(e.getJDA().getSelfUser().getId())) {
- rethink.insertUser(member.getUser().getId());
- }
- }
- }).start();
-
- rethink.insertGuild(e.getGuild().getId());
+ mongo.insertGuild(e.getGuild().getId());
e.getJDA().getTextChannelById("759783393230979142").sendMessage(new MessageEditor(null, null).getMessage(MessageEditor.MessageType.INFO)
.setTitle("Joined Server")
.setThumbnail(e.getGuild().getIconUrl())
@@ -79,7 +70,7 @@ public class GuildListener extends ListenerAdapter {
public void onGuildMemberJoin(GuildMemberJoinEvent e) {
if (!e.getUser().getId().equals(e.getJDA().getSelfUser().getId())) {
- rethink.insertUser(e.getUser().getId());
+ mongo.insertUser(e.getUser().getId());
}
}
}
diff --git a/src/main/java/com/bbn/hadder/listener/InviteLinkListener.java b/src/main/java/one/bbn/hadder/listener/InviteLinkListener.java
similarity index 84%
rename from src/main/java/com/bbn/hadder/listener/InviteLinkListener.java
rename to src/main/java/one/bbn/hadder/listener/InviteLinkListener.java
index f845009..f293935 100644
--- a/src/main/java/com/bbn/hadder/listener/InviteLinkListener.java
+++ b/src/main/java/one/bbn/hadder/listener/InviteLinkListener.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,10 +14,10 @@
* limitations under the License.
*/
-package com.bbn.hadder.listener;
+package one.bbn.hadder.listener;
-import com.bbn.hadder.db.Rethink;
-import com.bbn.hadder.db.RethinkServer;
+import one.bbn.hadder.db.Mongo;
+import one.bbn.hadder.db.MongoServer;
import net.dv8tion.jda.api.Permission;
import net.dv8tion.jda.api.entities.ChannelType;
import net.dv8tion.jda.api.entities.Guild;
@@ -35,10 +35,10 @@ import javax.annotation.Nonnull;
public class InviteLinkListener extends ListenerAdapter {
- private Rethink rethink;
+ private Mongo mongo;
- public InviteLinkListener(Rethink rethink) {
- this.rethink = rethink;
+ public InviteLinkListener(Mongo mongo) {
+ this.mongo = mongo;
}
@Override
@@ -68,12 +68,12 @@ public class InviteLinkListener extends ListenerAdapter {
}
public void scanMessage(Guild guild, Message message, Member member) {
- RethinkServer rethinkServer = new RethinkServer(rethink.getObjectByID("server", guild.getId()), rethink);
- if (message.getContentRaw().contains("discord.gg/") && !member.hasPermission(Permission.ADMINISTRATOR) && rethinkServer.hasInviteDetect()) {
+ MongoServer mongoServer = new MongoServer(mongo.getObjectByID("server", guild.getId()), mongo);
+ if (message.getContentRaw().contains("discord.gg/") && !member.hasPermission(Permission.ADMINISTRATOR) && mongoServer.hasInviteDetect()) {
checkInvite(message, "discord.gg/");
- } else if (message.getContentRaw().contains("discord.com/invite") && !member.hasPermission(Permission.ADMINISTRATOR) && rethinkServer.hasInviteDetect()) {
+ } else if (message.getContentRaw().contains("discord.com/invite") && !member.hasPermission(Permission.ADMINISTRATOR) && mongoServer.hasInviteDetect()) {
checkInvite(message, "discord.com/invite/");
- } else if (message.getContentRaw().contains("discordapp.com/invite") && !member.hasPermission(Permission.ADMINISTRATOR) && rethinkServer.hasInviteDetect()) {
+ } else if (message.getContentRaw().contains("discordapp.com/invite") && !member.hasPermission(Permission.ADMINISTRATOR) && mongoServer.hasInviteDetect()) {
checkInvite(message, "discordapp.com/invite/");
}
}
diff --git a/src/main/java/com/bbn/hadder/listener/MentionListener.java b/src/main/java/one/bbn/hadder/listener/MentionListener.java
similarity index 79%
rename from src/main/java/com/bbn/hadder/listener/MentionListener.java
rename to src/main/java/one/bbn/hadder/listener/MentionListener.java
index 8c7c8c8..830eef8 100644
--- a/src/main/java/com/bbn/hadder/listener/MentionListener.java
+++ b/src/main/java/one/bbn/hadder/listener/MentionListener.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,12 +14,12 @@
* limitations under the License.
*/
-package com.bbn.hadder.listener;
+package one.bbn.hadder.listener;
-import com.bbn.hadder.core.Config;
-import com.bbn.hadder.db.Rethink;
-import com.bbn.hadder.db.RethinkServer;
-import com.bbn.hadder.db.RethinkUser;
+import one.bbn.hadder.core.Config;
+import one.bbn.hadder.db.Mongo;
+import one.bbn.hadder.db.MongoServer;
+import one.bbn.hadder.db.MongoUser;
import net.dv8tion.jda.api.EmbedBuilder;
import net.dv8tion.jda.api.entities.ChannelType;
import net.dv8tion.jda.api.events.message.MessageReceivedEvent;
@@ -33,19 +33,19 @@ import java.util.Random;
public class MentionListener extends ListenerAdapter {
- private final Rethink rethink;
+ private final Mongo mongo;
private final Config config;
- public MentionListener(Rethink rethink, Config config) {
- this.rethink = rethink;
+ public MentionListener(Mongo mongo, Config config) {
+ this.mongo = mongo;
this.config = config;
}
@Override
public void onMessageReceived(@Nonnull MessageReceivedEvent e) {
if (!e.getAuthor().isBot() && e.isFromType(ChannelType.TEXT)) {
- RethinkServer rethinkServer = new RethinkServer(rethink.getObjectByID("server", e.getGuild().getId()), rethink);
- RethinkUser rethinkUser = new RethinkUser(rethink.getObjectByID("user", e.getAuthor().getId()), rethink);
+ MongoServer mongoServer = new MongoServer(mongo.getObjectByID("server", e.getGuild().getId()), mongo);
+ MongoUser mongoUser = new MongoUser(mongo.getObjectByID("user", e.getAuthor().getId()), mongo);
if (e.isFromType(ChannelType.TEXT) && (e.getMessage().getContentRaw().equals(e.getGuild().getSelfMember().getAsMention()) ||
e.getMessage().getContentRaw().equals(e.getGuild().getSelfMember().getAsMention().replace("@", "@!")))) {
@@ -62,8 +62,8 @@ public class MentionListener extends ListenerAdapter {
EmbedBuilder builder = new EmbedBuilder()
.setTitle("Hi!")
.addField("Version", version, false)
- .addField("User-Prefix", rethinkUser.getPrefix(), true)
- .addField("Guild-Prefix", rethinkServer.getPrefix(), true)
+ .addField("User-Prefix", mongoUser.getPrefix(), true)
+ .addField("Guild-Prefix", mongoServer.getPrefix(), true)
.addField("Join our Dev Server!", "[Click here!](https://discord.gg/nPwjaJk)", true)
.addField("Github", "[Click here!](https://github.com/BigBotNetwork/Hadder)", false)
.addField("Twitch", "[Click here!](https://www.twitch.tv/bigbotnetwork)", false);
diff --git a/src/main/java/com/bbn/hadder/listener/OwnerMessageListener.java b/src/main/java/one/bbn/hadder/listener/OwnerMessageListener.java
similarity index 64%
rename from src/main/java/com/bbn/hadder/listener/OwnerMessageListener.java
rename to src/main/java/one/bbn/hadder/listener/OwnerMessageListener.java
index db0736b..77795e0 100644
--- a/src/main/java/com/bbn/hadder/listener/OwnerMessageListener.java
+++ b/src/main/java/one/bbn/hadder/listener/OwnerMessageListener.java
@@ -1,10 +1,22 @@
/*
- * @author Hax / Hax6775 / Schlauer_Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
+ *
+ * Licensed under the GNU Affero General Public License, Version 3.0;
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * https://www.gnu.org/licenses/agpl-3.0.en.html
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
*/
-package com.bbn.hadder.listener;
+package one.bbn.hadder.listener;
-import com.bbn.hadder.core.Config;
+import one.bbn.hadder.core.Config;
import net.dv8tion.jda.api.entities.Emote;
import net.dv8tion.jda.api.events.message.MessageReceivedEvent;
import net.dv8tion.jda.api.hooks.ListenerAdapter;
diff --git a/src/main/java/com/bbn/hadder/listener/PrivateMessageListener.java b/src/main/java/one/bbn/hadder/listener/PrivateMessageListener.java
similarity index 83%
rename from src/main/java/com/bbn/hadder/listener/PrivateMessageListener.java
rename to src/main/java/one/bbn/hadder/listener/PrivateMessageListener.java
index f931313..28e0107 100644
--- a/src/main/java/com/bbn/hadder/listener/PrivateMessageListener.java
+++ b/src/main/java/one/bbn/hadder/listener/PrivateMessageListener.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,11 +14,11 @@
* limitations under the License.
*/
-package com.bbn.hadder.listener;
+package one.bbn.hadder.listener;
-import com.bbn.hadder.db.Rethink;
-import com.bbn.hadder.db.RethinkUser;
-import com.bbn.hadder.utils.MessageEditor;
+import one.bbn.hadder.db.Mongo;
+import one.bbn.hadder.db.MongoUser;
+import one.bbn.hadder.utils.MessageEditor;
import net.dv8tion.jda.api.EmbedBuilder;
import net.dv8tion.jda.api.entities.ChannelType;
import net.dv8tion.jda.api.entities.PrivateChannel;
@@ -30,18 +30,18 @@ import java.time.Instant;
public class PrivateMessageListener extends ListenerAdapter {
- private final Rethink rethink;
+ private final Mongo mongo;
- public PrivateMessageListener(Rethink rethink) {
- this.rethink = rethink;
+ public PrivateMessageListener(Mongo mongo) {
+ this.mongo = mongo;
}
public void onMessageReceived(MessageReceivedEvent e) {
if (e.isFromType(ChannelType.PRIVATE) && !e.getAuthor().getId().equals(e.getJDA().getSelfUser().getId())) {
PrivateChannel Skidder = e.getJDA().getUserById("401817301919465482").openPrivateChannel().complete();
PrivateChannel Hax = e.getJDA().getUserById("261083609148948488").openPrivateChannel().complete();
- RethinkUser HaxUser = new RethinkUser(rethink.getObjectByID("user", "261083609148948488"), rethink);
- RethinkUser SkidderUser = new RethinkUser(rethink.getObjectByID("user", "261083609148948488"), rethink);
+ MongoUser HaxUser = new MongoUser(mongo.getObjectByID("user", "261083609148948488"), mongo);
+ MongoUser SkidderUser = new MongoUser(mongo.getObjectByID("user", "261083609148948488"), mongo);
Skidder.sendMessage(new MessageEditor(SkidderUser, e.getJDA().getUserById("401817301919465482")).getMessage(MessageEditor.MessageType.INFO)
.setTitle("New DM by " + e.getAuthor().getAsTag())
diff --git a/src/main/java/com/bbn/hadder/listener/ReadyListener.java b/src/main/java/one/bbn/hadder/listener/ReadyListener.java
similarity index 50%
rename from src/main/java/com/bbn/hadder/listener/ReadyListener.java
rename to src/main/java/one/bbn/hadder/listener/ReadyListener.java
index 323f62b..407db51 100644
--- a/src/main/java/com/bbn/hadder/listener/ReadyListener.java
+++ b/src/main/java/one/bbn/hadder/listener/ReadyListener.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,43 +14,25 @@
* limitations under the License.
*/
-package com.bbn.hadder.listener;
+package one.bbn.hadder.listener;
-import com.bbn.hadder.core.Config;
-import com.bbn.hadder.db.Rethink;
-import com.bbn.hadder.utils.BotList;
-import net.dv8tion.jda.api.entities.Guild;
-import net.dv8tion.jda.api.entities.User;
+import one.bbn.hadder.core.Config;
import net.dv8tion.jda.api.events.ReadyEvent;
import net.dv8tion.jda.api.hooks.ListenerAdapter;
+import one.bbn.hadder.utils.BotList;
import javax.annotation.Nonnull;
public class ReadyListener extends ListenerAdapter {
- private final Rethink rethink;
private final Config config;
- public ReadyListener(Rethink rethink, Config config) {
- this.rethink = rethink;
+ public ReadyListener(Config config) {
this.config = config;
}
@Override
public void onReady(@Nonnull ReadyEvent e) {
- rethink.setup();
- new Thread(() -> {
- for (User user : e.getJDA().getUsers()) {
- if (!user.getId().equals(e.getJDA().getSelfUser().getId())) {
- rethink.insertUser(user.getId());
- }
- }
- for (Guild g : e.getJDA().getGuilds()) {
- rethink.insertGuild(g.getId());
- }
- }).start();
-
- //TODO: Renew all bot lists
- //new BotList(config).post();
+ new BotList(config).post();
}
}
diff --git a/src/main/java/com/bbn/hadder/listener/RulesListener.java b/src/main/java/one/bbn/hadder/listener/RulesListener.java
similarity index 58%
rename from src/main/java/com/bbn/hadder/listener/RulesListener.java
rename to src/main/java/one/bbn/hadder/listener/RulesListener.java
index 5a58835..b64d2c3 100644
--- a/src/main/java/com/bbn/hadder/listener/RulesListener.java
+++ b/src/main/java/one/bbn/hadder/listener/RulesListener.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,39 +14,39 @@
* limitations under the License.
*/
-package com.bbn.hadder.listener;
+package one.bbn.hadder.listener;
-import com.bbn.hadder.db.Rethink;
-import com.bbn.hadder.db.RethinkServer;
+import one.bbn.hadder.db.Mongo;
+import one.bbn.hadder.db.MongoServer;
import net.dv8tion.jda.api.events.message.react.MessageReactionAddEvent;
import net.dv8tion.jda.api.events.message.react.MessageReactionRemoveEvent;
import net.dv8tion.jda.api.hooks.ListenerAdapter;
public class RulesListener extends ListenerAdapter {
- private final Rethink rethink;
+ private final Mongo mongo;
- public RulesListener(Rethink rethink) {
- this.rethink = rethink;
+ public RulesListener(Mongo mongo) {
+ this.mongo = mongo;
}
@Override
public void onMessageReactionAdd(MessageReactionAddEvent e) {
- RethinkServer rethinkServer = new RethinkServer(rethink.getObjectByID("server", e.getGuild().getId()), rethink);
- if (e.getMessageId().equals(rethinkServer.getMessageID()) && !e.getUser().isBot()) {
+ MongoServer mongoServer = new MongoServer(mongo.getObjectByID("server", e.getGuild().getId()), mongo);
+ if (e.getMessageId().equals(mongoServer.getMessageID()) && !e.getUser().isBot()) {
if (e.getReactionEmote().isEmote()) {
- if (rethinkServer.getAcceptEmote().equals(e.getReactionEmote().getId())) {
+ if (mongoServer.getAcceptEmote().equals(e.getReactionEmote().getId())) {
addRole(e);
- } else if (rethinkServer.getDeclineEmote().equals(e.getReactionEmote().getId())) {
+ } else if (mongoServer.getDeclineEmote().equals(e.getReactionEmote().getId())) {
e.getReaction().removeReaction(e.getUser()).queue();
if (e.getGuild().getSelfMember().canInteract(e.getMember())) {
e.getMember().kick().reason("Declined the rules");
}
}
} else if (e.getReactionEmote().isEmoji()) {
- if (rethinkServer.getAcceptEmote().equals(e.getReactionEmote().getEmoji())) {
+ if (mongoServer.getAcceptEmote().equals(e.getReactionEmote().getEmoji())) {
addRole(e);
- } else if (rethinkServer.getDeclineEmote().equals(e.getReactionEmote().getEmoji())) {
+ } else if (mongoServer.getDeclineEmote().equals(e.getReactionEmote().getEmoji())) {
e.getReaction().removeReaction(e.getUser()).queue();
if (e.getGuild().getSelfMember().canInteract(e.getMember())) {
e.getMember().kick().reason("Declined the rules");
@@ -57,18 +57,18 @@ public class RulesListener extends ListenerAdapter {
}
private void addRole(MessageReactionAddEvent e) {
- RethinkServer rethinkServer = new RethinkServer(rethink.getObjectByID("server", e.getGuild().getId()), rethink);
- if (e.getMember().getRoles().contains(e.getGuild().getRoleById(rethinkServer.getRoleID()))) {
- e.getGuild().removeRoleFromMember(e.getMember(), e.getGuild().getRoleById(rethinkServer.getRoleID())).reason("Accepted rules").queue();
+ MongoServer mongoServer = new MongoServer(mongo.getObjectByID("server", e.getGuild().getId()), mongo);
+ if (e.getMember().getRoles().contains(e.getGuild().getRoleById(mongoServer.getRoleID()))) {
+ e.getGuild().removeRoleFromMember(e.getMember(), e.getGuild().getRoleById(mongoServer.getRoleID())).reason("Accepted rules").queue();
} else
- e.getGuild().addRoleToMember(e.getMember(), e.getGuild().getRoleById(rethinkServer.getRoleID())).reason("Accepted rules").queue();
+ e.getGuild().addRoleToMember(e.getMember(), e.getGuild().getRoleById(mongoServer.getRoleID())).reason("Accepted rules").queue();
}
@Override
public void onMessageReactionRemove(MessageReactionRemoveEvent e) {
- RethinkServer rethinkServer = new RethinkServer(rethink.getObjectByID("server", e.getGuild().getId()), rethink);
- if (e.getMessageId().equals(rethinkServer.getMessageID()) && !e.getUser().isBot()) {
- e.getGuild().removeRoleFromMember(e.getMember(), e.getGuild().getRoleById(rethinkServer.getRoleID())).reason("Withdrawal of the acceptance of the rules").queue();
+ MongoServer mongoServer = new MongoServer(mongo.getObjectByID("server", e.getGuild().getId()), mongo);
+ if (e.getMessageId().equals(mongoServer.getMessageID()) && !e.getUser().isBot()) {
+ e.getGuild().removeRoleFromMember(e.getMember(), e.getGuild().getRoleById(mongoServer.getRoleID())).reason("Withdrawal of the acceptance of the rules").queue();
}
}
}
diff --git a/src/main/java/com/bbn/hadder/listener/StarboardListener.java b/src/main/java/one/bbn/hadder/listener/StarboardListener.java
similarity index 79%
rename from src/main/java/com/bbn/hadder/listener/StarboardListener.java
rename to src/main/java/one/bbn/hadder/listener/StarboardListener.java
index dc1226a..4f77a93 100644
--- a/src/main/java/com/bbn/hadder/listener/StarboardListener.java
+++ b/src/main/java/one/bbn/hadder/listener/StarboardListener.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,10 +14,10 @@
* limitations under the License.
*/
-package com.bbn.hadder.listener;
+package one.bbn.hadder.listener;
-import com.bbn.hadder.db.Rethink;
-import com.bbn.hadder.db.RethinkServer;
+import one.bbn.hadder.db.Mongo;
+import one.bbn.hadder.db.MongoServer;
import net.dv8tion.jda.api.EmbedBuilder;
import net.dv8tion.jda.api.MessageBuilder;
import net.dv8tion.jda.api.entities.MessageReaction;
@@ -30,10 +30,10 @@ import javax.annotation.Nonnull;
public class StarboardListener extends ListenerAdapter {
- private final Rethink rethink;
+ private final Mongo mongo;
- public StarboardListener(Rethink rethink) {
- this.rethink = rethink;
+ public StarboardListener(Mongo mongo) {
+ this.mongo = mongo;
}
@Override
@@ -48,9 +48,9 @@ public class StarboardListener extends ListenerAdapter {
public void update(GenericMessageReactionEvent e) {
if (e.getReaction().getReactionEmote().getName().equals("⭐")) {
- RethinkServer rethinkServer = new RethinkServer(rethink.getObjectByID("server", e.getGuild().getId()), rethink);
- if (!rethink.hasStarboardMessage(e.getMessageId())) {
- if (rethinkServer.hasStarboardChannel()) {
+ MongoServer mongoServer = new MongoServer(mongo.getObjectByID("server", e.getGuild().getId()), mongo);
+ if (!mongo.hasStarboardMessage(e.getMessageId())) {
+ if (mongoServer.hasStarboardChannel()) {
e.getTextChannel().retrieveMessageById(e.getMessageId()).queue(
msg -> {
int stars = 0;
@@ -60,8 +60,8 @@ public class StarboardListener extends ListenerAdapter {
}
}
- if (Integer.parseInt(rethinkServer.getNeededStars()) <= stars) {
- e.getGuild().getTextChannelById(rethinkServer.getStarboard())
+ if (Integer.parseInt(mongoServer.getNeededStars()) <= stars) {
+ e.getGuild().getTextChannelById(mongoServer.getStarboard())
.sendMessage(new MessageBuilder()
.setContent("⭐ 1" + " " + e.getTextChannel().getAsMention())
.setEmbed(
@@ -70,7 +70,7 @@ public class StarboardListener extends ListenerAdapter {
.setDescription(msg.getContentRaw())
.setTimestamp(msg.getTimeCreated()).build()).build()).queue(
starboardmsg -> {
- rethink.insertStarboardMessage(msg.getId(), e.getGuild().getId(), starboardmsg.getId());
+ mongo.insertStarboardMessage(msg.getId(), e.getGuild().getId(), starboardmsg.getId());
}
);
}
@@ -90,11 +90,11 @@ public class StarboardListener extends ListenerAdapter {
}
int finalStars = stars;
- e.getGuild().getTextChannelById(rethinkServer.getStarboard())
- .retrieveMessageById(rethink.getStarboardMessage(e.getMessageId())).queue(
+ e.getGuild().getTextChannelById(mongoServer.getStarboard())
+ .retrieveMessageById(mongo.getStarboardMessage(e.getMessageId())).queue(
msg2 -> {
- if (Integer.parseInt(rethinkServer.getNeededStars()) <= finalStars) {
+ if (Integer.parseInt(mongoServer.getNeededStars()) <= finalStars) {
msg2.editMessage(new MessageBuilder()
.setContent("⭐ " + finalStars + " " + e.getTextChannel().getAsMention())
.setEmbed(
@@ -104,7 +104,7 @@ public class StarboardListener extends ListenerAdapter {
.setTimestamp(msg.getTimeCreated()).build()).build()).queue();
} else {
msg2.delete().queue();
- rethink.removeStarboardMessage(msg.getId());
+ mongo.removeStarboardMessage(msg.getId());
}
}
);
diff --git a/src/main/java/com/bbn/hadder/listener/VoiceLeaveListener.java b/src/main/java/one/bbn/hadder/listener/VoiceLeaveListener.java
similarity index 92%
rename from src/main/java/com/bbn/hadder/listener/VoiceLeaveListener.java
rename to src/main/java/one/bbn/hadder/listener/VoiceLeaveListener.java
index aeeb667..7780f8c 100644
--- a/src/main/java/com/bbn/hadder/listener/VoiceLeaveListener.java
+++ b/src/main/java/one/bbn/hadder/listener/VoiceLeaveListener.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,9 +14,9 @@
* limitations under the License.
*/
-package com.bbn.hadder.listener;
+package one.bbn.hadder.listener;
-import com.bbn.hadder.audio.AudioManager;
+import one.bbn.hadder.audio.AudioManager;
import net.dv8tion.jda.api.events.guild.voice.GuildVoiceLeaveEvent;
import net.dv8tion.jda.api.hooks.ListenerAdapter;
diff --git a/src/main/java/one/bbn/hadder/utils/BotList.java b/src/main/java/one/bbn/hadder/utils/BotList.java
new file mode 100644
index 0000000..507e9ba
--- /dev/null
+++ b/src/main/java/one/bbn/hadder/utils/BotList.java
@@ -0,0 +1,71 @@
+/*
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
+ *
+ * Licensed under the GNU Affero General Public License, Version 3.0;
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * https://www.gnu.org/licenses/agpl-3.0.en.html
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package one.bbn.hadder.utils;
+
+import one.bbn.hadder.Hadder;
+import one.bbn.hadder.core.Config;
+import okhttp3.MediaType;
+import okhttp3.OkHttpClient;
+import okhttp3.Request;
+import okhttp3.RequestBody;
+import org.json.JSONObject;
+
+import java.io.IOException;
+import java.nio.file.Files;
+import java.nio.file.Paths;
+
+public class BotList {
+
+ private static String BotList = "https://";
+
+ private Config config;
+
+ public BotList(Config config) {
+ this.config = config;
+ }
+
+ public void post() {
+// if (Files.notExists(Paths.get("./DEBUG"))) {
+// JSONObject json = new JSONObject();
+// json.put("server_count", Hadder.shardManager.getGuilds().size());
+// json.put("guildCount", Hadder.shardManager.getGuilds().size());
+// json.put("guilds", Hadder.shardManager.getGuilds().size());
+// json.put("count", Hadder.shardManager.getGuilds().size());
+// json.put("users", Hadder.shardManager.getUsers().size());
+// json.put("shard_count", Hadder.shardManager.getShards().size());
+// json.put("shardCount", Hadder.shardManager.getShards().size());
+// json.put("member_count", Hadder.shardManager.getUsers().size());
+//
+// RequestBody body = RequestBody.create(MediaType.parse("application/json"), json.toString());
+//
+// // Mythical Bot List
+//
+// Request botlist = new Request.Builder()
+// .url(BotList)
+// .post(body)
+// .addHeader("Authorization", config.getBotListToken())
+// .build();
+//
+// try {
+// new OkHttpClient().newCall(botlist).execute().close();
+// System.out.println("Successfully posted count for the !");
+// } catch (IOException e) {
+// e.printStackTrace();
+// }
+// }
+ }
+}
diff --git a/src/main/java/com/bbn/hadder/utils/EventWaiter.java b/src/main/java/one/bbn/hadder/utils/EventWaiter.java
similarity index 96%
rename from src/main/java/com/bbn/hadder/utils/EventWaiter.java
rename to src/main/java/one/bbn/hadder/utils/EventWaiter.java
index c07120b..5a8ac5f 100644
--- a/src/main/java/com/bbn/hadder/utils/EventWaiter.java
+++ b/src/main/java/one/bbn/hadder/utils/EventWaiter.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-package com.bbn.hadder.utils;
+package one.bbn.hadder.utils;
import net.dv8tion.jda.api.JDA;
import net.dv8tion.jda.api.entities.User;
diff --git a/src/main/java/com/bbn/hadder/utils/Http.java b/src/main/java/one/bbn/hadder/utils/Http.java
similarity index 94%
rename from src/main/java/com/bbn/hadder/utils/Http.java
rename to src/main/java/one/bbn/hadder/utils/Http.java
index 3caa009..26d80c4 100644
--- a/src/main/java/com/bbn/hadder/utils/Http.java
+++ b/src/main/java/one/bbn/hadder/utils/Http.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,7 +14,7 @@
* limitations under the License.
*/
-package com.bbn.hadder.utils;
+package one.bbn.hadder.utils;
import okhttp3.OkHttpClient;
import okhttp3.Response;
diff --git a/src/main/java/com/bbn/hadder/utils/MessageEditor.java b/src/main/java/one/bbn/hadder/utils/MessageEditor.java
similarity index 91%
rename from src/main/java/com/bbn/hadder/utils/MessageEditor.java
rename to src/main/java/one/bbn/hadder/utils/MessageEditor.java
index 7f1f80e..c1b74e0 100644
--- a/src/main/java/com/bbn/hadder/utils/MessageEditor.java
+++ b/src/main/java/one/bbn/hadder/utils/MessageEditor.java
@@ -1,5 +1,5 @@
/*
- * Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+ * Copyright 2019-2021 GregTCLTK and Schlauer-Hax
*
* Licensed under the GNU Affero General Public License, Version 3.0;
* you may not use this file except in compliance with the License.
@@ -14,9 +14,9 @@
* limitations under the License.
*/
-package com.bbn.hadder.utils;
+package one.bbn.hadder.utils;
-import com.bbn.hadder.db.RethinkUser;
+import one.bbn.hadder.db.MongoUser;
import net.dv8tion.jda.api.EmbedBuilder;
import net.dv8tion.jda.api.entities.User;
@@ -27,11 +27,11 @@ import java.util.ResourceBundle;
public class MessageEditor {
- private final RethinkUser rethinkUser;
+ private final MongoUser mongoUser;
private final User user;
- public MessageEditor(RethinkUser rethinkUser, User user) {
- this.rethinkUser = rethinkUser;
+ public MessageEditor(MongoUser mongoUser, User user) {
+ this.mongoUser = mongoUser;
this.user = user;
}
@@ -50,7 +50,7 @@ public class MessageEditor {
public EmbedBuilder getMessage(MessageType type, String title, String title_extra, String title_extra_two,
String description, String description_extra, String description_extra_two) {
- String language = (this.user != null) ? rethinkUser.getLanguage() : null;
+ String language = (this.user != null) ? mongoUser.getLanguage() : null;
EmbedBuilder eb = this.getDefaultSettings(type);
if (!"".equals(title)) eb.setTitle(this.handle(language, title, title_extra, title_extra_two));
if (!"".equals(description))
@@ -122,11 +122,11 @@ public class MessageEditor {
}
public String getTerm(String string) {
- return this.handle(rethinkUser.getLanguage(), string, "", "");
+ return this.handle(mongoUser.getLanguage(), string, "", "");
}
public String getTerm(String string, String extra, String extra_two) {
- return this.handle(rethinkUser.getLanguage(), string, extra, extra_two);
+ return this.handle(mongoUser.getLanguage(), string, extra, extra_two);
}
private String handle(String language_code, String string, String extra, String extra_two) {
diff --git a/src/main/resources/META-INF/MANIFEST.MF b/src/main/resources/META-INF/MANIFEST.MF
index 222bc42..50b5d17 100644
--- a/src/main/resources/META-INF/MANIFEST.MF
+++ b/src/main/resources/META-INF/MANIFEST.MF
@@ -1,3 +1,3 @@
Manifest-Version: 1.0
-Main-Class: com.bbn.hadder.Hadder
+Main-Class: one.bbn.hadder.Hadder
diff --git a/src/main/resources/Translations/Translations_de.properties b/src/main/resources/Translations/Translations_de.properties
index 83feb11..31b825b 100644
--- a/src/main/resources/Translations/Translations_de.properties
+++ b/src/main/resources/Translations/Translations_de.properties
@@ -1,5 +1,5 @@
#
-# Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+# Copyright 2019-2021 GregTCLTK and Schlauer-Hax
#
# Licensed under the GNU Affero General Public License, Version 3.0;
# you may not use this file except in compliance with the License.
diff --git a/src/main/resources/Translations/Translations_en.properties b/src/main/resources/Translations/Translations_en.properties
index 3577e78..1b9ef17 100644
--- a/src/main/resources/Translations/Translations_en.properties
+++ b/src/main/resources/Translations/Translations_en.properties
@@ -1,5 +1,5 @@
#
-# Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+# Copyright 2019-2021 GregTCLTK and Schlauer-Hax
#
# Licensed under the GNU Affero General Public License, Version 3.0;
# you may not use this file except in compliance with the License.
diff --git a/src/main/resources/Translations/Translations_es.properties b/src/main/resources/Translations/Translations_es.properties
index 3577e78..1b9ef17 100644
--- a/src/main/resources/Translations/Translations_es.properties
+++ b/src/main/resources/Translations/Translations_es.properties
@@ -1,5 +1,5 @@
#
-# Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+# Copyright 2019-2021 GregTCLTK and Schlauer-Hax
#
# Licensed under the GNU Affero General Public License, Version 3.0;
# you may not use this file except in compliance with the License.
diff --git a/src/main/resources/Translations/Translations_fr.properties b/src/main/resources/Translations/Translations_fr.properties
index 3577e78..1b9ef17 100644
--- a/src/main/resources/Translations/Translations_fr.properties
+++ b/src/main/resources/Translations/Translations_fr.properties
@@ -1,5 +1,5 @@
#
-# Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+# Copyright 2019-2021 GregTCLTK and Schlauer-Hax
#
# Licensed under the GNU Affero General Public License, Version 3.0;
# you may not use this file except in compliance with the License.
diff --git a/src/main/resources/Translations/Translations_ru.properties b/src/main/resources/Translations/Translations_ru.properties
index 3577e78..1b9ef17 100644
--- a/src/main/resources/Translations/Translations_ru.properties
+++ b/src/main/resources/Translations/Translations_ru.properties
@@ -1,5 +1,5 @@
#
-# Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+# Copyright 2019-2021 GregTCLTK and Schlauer-Hax
#
# Licensed under the GNU Affero General Public License, Version 3.0;
# you may not use this file except in compliance with the License.
diff --git a/src/main/resources/Translations/Translations_tr.properties b/src/main/resources/Translations/Translations_tr.properties
index 3577e78..1b9ef17 100644
--- a/src/main/resources/Translations/Translations_tr.properties
+++ b/src/main/resources/Translations/Translations_tr.properties
@@ -1,5 +1,5 @@
#
-# Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+# Copyright 2019-2021 GregTCLTK and Schlauer-Hax
#
# Licensed under the GNU Affero General Public License, Version 3.0;
# you may not use this file except in compliance with the License.
diff --git a/src/main/resources/Translations/Translations_zh.properties b/src/main/resources/Translations/Translations_zh.properties
index 3577e78..1b9ef17 100644
--- a/src/main/resources/Translations/Translations_zh.properties
+++ b/src/main/resources/Translations/Translations_zh.properties
@@ -1,5 +1,5 @@
#
-# Copyright 2019-2020 GregTCLTK and Schlauer-Hax
+# Copyright 2019-2021 GregTCLTK and Schlauer-Hax
#
# Licensed under the GNU Affero General Public License, Version 3.0;
# you may not use this file except in compliance with the License.