Showing with 1,610 additions and 236 deletions.
  1. +4 −0 .github/FUNDING.yml
  2. +18 −11 README.md
  3. +70 −10 pom.xml
  4. +122 −34 src/main/java/github/scarsz/discordsrv/DiscordSRV.java
  5. +26 −0 src/main/java/github/scarsz/discordsrv/api/events/AccountUnlinkedEvent.java
  6. +2 −2 src/main/java/github/scarsz/discordsrv/api/events/DiscordEvent.java
  7. +9 −1 src/main/java/github/scarsz/discordsrv/commands/CommandBroadcast.java
  8. +2 −0 src/main/java/github/scarsz/discordsrv/commands/CommandReload.java
  9. +13 −8 src/main/java/github/scarsz/discordsrv/hooks/chat/FancyChatHook.java
  10. +11 −3 src/main/java/github/scarsz/discordsrv/hooks/chat/HerochatHook.java
  11. +11 −3 src/main/java/github/scarsz/discordsrv/hooks/chat/LegendChatHook.java
  12. +13 −4 src/main/java/github/scarsz/discordsrv/hooks/chat/LunaChatHook.java
  13. +20 −7 src/main/java/github/scarsz/discordsrv/hooks/chat/TownyChatHook.java
  14. +9 −4 src/main/java/github/scarsz/discordsrv/hooks/chat/UltimateChatHook.java
  15. +13 −8 src/main/java/github/scarsz/discordsrv/hooks/chat/VentureChatHook.java
  16. +2 −3 src/main/java/github/scarsz/discordsrv/hooks/vanish/PhantomAdminHook.java
  17. +3 −1 src/main/java/github/scarsz/discordsrv/hooks/world/MultiverseCoreHook.java
  18. +5 −1 src/main/java/github/scarsz/discordsrv/listeners/DiscordBanListener.java
  19. +4 −3 src/main/java/github/scarsz/discordsrv/listeners/DiscordChatListener.java
  20. +32 −18 src/main/java/github/scarsz/discordsrv/listeners/DiscordConsoleListener.java
  21. +3 −3 src/main/java/github/scarsz/discordsrv/listeners/PlayerAchievementsListener.java
  22. +2 −2 src/main/java/github/scarsz/discordsrv/listeners/PlayerAdvancementDoneListener.java
  23. +6 −11 src/main/java/github/scarsz/discordsrv/listeners/PlayerBanListener.java
  24. +3 −1 src/main/java/github/scarsz/discordsrv/listeners/PlayerChatListener.java
  25. +3 −3 src/main/java/github/scarsz/discordsrv/listeners/PlayerDeathListener.java
  26. +9 −9 src/main/java/github/scarsz/discordsrv/listeners/PlayerJoinLeaveListener.java
  27. +9 −6 src/main/java/github/scarsz/discordsrv/objects/log4j/ConsoleAppender.java
  28. +17 −18 src/main/java/github/scarsz/discordsrv/objects/log4j/JdaFilter.java
  29. +55 −42 src/main/java/github/scarsz/discordsrv/objects/managers/AccountLinkManager.java
  30. +378 −0 src/main/java/github/scarsz/discordsrv/objects/managers/JdbcAccountLinkManager.java
  31. +4 −4 src/main/java/github/scarsz/discordsrv/objects/managers/MetricsManager.java
  32. +1 −1 src/main/java/github/scarsz/discordsrv/objects/threads/ConsoleMessageQueueWorker.java
  33. +3 −2 src/main/java/github/scarsz/discordsrv/util/ConfigUtil.java
  34. +4 −3 src/main/java/github/scarsz/discordsrv/util/DiscordUtil.java
  35. +5 −0 src/main/java/github/scarsz/discordsrv/util/GroupSynchronizationUtil.java
  36. +84 −2 src/main/java/github/scarsz/discordsrv/util/LangUtil.java
  37. +1 −1 src/main/java/github/scarsz/discordsrv/util/PlayerUtil.java
  38. +58 −0 src/main/java/github/scarsz/discordsrv/util/SQLUtil.java
  39. +10 −5 src/main/java/github/scarsz/discordsrv/util/WebhookUtil.java
  40. +10 −0 src/main/resources/config/de.yml
  41. +10 −0 src/main/resources/config/en.yml
  42. +10 −0 src/main/resources/config/es.yml
  43. +10 −0 src/main/resources/config/et.yml
  44. +10 −0 src/main/resources/config/fr.yml
  45. +10 −0 src/main/resources/config/ja.yml
  46. +10 −0 src/main/resources/config/ko.yml
  47. +10 −0 src/main/resources/config/nl.yml
  48. +10 −0 src/main/resources/config/ru.yml
  49. +238 −0 src/main/resources/config/zh.yml
  50. +1 −0 src/main/resources/messages/de.yml
  51. +1 −0 src/main/resources/messages/en.yml
  52. +1 −0 src/main/resources/messages/es.yml
  53. +1 −0 src/main/resources/messages/et.yml
  54. +2 −1 src/main/resources/messages/fr.yml
  55. +1 −0 src/main/resources/messages/ja.yml
  56. +1 −0 src/main/resources/messages/ko.yml
  57. +1 −0 src/main/resources/messages/nl.yml
  58. +1 −0 src/main/resources/messages/ru.yml
  59. +227 −0 src/main/resources/messages/zh.yml
  60. +1 −1 src/main/resources/plugin.yml
4 changes: 4 additions & 0 deletions .github/FUNDING.yml
@@ -0,0 +1,4 @@
# These are supported funding model platforms

patreon: scarsz
custom: https://scarsz.me/donate/10
29 changes: 18 additions & 11 deletions README.md
Expand Up @@ -10,14 +10,21 @@
A Minecraft to Discord and back link plugin

## Thanks to:
<a href="https://www.jetbrains.com/idea/"><img src="https://scarsz.me/i/x2262.png" alt="Jetbrains IntelliJ IDEA" width="400px"></img></a>

<strong>The Java IDE for Professional Developers by JetBrains</strong>

<a href="https://pebblehost.com"><img src="https://pebblehost.com/src/img/logos/main.png" alt="PebbleHost" width="250px"></img></a>

<strong>Need a server host? Try PebbleHost! Plans starting at $1/GB. Use promo code `DISCORDSRV` at checkout for 15% off your first three bills!</strong>

<a href="http://www.ej-technologies.com/products/jprofiler/overview.html"><img src="https://www.ej-technologies.com/images/product_banners/jprofiler_large.png" alt="JProfiler" width="150px"></img></a>

<strong>JProfiler's intuitive UI helps you resolve performance bottlenecks, pin down memory leaks and understand threading issues.</strong>
<table>
<tr>
<td align="center" colspan="2">
<a href="https://pebblehost.com"><img src="https://pebblehost.com/src/img/logos/main.png" alt="PebbleHost" width="250px"></img></a>
<p><strong>Need a server host? Try PebbleHost! Plans starting at $1/GB.</p><p>Use promo code <code>DISCORDSRV</code> at checkout for 15% off your first three bills!</strong></p>
</td>
</tr>
<tr>
<td align="center" width="50%">
<a href="https://www.jetbrains.com/idea/"><img src="https://scarsz.me/i/x2262.png" alt="Jetbrains IntelliJ IDEA" width="400px"></img></a>
<p><strong>The Java IDE for Professional Developers by JetBrains</strong></p>
</td>
<td align="center" width="50%">
<a href="http://www.ej-technologies.com/products/jprofiler/overview.html"><img src="https://www.ej-technologies.com/images/product_banners/jprofiler_large.png" alt="JProfiler" width="150px"></img></a>
<p><strong>JProfiler's intuitive UI helps you resolve performance bottlenecks, pin down memory leaks and understand threading issues.</strong></p>
</td>
</tr>
</table>
80 changes: 70 additions & 10 deletions pom.xml
Expand Up @@ -3,8 +3,7 @@
<modelVersion>4.0.0</modelVersion>
<groupId>github.scarsz.discordsrv</groupId>
<artifactId>DiscordSRV</artifactId>
<version>1.16.9-MH</version>

<version>1.17.1-MH</version>
<name>DiscordSRV</name>
<url>https://www.spigotmc.org/resources/discordsrv.18494/</url>

Expand All @@ -18,12 +17,12 @@

<issueManagement>
<system>GitHub</system>
<url>https://github.com/Scarsz/DiscordSRV/issues</url>
<url>https://github.com/DiscordSRV/DiscordSRV/issues</url>
</issueManagement>

<scm>
<connection>scm:git:https://github.com/Scarsz/DiscordSRV.git</connection>
<url>https://github.com/Scarsz/DiscordSRV/</url>
<connection>scm:git:https://github.com/DiscordSRV/DiscordSRV.git</connection>
<url>https://github.com/DiscordSRV/DiscordSRV/</url>
</scm>

<properties>
Expand All @@ -49,7 +48,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.5.1</version>
<version>3.8.1</version>
<configuration>
<source>1.8</source>
<target>1.8</target>
Expand All @@ -59,7 +58,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-shade-plugin</artifactId>
<version>2.4.3</version>
<version>3.2.1</version>
<executions>
<execution>
<phase>package</phase>
Expand All @@ -79,6 +78,14 @@
<pattern>net.dv8tion.jda</pattern>
<shadedPattern>github.scarsz.discordsrv.dependencies.jda</shadedPattern>
</relocation>
<relocation>
<pattern>net.kyori</pattern>
<shadedPattern>github.scarsz.discordsrv.dependencies.net.kyori</shadedPattern>
</relocation>
<relocation>
<pattern>me.vankka</pattern>
<shadedPattern>github.scarsz.discordsrv.dependencies.me.vankka</shadedPattern>
</relocation>

<!-- relocated due to dependency hell -->
<relocation>
Expand All @@ -105,6 +112,10 @@
<pattern>okio</pattern>
<shadedPattern>github.scarsz.discordsrv.dependencies.okio</shadedPattern>
</relocation>
<relocation>
<pattern>gnu.trove</pattern>
<shadedPattern>github.scarsz.discordsrv.dependencies.trove</shadedPattern>
</relocation>
</relocations>

<minimizeJar>true</minimizeJar>
Expand All @@ -127,7 +138,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<version>3.0.2</version>
<version>3.1.1</version>
<configuration>
<archive>
<manifestEntries>
Expand Down Expand Up @@ -173,14 +184,18 @@
<id>scarsz</id>
<url>https://nexus.scarsz.me/content/groups/public/</url>
</repository>
<repository>
<id>jitpack.io</id>
<url>https://jitpack.io</url>
</repository>
</repositories>

<dependencies>
<!-- jda -->
<dependency>
<groupId>net.dv8tion</groupId>
<artifactId>JDA</artifactId>
<version>3.8.2_459</version>
<version>3.8.3_463</version>
<exclusions>
<exclusion>
<groupId>club.minnced</groupId>
Expand Down Expand Up @@ -269,10 +284,24 @@
<dependency>
<groupId>org.projectlombok</groupId>
<artifactId>lombok</artifactId>
<version>1.16.12</version>
<version>1.18.8</version>
<scope>provided</scope>
</dependency>

<!-- mysql driver -->
<dependency>
<groupId>mysql</groupId>
<artifactId>mysql-connector-java</artifactId>
<version>8.0.16</version>
</dependency>

<!-- dependency hell -->
<dependency>
<groupId>net.sf.trove4j</groupId>
<artifactId>trove4j</artifactId>
<version>3.0.3</version>
</dependency>

<!-- json.simple -->
<dependency>
<groupId>com.googlecode.json-simple</groupId>
Expand All @@ -294,6 +323,37 @@
<version>0.9.0</version>
</dependency>

<!-- Discord <-> Minecraft reserializer -->
<dependency>
<groupId>com.github.Vankka</groupId>
<artifactId>MCDiscordReserializer</artifactId>
<version>-b00bafd9c6-1</version>
</dependency>

<!-- Kyori Text -->
<dependency>
<groupId>net.kyori</groupId>
<artifactId>text-api</artifactId>
<version>3.0.0</version>
</dependency>
<dependency>
<groupId>net.kyori</groupId>
<artifactId>text-serializer-legacy</artifactId>
<version>3.0.0</version>
</dependency>
<dependency>
<groupId>net.kyori</groupId>
<artifactId>text-adapter-bukkit</artifactId>
<version>3.0.2</version>
</dependency>

<!-- guava -->
<dependency>
<groupId>com.google.guava</groupId>
<artifactId>guava</artifactId>
<version>27.1-jre</version>
</dependency>

<!-- herochat -->
<dependency>
<groupId>com.dthielke.herochat</groupId>
Expand Down