├── .gitignore ├── .settings └── org.eclipse.jdt.core.prefs ├── META-INF └── MANIFEST.MF ├── README.md ├── _config.yml ├── doc ├── allclasses-frame.html ├── allclasses-noframe.html ├── com │ └── tjplaysnow │ │ └── discord │ │ ├── config │ │ ├── Config.html │ │ ├── File.html │ │ ├── package-frame.html │ │ ├── package-summary.html │ │ └── package-tree.html │ │ ├── main │ │ ├── BungeeMain.html │ │ ├── Main.html │ │ ├── PluginMain.html │ │ ├── commands │ │ │ ├── HelpCommand.html │ │ │ ├── MuteCommand.html │ │ │ ├── UnmuteCommand.html │ │ │ ├── package-frame.html │ │ │ ├── package-summary.html │ │ │ └── package-tree.html │ │ ├── consolecommands │ │ │ ├── BroadcastConsoleCommand.html │ │ │ ├── HelpConsoleCommand.html │ │ │ ├── StopConsoleCommand.html │ │ │ ├── package-frame.html │ │ │ ├── package-summary.html │ │ │ └── package-tree.html │ │ ├── package-frame.html │ │ ├── package-summary.html │ │ └── package-tree.html │ │ └── object │ │ ├── Bot.html │ │ ├── Command.html │ │ ├── CommandBukkit.html │ │ ├── CommandConsoleManager.html │ │ ├── CommandSpigotManager.html │ │ ├── ConsoleCommand.html │ │ ├── ProgramBot.html │ │ ├── ProgramCommand.html │ │ ├── ProgramCommandConsole.html │ │ ├── ProgramConsoleCommandManager.html │ │ ├── ProgramThread.html │ │ ├── ThreadHandle.html │ │ ├── ThreadSpigot.html │ │ ├── logger │ │ ├── Colors.html │ │ ├── LogLevel.html │ │ ├── Logger.html │ │ ├── package-frame.html │ │ ├── package-summary.html │ │ └── package-tree.html │ │ ├── package-frame.html │ │ ├── package-summary.html │ │ └── package-tree.html ├── constant-values.html ├── deprecated-list.html ├── help-doc.html ├── index-files │ ├── index-1.html │ ├── index-10.html │ ├── index-11.html │ ├── index-12.html │ ├── index-13.html │ ├── index-14.html │ ├── index-15.html │ ├── index-16.html │ ├── index-17.html │ ├── index-18.html │ ├── index-19.html │ ├── index-2.html │ ├── index-20.html │ ├── index-3.html │ ├── index-4.html │ ├── index-5.html │ ├── index-6.html │ ├── index-7.html │ ├── index-8.html │ └── index-9.html ├── index.html ├── overview-frame.html ├── overview-summary.html ├── overview-tree.html ├── package-list ├── script.js └── stylesheet.css ├── javadoc.xml ├── lib ├── fastjson-1.2.14-sources.jar └── fastjson-1.2.14.jar ├── out ├── Discord Bot API V 5.0.jar ├── Discord Bot API V 5.1.jar ├── Discord Bot API V 5.2.jar └── Discord Bot API V 5.3.jar ├── pom.xml ├── src └── main │ ├── java │ └── com │ │ └── tjplaysnow │ │ └── discord │ │ ├── config │ │ ├── Config.java │ │ ├── File.java │ │ └── package-info.java │ │ ├── main │ │ ├── BungeeMain.java │ │ ├── Main.java │ │ ├── PluginMain.java │ │ ├── commands │ │ │ ├── HelpCommand.java │ │ │ ├── MuteCommand.java │ │ │ ├── UnmuteCommand.java │ │ │ └── package-info.java │ │ ├── consolecommands │ │ │ ├── BroadcastConsoleCommand.java │ │ │ ├── HelpConsoleCommand.java │ │ │ ├── SpongeMain.java │ │ │ ├── StopConsoleCommand.java │ │ │ └── package-info.java │ │ └── metrics │ │ │ ├── Bungee.java │ │ │ └── Spigot.java │ │ └── object │ │ ├── Bot.java │ │ ├── Command.java │ │ ├── CommandBukkit.java │ │ ├── CommandBungeeManager.java │ │ ├── CommandConsoleManager.java │ │ ├── CommandSpigotManager.java │ │ ├── CommandSpongerManager.java │ │ ├── ConsoleCommand.java │ │ ├── ProgramBot.java │ │ ├── ProgramCommand.java │ │ ├── ProgramCommandConsole.java │ │ ├── ProgramConsoleCommandManager.java │ │ ├── ProgramThread.java │ │ ├── ReactionAddEvent.java │ │ ├── SlashCommandEvents.java │ │ ├── ThreadBungee.java │ │ ├── ThreadHandle.java │ │ ├── ThreadSpigot.java │ │ ├── logger │ │ ├── Colors.java │ │ ├── LogLevel.java │ │ ├── Logger.java │ │ └── package-info.java │ │ └── package-info.java │ └── resources │ ├── bungee.yml │ ├── logback.xml │ ├── mcmod.info │ └── plugin.yml └── target ├── classes ├── bungee.yml ├── logback.xml ├── mcmod.info └── plugin.yml ├── maven-archiver └── pom.properties └── maven-status └── maven-compiler-plugin └── compile └── default-compile ├── createdFiles.lst └── inputFiles.lst /.gitignore: -------------------------------------------------------------------------------- 1 | bin/ 2 | .classpath 3 | .project 4 | *.iml 5 | .idea/ 6 | .settings/ -------------------------------------------------------------------------------- /.settings/org.eclipse.jdt.core.prefs: -------------------------------------------------------------------------------- 1 | eclipse.preferences.version=1 2 | org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled 3 | org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8 4 | org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve 5 | org.eclipse.jdt.core.compiler.compliance=1.8 6 | org.eclipse.jdt.core.compiler.debug.lineNumber=generate 7 | org.eclipse.jdt.core.compiler.debug.localVariable=generate 8 | org.eclipse.jdt.core.compiler.debug.sourceFile=generate 9 | org.eclipse.jdt.core.compiler.problem.assertIdentifier=error 10 | org.eclipse.jdt.core.compiler.problem.enumIdentifier=error 11 | org.eclipse.jdt.core.compiler.source=1.8 12 | -------------------------------------------------------------------------------- /META-INF/MANIFEST.MF: -------------------------------------------------------------------------------- 1 | Manifest-Version: 1.0 2 | Main-Class: com.tjplaysnow.discord.main.Main 3 | 4 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Discord-Bot-API - JDA 2 | My official API (Wrapper) of JDA for Discord Bots mainly used on Minecraft servers. 3 | 4 | * [Javadoc](https://tjplaysnow.github.io/Discord-Bot-API---JDA/doc/index.html) 5 | 6 | * Tutorial: 7 | * [Text tutorial v1](https://www.spigotmc.org/resources/discord-bot-api-jda.49783/) 8 | 9 | ## 🌈 How to install 10 | 11 | To install you can use maven, gradle or [build path](https://github.com/TJPlaysNow/Discord-Bot-API---JDA/raw/master/out/Discord%20Bot%20API%20V%205.0.jar) 12 | 13 | #### 🍕 Repository 14 | 15 | Add this repository in your list: 16 | 17 | 🎇Maven repository 18 | ```xml 19 | 20 | ... 21 | 22 | jitpack.io 23 | https://jitpack.io 24 | 25 | 26 | 27 | ``` 28 | 29 | 🎊 Gradle repository 30 | ```gradle 31 | repositories { 32 | ... 33 | maven { url 'https://jitpack.io' } 34 | } 35 | ``` 36 | 37 | #### 🍔 Project dependency 38 | 39 | Add the project dependency to your dependencies list: 40 | 41 | 🎇Maven dependency 42 | ```xml 43 | 44 | com.github.TJPlaysNow 45 | Discord-Bot-API---JDA 46 | bb783a3816 47 | 48 | ``` 49 | 50 | 🎊 Gradle dependency 51 | ```gradle 52 | dependencies { 53 | implementation 'com.github.TJPlaysNow:Discord-Bot-API---JDA:1.0-SNAPSHOT' 54 | } 55 | ``` 56 | -------------------------------------------------------------------------------- /_config.yml: -------------------------------------------------------------------------------- 1 | theme: jekyll-theme-slate -------------------------------------------------------------------------------- /doc/allclasses-frame.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | All Classes 7 | 8 | 9 | 10 | 11 | 12 |

All Classes

13 |
14 | 43 |
44 | 45 | 46 | -------------------------------------------------------------------------------- /doc/allclasses-noframe.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | All Classes 7 | 8 | 9 | 10 | 11 | 12 |

All Classes

13 |
14 | 43 |
44 | 45 | 46 | -------------------------------------------------------------------------------- /doc/com/tjplaysnow/discord/config/package-frame.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | com.tjplaysnow.discord.config 7 | 8 | 9 | 10 | 11 | 12 |

com.tjplaysnow.discord.config

13 |
14 |

Classes

15 | 19 |
20 | 21 | 22 | -------------------------------------------------------------------------------- /doc/com/tjplaysnow/discord/config/package-summary.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | com.tjplaysnow.discord.config 7 | 8 | 9 | 10 | 11 | 12 | 22 | 25 | 26 |
27 | 28 | 29 |
Skip navigation links
30 | 31 | 32 | 33 | 42 |
43 | 70 | 71 |
72 |

Package com.tjplaysnow.discord.config

73 |
74 |
75 | 100 |
101 | 102 |
103 | 104 | 105 |
Skip navigation links
106 | 107 | 108 | 109 | 118 |
119 | 146 | 147 | 148 | 149 | -------------------------------------------------------------------------------- /doc/com/tjplaysnow/discord/config/package-tree.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | com.tjplaysnow.discord.config Class Hierarchy 7 | 8 | 9 | 10 | 11 | 12 | 22 | 25 | 26 |
27 | 28 | 29 |
Skip navigation links
30 | 31 | 32 | 33 | 42 |
43 | 70 | 71 |
72 |

Hierarchy For Package com.tjplaysnow.discord.config

73 | Package Hierarchies: 74 | 77 |
78 |
79 |

Class Hierarchy

80 | 88 |
89 | 90 |
91 | 92 | 93 |
Skip navigation links
94 | 95 | 96 | 97 | 106 |
107 | 134 | 135 | 136 | 137 | -------------------------------------------------------------------------------- /doc/com/tjplaysnow/discord/main/commands/package-frame.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | com.tjplaysnow.discord.main.commands 7 | 8 | 9 | 10 | 11 | 12 |

com.tjplaysnow.discord.main.commands

13 |
14 |

Classes

15 | 20 |
21 | 22 | 23 | -------------------------------------------------------------------------------- /doc/com/tjplaysnow/discord/main/commands/package-summary.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | com.tjplaysnow.discord.main.commands 7 | 8 | 9 | 10 | 11 | 12 | 22 | 25 | 26 |
27 | 28 | 29 |
Skip navigation links
30 | 31 | 32 | 33 | 42 |
43 | 70 | 71 |
72 |

Package com.tjplaysnow.discord.main.commands

73 |
74 |
75 | 100 |
101 | 102 |
103 | 104 | 105 |
Skip navigation links
106 | 107 | 108 | 109 | 118 |
119 | 146 | 147 | 148 | 149 | -------------------------------------------------------------------------------- /doc/com/tjplaysnow/discord/main/commands/package-tree.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | com.tjplaysnow.discord.main.commands Class Hierarchy 7 | 8 | 9 | 10 | 11 | 12 | 22 | 25 | 26 |
27 | 28 | 29 |
Skip navigation links
30 | 31 | 32 | 33 | 42 |
43 | 70 | 71 |
72 |

Hierarchy For Package com.tjplaysnow.discord.main.commands

73 | Package Hierarchies: 74 | 77 |
78 |
79 |

Class Hierarchy

80 | 93 |
94 | 95 |
96 | 97 | 98 |
Skip navigation links
99 | 100 | 101 | 102 | 111 |
112 | 139 | 140 | 141 | 142 | -------------------------------------------------------------------------------- /doc/com/tjplaysnow/discord/main/consolecommands/package-frame.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | com.tjplaysnow.discord.main.consolecommands 7 | 8 | 9 | 10 | 11 | 12 |

com.tjplaysnow.discord.main.consolecommands

13 |
14 |

Classes

15 | 20 |
21 | 22 | 23 | -------------------------------------------------------------------------------- /doc/com/tjplaysnow/discord/main/consolecommands/package-summary.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | com.tjplaysnow.discord.main.consolecommands 7 | 8 | 9 | 10 | 11 | 12 | 22 | 25 | 26 |
27 | 28 | 29 |
Skip navigation links
30 | 31 | 32 | 33 | 42 |
43 | 70 | 71 |
72 |

Package com.tjplaysnow.discord.main.consolecommands

73 |
74 |
75 | 100 |
101 | 102 |
103 | 104 | 105 |
Skip navigation links
106 | 107 | 108 | 109 | 118 |
119 | 146 | 147 | 148 | 149 | -------------------------------------------------------------------------------- /doc/com/tjplaysnow/discord/main/consolecommands/package-tree.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | com.tjplaysnow.discord.main.consolecommands Class Hierarchy 7 | 8 | 9 | 10 | 11 | 12 | 22 | 25 | 26 |
27 | 28 | 29 |
Skip navigation links
30 | 31 | 32 | 33 | 42 |
43 | 70 | 71 |
72 |

Hierarchy For Package com.tjplaysnow.discord.main.consolecommands

73 | Package Hierarchies: 74 | 77 |
78 |
79 |

Class Hierarchy

80 | 93 |
94 | 95 |
96 | 97 | 98 |
Skip navigation links
99 | 100 | 101 | 102 | 111 |
112 | 139 | 140 | 141 | 142 | -------------------------------------------------------------------------------- /doc/com/tjplaysnow/discord/main/package-frame.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | com.tjplaysnow.discord.main 7 | 8 | 9 | 10 | 11 | 12 |

com.tjplaysnow.discord.main

13 |
14 |

Classes

15 | 20 |
21 | 22 | 23 | -------------------------------------------------------------------------------- /doc/com/tjplaysnow/discord/main/package-summary.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | com.tjplaysnow.discord.main 7 | 8 | 9 | 10 | 11 | 12 | 22 | 25 | 26 |
27 | 28 | 29 |
Skip navigation links
30 | 31 | 32 | 33 | 42 |
43 | 70 | 71 |
72 |

Package com.tjplaysnow.discord.main

73 |
74 |
75 | 100 |
101 | 102 |
103 | 104 | 105 |
Skip navigation links
106 | 107 | 108 | 109 | 118 |
119 | 146 | 147 | 148 | 149 | -------------------------------------------------------------------------------- /doc/com/tjplaysnow/discord/main/package-tree.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | com.tjplaysnow.discord.main Class Hierarchy 7 | 8 | 9 | 10 | 11 | 12 | 22 | 25 | 26 |
27 | 28 | 29 |
Skip navigation links
30 | 31 | 32 | 33 | 42 |
43 | 70 | 71 |
72 |

Hierarchy For Package com.tjplaysnow.discord.main

73 | Package Hierarchies: 74 | 77 |
78 |
79 |

Class Hierarchy

80 | 101 |
102 | 103 |
104 | 105 | 106 |
Skip navigation links
107 | 108 | 109 | 110 | 119 |
120 | 147 | 148 | 149 | 150 | -------------------------------------------------------------------------------- /doc/com/tjplaysnow/discord/object/logger/package-frame.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | com.tjplaysnow.discord.object.logger 7 | 8 | 9 | 10 | 11 | 12 |

com.tjplaysnow.discord.object.logger

13 |
14 |

Classes

15 | 19 |

Enums

20 | 23 |
24 | 25 | 26 | -------------------------------------------------------------------------------- /doc/com/tjplaysnow/discord/object/logger/package-summary.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | com.tjplaysnow.discord.object.logger 7 | 8 | 9 | 10 | 11 | 12 | 22 | 25 | 26 |
27 | 28 | 29 |
Skip navigation links
30 | 31 | 32 | 33 | 42 |
43 | 70 | 71 |
72 |

Package com.tjplaysnow.discord.object.logger

73 |
74 |
75 | 117 |
118 | 119 |
120 | 121 | 122 |
Skip navigation links
123 | 124 | 125 | 126 | 135 |
136 | 163 | 164 | 165 | 166 | -------------------------------------------------------------------------------- /doc/com/tjplaysnow/discord/object/logger/package-tree.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | com.tjplaysnow.discord.object.logger Class Hierarchy 7 | 8 | 9 | 10 | 11 | 12 | 22 | 25 | 26 |
27 | 28 | 29 |
Skip navigation links
30 | 31 | 32 | 33 | 42 |
43 | 70 | 71 |
72 |

Hierarchy For Package com.tjplaysnow.discord.object.logger

73 | Package Hierarchies: 74 | 77 |
78 |
79 |

Class Hierarchy

80 | 88 |

Enum Hierarchy

89 | 100 |
101 | 102 |
103 | 104 | 105 |
Skip navigation links
106 | 107 | 108 | 109 | 118 |
119 | 146 | 147 | 148 | 149 | -------------------------------------------------------------------------------- /doc/com/tjplaysnow/discord/object/package-frame.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | com.tjplaysnow.discord.object 7 | 8 | 9 | 10 | 11 | 12 |

com.tjplaysnow.discord.object

13 |
14 |

Interfaces

15 | 19 |

Classes

20 | 33 |
34 | 35 | 36 | -------------------------------------------------------------------------------- /doc/deprecated-list.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | Deprecated List 7 | 8 | 9 | 10 | 11 | 12 | 22 | 25 | 26 |
27 | 28 | 29 |
Skip navigation links
30 | 31 | 32 | 33 | 42 |
43 | 70 | 71 |
72 |

Deprecated API

73 |

Contents

74 | 77 |
78 |
79 | 80 | 81 | 99 |
100 | 101 |
102 | 103 | 104 |
Skip navigation links
105 | 106 | 107 | 108 | 117 |
118 | 145 | 146 | 147 | 148 | -------------------------------------------------------------------------------- /doc/index-files/index-11.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | M-Index 7 | 8 | 9 | 10 | 11 | 12 | 22 | 25 | 26 |
27 | 28 | 29 |
Skip navigation links
30 | 31 | 32 | 33 | 42 |
43 | 70 | 71 |
A B C D E F G H I L M O P R S T U V W Y  72 | 73 | 74 |

M

75 |
76 |
Main - Class in com.tjplaysnow.discord.main
77 |
 
78 |
Main() - Constructor for class com.tjplaysnow.discord.main.Main
79 |
 
80 |
main(String[]) - Static method in class com.tjplaysnow.discord.main.Main
81 |
 
82 |
MuteCommand - Class in com.tjplaysnow.discord.main.commands
83 |
 
84 |
MuteCommand(Bot) - Constructor for class com.tjplaysnow.discord.main.commands.MuteCommand
85 |
 
86 |
87 | A B C D E F G H I L M O P R S T U V W Y 
88 | 89 |
90 | 91 | 92 |
Skip navigation links
93 | 94 | 95 | 96 | 105 |
106 | 133 | 134 | 135 | 136 | -------------------------------------------------------------------------------- /doc/index-files/index-12.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | O-Index 7 | 8 | 9 | 10 | 11 | 12 | 22 | 25 | 26 |
27 | 28 | 29 |
Skip navigation links
30 | 31 | 32 | 33 | 42 |
43 | 70 | 71 |
A B C D E F G H I L M O P R S T U V W Y  72 | 73 | 74 |

O

75 |
76 |
onEnable() - Method in class com.tjplaysnow.discord.main.BungeeMain
77 |
 
78 |
onEnable() - Method in class com.tjplaysnow.discord.main.PluginMain
79 |
 
80 |
onEvent(Event) - Method in class com.tjplaysnow.discord.object.Bot
81 |
 
82 |
83 | A B C D E F G H I L M O P R S T U V W Y 
84 | 85 |
86 | 87 | 88 |
Skip navigation links
89 | 90 | 91 | 92 | 101 |
102 | 129 | 130 | 131 | 132 | -------------------------------------------------------------------------------- /doc/index-files/index-16.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | T-Index 7 | 8 | 9 | 10 | 11 | 12 | 22 | 25 | 26 |
27 | 28 | 29 |
Skip navigation links
30 | 31 | 32 | 33 | 42 |
43 | 70 | 71 |
A B C D E F G H I L M O P R S T U V W Y  72 | 73 | 74 |

T

75 |
76 |
ThreadHandle - Class in com.tjplaysnow.discord.object
77 |
 
78 |
ThreadHandle() - Constructor for class com.tjplaysnow.discord.object.ThreadHandle
79 |
 
80 |
ThreadSpigot - Class in com.tjplaysnow.discord.object
81 |
 
82 |
ThreadSpigot(Plugin) - Constructor for class com.tjplaysnow.discord.object.ThreadSpigot
83 |
 
84 |
85 | A B C D E F G H I L M O P R S T U V W Y 
86 | 87 |
88 | 89 | 90 |
Skip navigation links
91 | 92 | 93 | 94 | 103 |
104 | 131 | 132 | 133 | 134 | -------------------------------------------------------------------------------- /doc/index-files/index-17.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | U-Index 7 | 8 | 9 | 10 | 11 | 12 | 22 | 25 | 26 |
27 | 28 | 29 |
Skip navigation links
30 | 31 | 32 | 33 | 42 |
43 | 70 | 71 |
A B C D E F G H I L M O P R S T U V W Y  72 | 73 | 74 |

U

75 |
76 |
UnmuteCommand - Class in com.tjplaysnow.discord.main.commands
77 |
 
78 |
UnmuteCommand(Bot) - Constructor for class com.tjplaysnow.discord.main.commands.UnmuteCommand
79 |
 
80 |
81 | A B C D E F G H I L M O P R S T U V W Y 
82 | 83 |
84 | 85 | 86 |
Skip navigation links
87 | 88 | 89 | 90 | 99 |
100 | 127 | 128 | 129 | 130 | -------------------------------------------------------------------------------- /doc/index-files/index-18.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | V-Index 7 | 8 | 9 | 10 | 11 | 12 | 22 | 25 | 26 |
27 | 28 | 29 |
Skip navigation links
30 | 31 | 32 | 33 | 42 |
43 | 70 | 71 |
A B C D E F G H I L M O P R S T U V W Y  72 | 73 | 74 |

V

75 |
76 |
valueOf(String) - Static method in enum com.tjplaysnow.discord.object.logger.LogLevel
77 |
78 |
Returns the enum constant of this type with the specified name.
79 |
80 |
values() - Static method in enum com.tjplaysnow.discord.object.logger.LogLevel
81 |
82 |
Returns an array containing the constants of this enum type, in 83 | the order they are declared.
84 |
85 |
86 | A B C D E F G H I L M O P R S T U V W Y 
87 | 88 |
89 | 90 | 91 |
Skip navigation links
92 | 93 | 94 | 95 | 104 |
105 | 132 | 133 | 134 | 135 | -------------------------------------------------------------------------------- /doc/index-files/index-4.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | D-Index 7 | 8 | 9 | 10 | 11 | 12 | 22 | 25 | 26 |
27 | 28 | 29 |
Skip navigation links
30 | 31 | 32 | 33 | 42 |
43 | 70 | 71 |
A B C D E F G H I L M O P R S T U V W Y  72 | 73 | 74 |

D

75 |
76 |
delete() - Method in interface com.tjplaysnow.discord.object.Command
77 |
78 |
Use to delete messages after a period of time.
79 | Default time is 5 seconds, use getDeleteTime() 80 | to specify how long it should wait.
81 |
82 |
delete() - Method in class com.tjplaysnow.discord.object.ProgramCommand
83 |
84 |
Use to delete messages after a period of time.
85 | Default time is 5 seconds, use getDeleteTime() 86 | to specify how long it should wait.
87 |
88 |
89 | A B C D E F G H I L M O P R S T U V W Y 
90 | 91 |
92 | 93 | 94 |
Skip navigation links
95 | 96 | 97 | 98 | 107 |
108 | 135 | 136 | 137 | 138 | -------------------------------------------------------------------------------- /doc/index-files/index-5.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | E-Index 7 | 8 | 9 | 10 | 11 | 12 | 22 | 25 | 26 |
27 | 28 | 29 |
Skip navigation links
30 | 31 | 32 | 33 | 42 |
43 | 70 | 71 |
A B C D E F G H I L M O P R S T U V W Y  72 | 73 | 74 |

E

75 |
76 |
error(String) - Method in class com.tjplaysnow.discord.object.logger.Logger
77 |
78 |
Error messages
79 |
80 |
execute(CommandSender, String, String[]) - Method in class com.tjplaysnow.discord.object.CommandBukkit
81 |
 
82 |
83 | A B C D E F G H I L M O P R S T U V W Y 
84 | 85 |
86 | 87 | 88 |
Skip navigation links
89 | 90 | 91 | 92 | 101 |
102 | 129 | 130 | 131 | 132 | -------------------------------------------------------------------------------- /doc/index-files/index-6.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | F-Index 7 | 8 | 9 | 10 | 11 | 12 | 22 | 25 | 26 |
27 | 28 | 29 |
Skip navigation links
30 | 31 | 32 | 33 | 42 |
43 | 70 | 71 |
A B C D E F G H I L M O P R S T U V W Y  72 | 73 | 74 |

F

75 |
76 |
File - Class in com.tjplaysnow.discord.config
77 |
78 |
Created for use with the Config not from Spigot.
79 |
80 |
File(String) - Constructor for class com.tjplaysnow.discord.config.File
81 |
82 |
Create / load a new File for a Config to read.
83 |
84 |
85 | A B C D E F G H I L M O P R S T U V W Y 
86 | 87 |
88 | 89 | 90 |
Skip navigation links
91 | 92 | 93 | 94 | 103 |
104 | 131 | 132 | 133 | 134 | -------------------------------------------------------------------------------- /doc/index-files/index-8.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | H-Index 7 | 8 | 9 | 10 | 11 | 12 | 22 | 25 | 26 |
27 | 28 | 29 |
Skip navigation links
30 | 31 | 32 | 33 | 42 |
43 | 70 | 71 |
A B C D E F G H I L M O P R S T U V W Y  72 | 73 | 74 |

H

75 |
76 |
HelpCommand - Class in com.tjplaysnow.discord.main.commands
77 |
 
78 |
HelpCommand(Bot) - Constructor for class com.tjplaysnow.discord.main.commands.HelpCommand
79 |
 
80 |
HelpConsoleCommand - Class in com.tjplaysnow.discord.main.consolecommands
81 |
 
82 |
HelpConsoleCommand(Bot) - Constructor for class com.tjplaysnow.discord.main.consolecommands.HelpConsoleCommand
83 |
 
84 |
85 | A B C D E F G H I L M O P R S T U V W Y 
86 | 87 |
88 | 89 | 90 |
Skip navigation links
91 | 92 | 93 | 94 | 103 |
104 | 131 | 132 | 133 | 134 | -------------------------------------------------------------------------------- /doc/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | Generated Documentation (Untitled) 7 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | <noscript> 69 | <div>JavaScript is disabled on your browser.</div> 70 | </noscript> 71 | <h2>Frame Alert</h2> 72 | <p>This document is designed to be viewed using the frames feature. If you see this message, you are using a non-frame-capable web client. Link to <a href="overview-summary.html">Non-frame version</a>.</p> 73 | 74 | 75 | 76 | -------------------------------------------------------------------------------- /doc/overview-frame.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | Overview List 7 | 8 | 9 | 10 | 11 | 12 |
All Classes
13 |
14 |

Packages

15 | 23 |
24 |

 

25 | 26 | 27 | -------------------------------------------------------------------------------- /doc/overview-summary.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | Overview 7 | 8 | 9 | 10 | 11 | 12 | 22 | 25 | 26 |
27 | 28 | 29 |
Skip navigation links
30 | 31 | 32 | 33 | 42 |
43 | 70 | 71 |
72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 |
Packages 
PackageDescription
com.tjplaysnow.discord.config 
com.tjplaysnow.discord.main 
com.tjplaysnow.discord.main.commands 
com.tjplaysnow.discord.main.consolecommands 
com.tjplaysnow.discord.object 
com.tjplaysnow.discord.object.logger 
105 |
106 | 107 |
108 | 109 | 110 |
Skip navigation links
111 | 112 | 113 | 114 | 123 |
124 | 151 | 152 | 153 | 154 | -------------------------------------------------------------------------------- /doc/package-list: -------------------------------------------------------------------------------- 1 | com.tjplaysnow.discord.config 2 | com.tjplaysnow.discord.main 3 | com.tjplaysnow.discord.main.commands 4 | com.tjplaysnow.discord.main.consolecommands 5 | com.tjplaysnow.discord.object 6 | com.tjplaysnow.discord.object.logger 7 | -------------------------------------------------------------------------------- /doc/script.js: -------------------------------------------------------------------------------- 1 | function show(type) 2 | { 3 | count = 0; 4 | for (var key in methods) { 5 | var row = document.getElementById(key); 6 | if ((methods[key] & type) != 0) { 7 | row.style.display = ''; 8 | row.className = (count++ % 2) ? rowColor : altColor; 9 | } 10 | else 11 | row.style.display = 'none'; 12 | } 13 | updateTabs(type); 14 | } 15 | 16 | function updateTabs(type) 17 | { 18 | for (var value in tabs) { 19 | var sNode = document.getElementById(tabs[value][0]); 20 | var spanNode = sNode.firstChild; 21 | if (value == type) { 22 | sNode.className = activeTableTab; 23 | spanNode.innerHTML = tabs[value][1]; 24 | } 25 | else { 26 | sNode.className = tableTab; 27 | spanNode.innerHTML = "" + tabs[value][1] + ""; 28 | } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /javadoc.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /lib/fastjson-1.2.14-sources.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TJPlaysNow/Discord-Bot-API---JDA/11b176d1e8a0b06aabe5827524395886df9dd28e/lib/fastjson-1.2.14-sources.jar -------------------------------------------------------------------------------- /lib/fastjson-1.2.14.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TJPlaysNow/Discord-Bot-API---JDA/11b176d1e8a0b06aabe5827524395886df9dd28e/lib/fastjson-1.2.14.jar -------------------------------------------------------------------------------- /out/Discord Bot API V 5.0.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TJPlaysNow/Discord-Bot-API---JDA/11b176d1e8a0b06aabe5827524395886df9dd28e/out/Discord Bot API V 5.0.jar -------------------------------------------------------------------------------- /out/Discord Bot API V 5.1.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TJPlaysNow/Discord-Bot-API---JDA/11b176d1e8a0b06aabe5827524395886df9dd28e/out/Discord Bot API V 5.1.jar -------------------------------------------------------------------------------- /out/Discord Bot API V 5.2.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TJPlaysNow/Discord-Bot-API---JDA/11b176d1e8a0b06aabe5827524395886df9dd28e/out/Discord Bot API V 5.2.jar -------------------------------------------------------------------------------- /out/Discord Bot API V 5.3.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/TJPlaysNow/Discord-Bot-API---JDA/11b176d1e8a0b06aabe5827524395886df9dd28e/out/Discord Bot API V 5.3.jar -------------------------------------------------------------------------------- /pom.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 4.0.0 6 | 7 | com.tjplaysnow 8 | DiscordBotAPI 9 | 4.0 10 | 11 | 12 | 13 | org.apache.maven.plugins 14 | maven-compiler-plugin 15 | 16 | 8 17 | 8 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | spigot-repo 26 | https://hub.spigotmc.org/nexus/content/repositories/snapshots/ 27 | 28 | 29 | 30 | bungeecord-repo 31 | https://oss.sonatype.org/content/repositories/snapshots 32 | 33 | 34 | 35 | sponge-repo 36 | Sponge Maven Repository 37 | https://repo.spongepowered.org/maven 38 | 39 | 40 | 41 | dv8tion 42 | m2-dv8tion 43 | https://m2.dv8tion.net/releases 44 | 45 | 46 | 47 | 48 | 49 | org.spigotmc 50 | spigot-api 51 | 1.16.5-R0.1-SNAPSHOT 52 | provided 53 | 54 | 55 | 56 | net.md-5 57 | bungeecord-api 58 | 1.16-R0.5-SNAPSHOT 59 | jar 60 | provided 61 | 62 | 63 | net.md-5 64 | bungeecord-api 65 | 1.16-R0.5-SNAPSHOT 66 | javadoc 67 | provided 68 | 69 | 70 | 71 | org.spongepowered 72 | spongeapi 73 | 7.2.0 74 | jar 75 | provided 76 | 77 | 78 | 79 | net.dv8tion 80 | JDA 81 | LATEST 82 | 83 | 84 | -------------------------------------------------------------------------------- /src/main/java/com/tjplaysnow/discord/config/Config.java: -------------------------------------------------------------------------------- 1 | package com.tjplaysnow.discord.config; 2 | 3 | import java.util.List; 4 | import java.util.Map; 5 | 6 | /** 7 | * Created for use when not using Spigot's version of a config. 8 | * @version 1.0 9 | * @author TJPlaysNow 10 | */ 11 | public class Config { 12 | 13 | private String seperator = " =- "; 14 | 15 | private File conf; 16 | 17 | private Map config; 18 | 19 | /** 20 | * Create a new config. 21 | * 22 | * @param file to format. 23 | */ 24 | public Config(File file) { 25 | this.conf = file; 26 | } 27 | 28 | /** 29 | * Set an object to a path. 30 | * @param path Place to put the object. 31 | * @param object Object to place. 32 | */ 33 | public void set(String path, String object) { 34 | List lines = conf.readSmallTextFile(); 35 | int lineNum = lines.size(); 36 | boolean set = false; 37 | for (String b : lines) { 38 | if (b.contains(path + seperator)) { 39 | set = true; 40 | lineNum = lines.indexOf(b); 41 | } 42 | } 43 | if (set) { 44 | lines.set(lineNum, path + seperator + object); 45 | } else { 46 | lines.add(path + seperator + object); 47 | } 48 | conf.writeSmallTextFile(lines); 49 | } 50 | 51 | /** 52 | * Set an object to a path, if nothing else is there. 53 | * @param path Place to put the object. 54 | * @param def Object to place. 55 | */ 56 | public void setDefault(String path, String def) { 57 | List a = conf.readSmallTextFile(); 58 | String ret = "nil"; 59 | for (String b : a) { 60 | if (b.contains(path + seperator)) { 61 | ret = b.replace(path + seperator, ""); 62 | } 63 | } 64 | if (ret.equals("nil")) { 65 | set(path, def); 66 | } 67 | } 68 | 69 | /** 70 | * Get an object from a path. 71 | * @param path Place to get the object from. 72 | * @return The object in String form. 73 | */ 74 | public String getObject(String path) { 75 | List a = conf.readSmallTextFile(); 76 | String ret = ""; 77 | for (String b : a) { 78 | if (b.contains(path + seperator)) { 79 | ret = b.replace(path + seperator, ""); 80 | } 81 | } 82 | return ret; 83 | } 84 | 85 | /** 86 | * Get an object from a path. 87 | * @param path Place to get the object from. 88 | * @param def The object if it is null (Sets this in the config) 89 | * @return The object in String form. 90 | */ 91 | public String getObject(String path, String def) { 92 | List a = conf.readSmallTextFile(); 93 | String ret = "nil"; 94 | for (String b : a) { 95 | if (b.contains(path + seperator)) { 96 | ret = b.replace(path + seperator, ""); 97 | } 98 | } 99 | if (ret.equals("nil")) { 100 | set(path, def); 101 | ret = def; 102 | } 103 | return ret; 104 | } 105 | 106 | public java.io.File getFile() { 107 | return conf.getFile(); 108 | } 109 | } -------------------------------------------------------------------------------- /src/main/java/com/tjplaysnow/discord/config/File.java: -------------------------------------------------------------------------------- 1 | package com.tjplaysnow.discord.config; 2 | 3 | import java.io.IOException; 4 | import java.net.URISyntaxException; 5 | import java.nio.charset.Charset; 6 | import java.nio.charset.StandardCharsets; 7 | import java.nio.file.FileAlreadyExistsException; 8 | import java.nio.file.Files; 9 | import java.nio.file.Path; 10 | import java.nio.file.Paths; 11 | import java.util.List; 12 | 13 | /** 14 | * Created for use with the Config not from Spigot. 15 | * @version 1.0 16 | * @author TJPlaysNow 17 | */ 18 | public class File { 19 | 20 | private Path file; 21 | 22 | /** 23 | * Create / load a new File for a Config to read. 24 | * @param path Path to file 25 | */ 26 | public File(String path) { 27 | String loc; 28 | try { 29 | String[] p = this.getClass().getProtectionDomain().getCodeSource().getLocation().toURI().getPath().split("/"); 30 | loc = this.getClass().getProtectionDomain().getCodeSource().getLocation().toURI().getPath() + path; 31 | loc = loc.replace(p[p.length - 1], "").replace("\\", "/").replace("file:", ""); 32 | loc = loc.replace("/C:", "C:"); 33 | loc = loc.replace("/D:", "D:"); 34 | loc = loc.replace("/G:", "G:"); 35 | loc = loc.replace("/F:", "F:"); 36 | loc = loc.replace("/E:", "E:"); 37 | loc = loc.replace("/./", "/"); 38 | System.out.println(loc); 39 | file = Paths.get(loc); 40 | Files.createFile(file); 41 | } catch (FileAlreadyExistsException ignored) { 42 | } catch (IOException | URISyntaxException e) { 43 | e.printStackTrace(); 44 | } 45 | } 46 | 47 | private final static Charset ENCODING = StandardCharsets.UTF_8; 48 | 49 | /** 50 | * Reads the file. 51 | * @return File in lines 52 | */ 53 | public List readSmallTextFile() { 54 | try { 55 | return Files.readAllLines(file, ENCODING); 56 | } catch (Exception e) { 57 | e.printStackTrace(); 58 | return null; 59 | } 60 | } 61 | 62 | /** 63 | * Writes to the file. 64 | * @param lines to write to file. 65 | */ 66 | public void writeSmallTextFile(List lines) { 67 | try { 68 | Files.write(file, lines, ENCODING); 69 | } catch (Exception e) { 70 | e.printStackTrace(); 71 | } 72 | } 73 | 74 | public java.io.File getFile() { 75 | return file.toFile(); 76 | } 77 | } -------------------------------------------------------------------------------- /src/main/java/com/tjplaysnow/discord/config/package-info.java: -------------------------------------------------------------------------------- 1 | package com.tjplaysnow.discord.config; -------------------------------------------------------------------------------- /src/main/java/com/tjplaysnow/discord/main/BungeeMain.java: -------------------------------------------------------------------------------- 1 | package com.tjplaysnow.discord.main; 2 | 3 | import com.tjplaysnow.discord.main.metrics.Bungee; 4 | import net.md_5.bungee.api.plugin.Plugin; 5 | 6 | public class BungeeMain extends Plugin { 7 | @Override 8 | public void onEnable() { 9 | Bungee metrics = new Bungee(this, 15872); 10 | } 11 | } -------------------------------------------------------------------------------- /src/main/java/com/tjplaysnow/discord/main/Main.java: -------------------------------------------------------------------------------- 1 | package com.tjplaysnow.discord.main; 2 | 3 | public class Main { 4 | public static void main(String[] args) { 5 | // TODO: Nothing. 6 | } 7 | } -------------------------------------------------------------------------------- /src/main/java/com/tjplaysnow/discord/main/PluginMain.java: -------------------------------------------------------------------------------- 1 | package com.tjplaysnow.discord.main; 2 | 3 | import com.tjplaysnow.discord.main.metrics.Spigot; 4 | import org.bukkit.plugin.java.JavaPlugin; 5 | 6 | public class PluginMain extends JavaPlugin { 7 | @Override 8 | public void onEnable() { 9 | Spigot metrics = new Spigot(this, 15871); 10 | } 11 | } -------------------------------------------------------------------------------- /src/main/java/com/tjplaysnow/discord/main/commands/HelpCommand.java: -------------------------------------------------------------------------------- 1 | package com.tjplaysnow.discord.main.commands; 2 | 3 | import com.tjplaysnow.discord.object.Bot; 4 | import com.tjplaysnow.discord.object.ProgramCommand; 5 | import net.dv8tion.jda.api.entities.ChannelType; 6 | import net.dv8tion.jda.api.events.interaction.command.SlashCommandInteractionEvent; 7 | import net.dv8tion.jda.api.interactions.commands.build.OptionData; 8 | import net.dv8tion.jda.internal.utils.PermissionUtil; 9 | import org.jetbrains.annotations.NotNull; 10 | 11 | import java.util.List; 12 | 13 | public class HelpCommand extends ProgramCommand { 14 | 15 | private final Bot bot; 16 | 17 | public HelpCommand(Bot bot) { 18 | this.bot = bot; 19 | } 20 | 21 | @Override 22 | public String getLabel() { 23 | return "help"; 24 | } 25 | 26 | @Override 27 | public List getOptionData() { 28 | return null; 29 | } 30 | 31 | @Override 32 | public String getDescription() { 33 | return "The command that tells all."; 34 | } 35 | 36 | @Override 37 | public boolean run(@NotNull SlashCommandInteractionEvent event) { 38 | StringBuilder helpMessage = new StringBuilder("**__Commands:__**\n"); 39 | for (ProgramCommand command : bot.getCommands()) { 40 | if (!event.getChannel().getType().equals(ChannelType.PRIVATE)) { 41 | if (event.getMember() != null) { 42 | if (PermissionUtil.checkPermission(event.getMember(), command.getPermissionNeeded())) { 43 | helpMessage.append("> ").append(command.getLabel()).append("\n - ").append(command.getDescription()).append("\n"); 44 | } 45 | } else { 46 | helpMessage = new StringBuilder("Sorry, but your member object is null. (Because you are OP possibly)"); 47 | } 48 | } else { 49 | helpMessage = new StringBuilder("Sorry, but you need to run this command on the server."); 50 | } 51 | } 52 | event.getHook().sendMessage(helpMessage.toString()).queue(); 53 | return false; 54 | } 55 | } -------------------------------------------------------------------------------- /src/main/java/com/tjplaysnow/discord/main/commands/MuteCommand.java: -------------------------------------------------------------------------------- 1 | package com.tjplaysnow.discord.main.commands; 2 | 3 | import com.tjplaysnow.discord.object.Bot; 4 | import com.tjplaysnow.discord.object.ProgramCommand; 5 | import net.dv8tion.jda.api.Permission; 6 | import net.dv8tion.jda.api.entities.Member; 7 | import net.dv8tion.jda.api.events.interaction.command.SlashCommandInteractionEvent; 8 | import net.dv8tion.jda.api.interactions.commands.OptionType; 9 | import net.dv8tion.jda.api.interactions.commands.build.OptionData; 10 | 11 | import java.util.Collections; 12 | import java.util.List; 13 | 14 | public class MuteCommand extends ProgramCommand { 15 | 16 | private final Bot bot; 17 | 18 | public MuteCommand(Bot bot) { 19 | this.bot = bot; 20 | } 21 | 22 | @Override 23 | public String getLabel() { 24 | return "Mute"; 25 | } 26 | 27 | @Override 28 | public String getDescription() { 29 | return "Mute a user. `!Mute [User]`"; 30 | } 31 | 32 | @Override 33 | public Permission getPermissionNeeded() { 34 | return Permission.MESSAGE_MANAGE; 35 | } 36 | 37 | @Override 38 | public List getOptionData() { 39 | return Collections.singletonList(new OptionData(OptionType.STRING, "user", "The user to mute.", true).addChoice("", 1)); 40 | } 41 | 42 | @Override 43 | public boolean run(SlashCommandInteractionEvent event) { 44 | Member member = event.getOption("user").getAsMember(); 45 | if (member != null) { 46 | bot.addMutedUser(member.getUser()); 47 | event.getHook().sendMessage("Muted " + member.getAsMention() + ".").queue(delete()); 48 | return true; 49 | } 50 | event.getHook().sendMessage("Can't mute that person as they weren't found. Try `!Mute [User]`").queue(delete()); 51 | return false; 52 | } 53 | } -------------------------------------------------------------------------------- /src/main/java/com/tjplaysnow/discord/main/commands/UnmuteCommand.java: -------------------------------------------------------------------------------- 1 | package com.tjplaysnow.discord.main.commands; 2 | 3 | import com.tjplaysnow.discord.object.Bot; 4 | import com.tjplaysnow.discord.object.ProgramCommand; 5 | import net.dv8tion.jda.api.Permission; 6 | import net.dv8tion.jda.api.entities.Member; 7 | import net.dv8tion.jda.api.events.interaction.command.SlashCommandInteractionEvent; 8 | import net.dv8tion.jda.api.interactions.commands.OptionType; 9 | import net.dv8tion.jda.api.interactions.commands.build.OptionData; 10 | 11 | import java.util.Collections; 12 | import java.util.List; 13 | 14 | public class UnmuteCommand extends ProgramCommand { 15 | 16 | private final Bot bot; 17 | 18 | public UnmuteCommand(Bot bot) { 19 | this.bot = bot; 20 | } 21 | 22 | @Override 23 | public String getLabel() { 24 | return "Unmute"; 25 | } 26 | 27 | @Override 28 | public String getDescription() { 29 | return "Unmute a user. `!Unmute [User]`"; 30 | } 31 | 32 | @Override 33 | public Permission getPermissionNeeded() { 34 | return Permission.MESSAGE_MANAGE; 35 | } 36 | 37 | @Override 38 | public List getOptionData() { 39 | return Collections.singletonList(new OptionData(OptionType.USER, "user", "The user to mute.", true)); 40 | } 41 | 42 | @Override 43 | public boolean run(SlashCommandInteractionEvent event) { 44 | Member member = event.getOption("user").getAsMember(); 45 | if (member != null) { 46 | bot.removeMutedUser(member.getUser()); 47 | event.getHook().sendMessage("Unmuted " + member.getAsMention() + ".").queue(delete()); 48 | return true; 49 | } 50 | event.getHook().sendMessage("Can't unmute that person as they weren't found. Try `!Unmute [User]`").queue(delete()); 51 | return false; 52 | } 53 | } -------------------------------------------------------------------------------- /src/main/java/com/tjplaysnow/discord/main/commands/package-info.java: -------------------------------------------------------------------------------- 1 | package com.tjplaysnow.discord.main.commands; -------------------------------------------------------------------------------- /src/main/java/com/tjplaysnow/discord/main/consolecommands/BroadcastConsoleCommand.java: -------------------------------------------------------------------------------- 1 | package com.tjplaysnow.discord.main.consolecommands; 2 | 3 | import com.tjplaysnow.discord.object.Bot; 4 | import com.tjplaysnow.discord.object.ProgramCommandConsole; 5 | import net.dv8tion.jda.api.entities.Guild; 6 | import net.dv8tion.jda.api.entities.TextChannel; 7 | 8 | public class BroadcastConsoleCommand extends ProgramCommandConsole { 9 | 10 | private Bot bot; 11 | 12 | public BroadcastConsoleCommand(Bot bot) { 13 | this.bot = bot; 14 | } 15 | 16 | @Override 17 | public void run(String[] args) { 18 | for (Guild guild : bot.getBot().getGuilds()) { 19 | for (TextChannel channel : guild.getTextChannels()) { 20 | if (channel.getName().equalsIgnoreCase("announcements")) { 21 | String message = ""; 22 | for (String s : args) { 23 | if (s.equalsIgnoreCase("broadcast")) { 24 | continue; 25 | } 26 | message += s + " "; 27 | } 28 | channel.sendMessage(message).complete(); 29 | System.out.println("Sent the message."); 30 | System.out.println(); 31 | } 32 | } 33 | } 34 | } 35 | 36 | @Override 37 | public String getLabel() { 38 | return "broadcast"; 39 | } 40 | 41 | @Override 42 | public String getDescription() { 43 | return "Broadcasts a message to a channel in every guild."; 44 | } 45 | 46 | @Override 47 | public String getUsage() { 48 | return "broadcast "; 49 | } 50 | } -------------------------------------------------------------------------------- /src/main/java/com/tjplaysnow/discord/main/consolecommands/HelpConsoleCommand.java: -------------------------------------------------------------------------------- 1 | package com.tjplaysnow.discord.main.consolecommands; 2 | 3 | import com.tjplaysnow.discord.object.Bot; 4 | import com.tjplaysnow.discord.object.ProgramCommandConsole; 5 | 6 | public class HelpConsoleCommand extends ProgramCommandConsole { 7 | 8 | private Bot bot; 9 | 10 | public HelpConsoleCommand(Bot bot) { 11 | this.bot = bot; 12 | } 13 | 14 | @Override 15 | public void run(String[] args) { 16 | System.out.println(" - Help -"); 17 | for (ProgramCommandConsole command : bot.getConsoleCommands()) { 18 | System.out.println("ProgramCommand: " + command.getLabel()); 19 | System.out.println(" - Description: " + command.getDescription()); 20 | System.out.println(" - Usage: " + command.getUsage()); 21 | } 22 | System.out.println(); 23 | } 24 | 25 | @Override 26 | public String getLabel() { 27 | return "help"; 28 | } 29 | 30 | @Override 31 | public String getDescription() { 32 | return "Returns a list of commands and there information."; 33 | } 34 | 35 | @Override 36 | public String getUsage() { 37 | return "help"; 38 | } 39 | } -------------------------------------------------------------------------------- /src/main/java/com/tjplaysnow/discord/main/consolecommands/SpongeMain.java: -------------------------------------------------------------------------------- 1 | package com.tjplaysnow.discord.main.consolecommands; 2 | 3 | import org.spongepowered.api.event.Listener; 4 | import org.spongepowered.api.event.game.state.GameStartedServerEvent; 5 | import org.spongepowered.api.plugin.Plugin; 6 | 7 | @Plugin(id = "discordbotapi", name = "Discord Bot API", url = "http://tjplaysnow.com/", authors = "TJPlaysNow", description = "This plugin is an API to use a Discord ProgramBot.", version = "1.0") 8 | public class SpongeMain { 9 | @Listener 10 | public void onServerStart(GameStartedServerEvent event) {} 11 | } -------------------------------------------------------------------------------- /src/main/java/com/tjplaysnow/discord/main/consolecommands/StopConsoleCommand.java: -------------------------------------------------------------------------------- 1 | package com.tjplaysnow.discord.main.consolecommands; 2 | 3 | import com.tjplaysnow.discord.object.Bot; 4 | import com.tjplaysnow.discord.object.ProgramCommandConsole; 5 | 6 | public class StopConsoleCommand extends ProgramCommandConsole { 7 | 8 | private Bot bot; 9 | private Runnable runnable; 10 | 11 | public StopConsoleCommand(Bot bot) { 12 | this.bot = bot; 13 | runnable = () -> { 14 | }; 15 | } 16 | 17 | public StopConsoleCommand(Runnable runnable, Bot bot) { 18 | this.bot = bot; 19 | this.runnable = runnable; 20 | } 21 | 22 | @Override 23 | public void run(String[] args) { 24 | System.out.println("Stopping the program."); 25 | System.out.println(); 26 | runnable.run(); 27 | bot.logout(); 28 | } 29 | 30 | @Override 31 | public String getLabel() { 32 | return "stop"; 33 | } 34 | 35 | @Override 36 | public String getDescription() { 37 | return "Stops the program properly."; 38 | } 39 | 40 | @Override 41 | public String getUsage() { 42 | return "stop"; 43 | } 44 | } -------------------------------------------------------------------------------- /src/main/java/com/tjplaysnow/discord/main/consolecommands/package-info.java: -------------------------------------------------------------------------------- 1 | package com.tjplaysnow.discord.main.consolecommands; -------------------------------------------------------------------------------- /src/main/java/com/tjplaysnow/discord/object/Command.java: -------------------------------------------------------------------------------- 1 | package com.tjplaysnow.discord.object; 2 | 3 | import net.dv8tion.jda.api.Permission; 4 | import net.dv8tion.jda.api.entities.Guild; 5 | import net.dv8tion.jda.api.entities.Message; 6 | import net.dv8tion.jda.api.entities.MessageChannel; 7 | import net.dv8tion.jda.api.entities.User; 8 | 9 | import java.util.List; 10 | import java.util.concurrent.TimeUnit; 11 | import java.util.function.Consumer; 12 | 13 | /** 14 | * A Discord Command. 15 | * @version 1.0 16 | * @author TJPlaysNow 17 | */ 18 | public interface Command { 19 | 20 | /** 21 | * This is used to tell what the command's label is. 22 | * @return The command's label. 23 | */ 24 | String getLabel(); 25 | 26 | /** 27 | * This is used for simple help commands. 28 | * @return The command's help information. 29 | */ 30 | String getDescription(); 31 | 32 | /** 33 | * The permission level needed to run this command. 34 | * @return Permission to run the command. 35 | */ 36 | Permission getPermissionNeeded(); 37 | 38 | /** 39 | * Called when the command is ran. 40 | * @param user The user that ran the command. 41 | * @param channel The channel the command was ran in. 42 | * @param guild The guild the command was ran in. 43 | * @param label The label of the command, (used for exact message). 44 | * @param args The args sent with the command. 45 | * @return True or False whether the command worked or not. 46 | */ 47 | boolean run(User user, MessageChannel channel, Guild guild, String label, List args); 48 | 49 | /** 50 | * Get's the time to wait before calling delete() 51 | * @return int Time to wait before deleting. 52 | */ 53 | default int getDeleteTime() { 54 | return 5; 55 | } 56 | 57 | /** 58 | * Use to delete messages after a period of time.
59 | * Default time is 5 seconds, use getDeleteTime() 60 | * to specify how long it should wait. 61 | */ 62 | default Consumer delete() { 63 | return (message) -> message.delete().queueAfter(getDeleteTime(), TimeUnit.SECONDS); 64 | } 65 | } -------------------------------------------------------------------------------- /src/main/java/com/tjplaysnow/discord/object/CommandBukkit.java: -------------------------------------------------------------------------------- 1 | package com.tjplaysnow.discord.object; 2 | 3 | import org.bukkit.command.CommandSender; 4 | import org.bukkit.command.defaults.BukkitCommand; 5 | 6 | public class CommandBukkit extends BukkitCommand { 7 | 8 | private ProgramCommandConsole command; 9 | 10 | public CommandBukkit(ProgramCommandConsole command) { 11 | super(command.getLabel()); 12 | this.description = command.getDescription(); 13 | this.usageMessage = "/" + command.getUsage(); 14 | this.setPermission("console.command"); 15 | this.command = command; 16 | } 17 | 18 | @Override 19 | public boolean execute(CommandSender sender, String alias, String[] args) { 20 | if (!sender.hasPermission(this.getPermission())) { 21 | sender.sendMessage("§cUh oh, you don't have permission for that!"); 22 | return true; 23 | } 24 | command.run(args); 25 | return true; 26 | } 27 | } -------------------------------------------------------------------------------- /src/main/java/com/tjplaysnow/discord/object/CommandBungeeManager.java: -------------------------------------------------------------------------------- 1 | package com.tjplaysnow.discord.object; 2 | 3 | import net.md_5.bungee.api.CommandSender; 4 | import net.md_5.bungee.api.ProxyServer; 5 | import net.md_5.bungee.api.plugin.Command; 6 | import net.md_5.bungee.api.plugin.Plugin; 7 | 8 | import java.util.ArrayList; 9 | import java.util.List; 10 | 11 | public class CommandBungeeManager extends ProgramConsoleCommandManager { 12 | 13 | private final List commands; 14 | private final Plugin plugin; 15 | 16 | public CommandBungeeManager(Plugin plugin) { 17 | super(false); 18 | commands = new ArrayList<>(); 19 | this.plugin = plugin; 20 | } 21 | 22 | @Override 23 | public void addCommand(ProgramCommandConsole command) { 24 | commands.add(command); 25 | ProxyServer.getInstance().getPluginManager().registerCommand(plugin, new Command(command.getLabel(), "op") { 26 | @Override 27 | public void execute(CommandSender commandSender, String[] strings) { 28 | command.run(strings); 29 | } 30 | }); 31 | } 32 | 33 | @Override 34 | public List getCommands() { 35 | return commands; 36 | } 37 | 38 | @Override 39 | public void stop() { 40 | 41 | } 42 | 43 | @Override 44 | public void run() { 45 | 46 | } 47 | } -------------------------------------------------------------------------------- /src/main/java/com/tjplaysnow/discord/object/CommandConsoleManager.java: -------------------------------------------------------------------------------- 1 | package com.tjplaysnow.discord.object; 2 | 3 | import java.util.ArrayList; 4 | import java.util.List; 5 | import java.util.Scanner; 6 | 7 | public class CommandConsoleManager extends ProgramConsoleCommandManager { 8 | 9 | private List commands; 10 | private Scanner scanner; 11 | 12 | public CommandConsoleManager() { 13 | super(true); 14 | commands = new ArrayList<>(); 15 | } 16 | 17 | @Override 18 | public void addCommand(ProgramCommandConsole command) { 19 | commands.add(command); 20 | } 21 | 22 | @Override 23 | public List getCommands() { 24 | return commands; 25 | } 26 | 27 | @Override 28 | public void stop() { 29 | stopThread(); 30 | } 31 | 32 | @Override 33 | public void run() { 34 | while (isRunning()) { 35 | scanner = new Scanner(System.in); 36 | String[] args = scanner.nextLine().split(" "); 37 | for (ProgramCommandConsole command : commands) { 38 | if (args[0].equalsIgnoreCase(command.getLabel())) { 39 | command.run(args); 40 | } 41 | } 42 | } 43 | scanner.close(); 44 | } 45 | } -------------------------------------------------------------------------------- /src/main/java/com/tjplaysnow/discord/object/CommandSpigotManager.java: -------------------------------------------------------------------------------- 1 | package com.tjplaysnow.discord.object; 2 | 3 | import org.bukkit.Bukkit; 4 | import org.bukkit.command.CommandMap; 5 | 6 | import java.lang.reflect.Field; 7 | import java.util.ArrayList; 8 | import java.util.List; 9 | 10 | public class CommandSpigotManager extends ProgramConsoleCommandManager { 11 | 12 | private List commands; 13 | 14 | public CommandSpigotManager() { 15 | super(false); 16 | commands = new ArrayList<>(); 17 | } 18 | 19 | @Override 20 | public void addCommand(ProgramCommandConsole command) { 21 | commands.add(command); 22 | try { 23 | final Field bukkitCommandMap = Bukkit.getServer().getClass().getDeclaredField("commandMap"); 24 | bukkitCommandMap.setAccessible(true); 25 | CommandMap commandMap = (CommandMap) bukkitCommandMap.get(Bukkit.getServer()); 26 | commandMap.register(command.getLabel(), new CommandBukkit(command)); 27 | } catch(Exception e) { 28 | e.printStackTrace(); 29 | } 30 | } 31 | 32 | @Override 33 | public List getCommands() { 34 | return commands; 35 | } 36 | 37 | @Override 38 | public void stop() {} 39 | 40 | @Override 41 | public void run() {} 42 | } -------------------------------------------------------------------------------- /src/main/java/com/tjplaysnow/discord/object/CommandSpongerManager.java: -------------------------------------------------------------------------------- 1 | package com.tjplaysnow.discord.object; 2 | 3 | import org.spongepowered.api.Sponge; 4 | import org.spongepowered.api.command.CommandResult; 5 | import org.spongepowered.api.command.spec.CommandSpec; 6 | import org.spongepowered.api.plugin.Plugin; 7 | import org.spongepowered.api.text.Text; 8 | 9 | import java.util.List; 10 | 11 | public class CommandSpongerManager extends ProgramConsoleCommandManager { 12 | 13 | private Plugin plugin; 14 | 15 | protected CommandSpongerManager(Plugin plugin) { 16 | super(false); 17 | this.plugin = plugin; 18 | } 19 | 20 | @Override 21 | public void addCommand(ProgramCommandConsole command) { 22 | CommandSpec myCommandSpec = CommandSpec.builder() 23 | .description(Text.of(command.getDescription())) 24 | .permission("discord.operator") 25 | .executor((sender, args) -> { 26 | command.run(args.getAll("").toArray(new String[]{})); 27 | return CommandResult.builder().successCount(1).build(); 28 | }) 29 | .build(); 30 | 31 | Sponge.getCommandManager().register(plugin, myCommandSpec, "helloworld", "hello", "test"); 32 | } 33 | 34 | @Override 35 | public List getCommands() { 36 | return null; 37 | } 38 | 39 | @Override 40 | public void stop() { 41 | 42 | } 43 | 44 | @Override 45 | public void run() { 46 | 47 | } 48 | } -------------------------------------------------------------------------------- /src/main/java/com/tjplaysnow/discord/object/ConsoleCommand.java: -------------------------------------------------------------------------------- 1 | package com.tjplaysnow.discord.object; 2 | 3 | /** 4 | * A Console ProgramCommand. 5 | * @version 1.0 6 | * @author TJPlaysNow 7 | */ 8 | public interface ConsoleCommand { 9 | /** 10 | * This is used to tell what the command's label is. 11 | * @return The command's label. 12 | */ 13 | public String getLabel(); 14 | 15 | /** 16 | * This is used to tell how to use the command. 17 | * @return The command's usage. 18 | */ 19 | public String getUsage(); 20 | 21 | /** 22 | * This is used for simple help commands. 23 | * @return The command's help information. 24 | */ 25 | public String getDescrition(); 26 | 27 | /** 28 | * Called when the command is ran. 29 | * @param args The args sent with the command. 30 | */ 31 | public void run(String[] args); 32 | } -------------------------------------------------------------------------------- /src/main/java/com/tjplaysnow/discord/object/ProgramBot.java: -------------------------------------------------------------------------------- 1 | package com.tjplaysnow.discord.object; 2 | 3 | import com.tjplaysnow.discord.object.logger.LogLevel; 4 | import com.tjplaysnow.discord.object.logger.Logger; 5 | import net.dv8tion.jda.api.JDA; 6 | import net.dv8tion.jda.api.JDABuilder; 7 | import net.dv8tion.jda.api.entities.Activity; 8 | import net.dv8tion.jda.api.hooks.EventListener; 9 | import net.dv8tion.jda.api.requests.GatewayIntent; 10 | 11 | import javax.security.auth.login.LoginException; 12 | import java.util.EnumSet; 13 | 14 | public abstract class ProgramBot implements EventListener { 15 | 16 | private final String token; 17 | private final Logger logger; 18 | private boolean isOnline; 19 | protected JDA jda; 20 | 21 | protected ProgramBot(String token) { 22 | this.token = token; 23 | logger = new Logger(LogLevel.INFO); 24 | } 25 | 26 | protected ProgramBot(String token, LogLevel logLevel) { 27 | this.token = token; 28 | logger = new Logger(logLevel); 29 | } 30 | 31 | protected void build() { 32 | try { 33 | jda = JDABuilder.createDefault(token, EnumSet.allOf(GatewayIntent.class)).addEventListeners(this).build(); 34 | jda.updateCommands().queue(); 35 | isOnline = true; 36 | } catch (LoginException | IllegalArgumentException e) { 37 | e.printStackTrace(); 38 | isOnline = false; 39 | } 40 | } 41 | 42 | /** 43 | * This is used for indepth manipulation with the bot. 44 | * @return JDA instance of the bot. 45 | */ 46 | public JDA getBot() { 47 | return jda; 48 | } 49 | 50 | /** 51 | * Checks to see if the bot is online. 52 | * @return Boolean of online. 53 | */ 54 | public boolean isOnline() { 55 | return isOnline; 56 | } 57 | 58 | /** 59 | * Stops the bot and goes offline. 60 | */ 61 | public void logout() { 62 | jda.shutdown(); 63 | isOnline = false; 64 | } 65 | 66 | /** 67 | * Set the bot's playing game text. 68 | * @param game Playing text. 69 | */ 70 | public void setGame(String game) { 71 | jda.getPresence().setPresence(Activity.playing(game), true); 72 | } 73 | 74 | /** 75 | * Set the bot's activity with the text. 76 | * 77 | * @param action The bot's action (Listening, Playing, Streaming, Watching) 78 | * @param text The text to display. 79 | * 80 | */ 81 | public void setActivity(String action, String text) { 82 | if (action.equalsIgnoreCase("Listening")) { 83 | jda.getPresence().setPresence(Activity.listening(text), true); 84 | } else if (action.equals("Playing")) { 85 | jda.getPresence().setPresence(Activity.playing(text), true); 86 | } else if (action.equals("Streaming")) { 87 | jda.getPresence().setPresence(Activity.streaming(text.split(" : ")[0], text.split(" : ")[1]), true); 88 | } else if (action.equals("Watching")) { 89 | jda.getPresence().setPresence(Activity.watching(text), true); 90 | } 91 | } 92 | 93 | /** 94 | * Get the logger for logging purposes. 95 | * @return Logger 96 | */ 97 | public Logger logger() { 98 | return logger; 99 | } 100 | } -------------------------------------------------------------------------------- /src/main/java/com/tjplaysnow/discord/object/ProgramCommand.java: -------------------------------------------------------------------------------- 1 | package com.tjplaysnow.discord.object; 2 | 3 | import net.dv8tion.jda.api.Permission; 4 | import net.dv8tion.jda.api.entities.Message; 5 | import net.dv8tion.jda.api.events.interaction.command.SlashCommandInteractionEvent; 6 | import net.dv8tion.jda.api.interactions.commands.build.OptionData; 7 | import org.jetbrains.annotations.NotNull; 8 | 9 | import java.util.List; 10 | import java.util.function.Consumer; 11 | 12 | /** 13 | * A Discord ProgramCommand. 14 | * @version 1.0 15 | * @author TJPlaysNow 16 | */ 17 | public abstract class ProgramCommand { 18 | 19 | /** 20 | * This is used to tell what the command's label is. 21 | * 22 | * @return The command's label. 23 | */ 24 | public abstract String getLabel(); 25 | 26 | /** 27 | * This is for the new command system. 28 | * 29 | * @return The options the command should have. 30 | */ 31 | public abstract List getOptionData(); 32 | 33 | /** 34 | * This is used for simple help commands. 35 | * 36 | * @return The command's help information. 37 | */ 38 | public String getDescription() { 39 | return ""; 40 | } 41 | 42 | /** 43 | * The permission level needed to run this command. 44 | * @return Permission to run the command. 45 | */ 46 | public Permission getPermissionNeeded() { 47 | return Permission.MESSAGE_SEND; 48 | } 49 | 50 | /** 51 | * Called when the command is ran. 52 | * 53 | * @param event The slash command event triggered when the event is called. 54 | */ 55 | protected abstract boolean run(@NotNull SlashCommandInteractionEvent event); 56 | 57 | /** 58 | * Get's the time to wait before calling delete() 59 | * @return int Time to wait before deleting. 60 | */ 61 | protected int getDeleteTime() { 62 | return 5; 63 | } 64 | 65 | /** 66 | * Use to delete messages after a period of time.
67 | * Default time is 5 seconds, use getDeleteTime() 68 | * to specify how long it should wait. 69 | */ 70 | @Deprecated 71 | protected Consumer delete() { 72 | return (message) -> {/*message.delete().queueAfter(getDeleteTime(), TimeUnit.SECONDS)*/}; 73 | } 74 | } -------------------------------------------------------------------------------- /src/main/java/com/tjplaysnow/discord/object/ProgramCommandConsole.java: -------------------------------------------------------------------------------- 1 | package com.tjplaysnow.discord.object; 2 | 3 | /** 4 | * A Console ProgramCommand. 5 | * @version 1.0 6 | * @author TJPlaysNow 7 | */ 8 | public abstract class ProgramCommandConsole { 9 | 10 | /** 11 | * This is used to tell what the command's label is. 12 | * @return The command's label. 13 | */ 14 | public abstract String getLabel(); 15 | 16 | /** 17 | * This is used to tell how to use the command. 18 | * @return The command's usage. 19 | */ 20 | public String getUsage() { 21 | return ""; 22 | } 23 | 24 | /** 25 | * This is used for simple help commands. 26 | * @return The command's help information. 27 | */ 28 | public String getDescription() { 29 | return ""; 30 | } 31 | 32 | /** 33 | * Called when the command is ran. 34 | * @param args The args sent with the command. 35 | */ 36 | public abstract void run(String[] args); 37 | } -------------------------------------------------------------------------------- /src/main/java/com/tjplaysnow/discord/object/ProgramConsoleCommandManager.java: -------------------------------------------------------------------------------- 1 | package com.tjplaysnow.discord.object; 2 | 3 | import java.util.List; 4 | 5 | public abstract class ProgramConsoleCommandManager implements Runnable { 6 | 7 | private Thread thread; 8 | private boolean running; 9 | 10 | protected ProgramConsoleCommandManager(boolean thread) { 11 | if (thread) { 12 | running = true; 13 | this.thread = new Thread(this, "ProgramThread"); 14 | this.thread.start(); 15 | } 16 | } 17 | 18 | /** 19 | * Add a command to the manager. 20 | * @param command A new command. 21 | */ 22 | public abstract void addCommand(ProgramCommandConsole command); 23 | 24 | public abstract List getCommands(); 25 | 26 | /** 27 | * Stops the ProgramBot Thread thread. 28 | */ 29 | public abstract void stop(); 30 | 31 | /** 32 | * The run loop. 33 | */ 34 | @Override 35 | public abstract void run(); 36 | 37 | /** 38 | * Stops the Thread. 39 | */ 40 | protected void stopThread() { 41 | thread.interrupt(); 42 | running = false; 43 | } 44 | 45 | /** 46 | * Get whether the thread is still running. 47 | * @return 48 | */ 49 | protected boolean isRunning() { 50 | return running; 51 | } 52 | } -------------------------------------------------------------------------------- /src/main/java/com/tjplaysnow/discord/object/ProgramThread.java: -------------------------------------------------------------------------------- 1 | package com.tjplaysnow.discord.object; 2 | 3 | public abstract class ProgramThread implements Runnable { 4 | 5 | private Thread thread; 6 | private boolean running; 7 | 8 | protected ProgramThread(boolean thread) { 9 | if (thread) { 10 | running = true; 11 | this.thread = new Thread(this, "ProgramThread"); 12 | this.thread.start(); 13 | } 14 | } 15 | 16 | /** 17 | * A new action to run later. 18 | * @param action The action to be run. 19 | * @param seconds The time in seconds to wait before running the action. 20 | */ 21 | public abstract void addAction(Runnable action, int seconds); 22 | 23 | /** 24 | * Stops the ProgramBot Thread thread. 25 | */ 26 | public abstract void stop(); 27 | 28 | /** 29 | * The run loop. 30 | */ 31 | @Override 32 | public abstract void run(); 33 | 34 | /** 35 | * Stops the Thread. 36 | */ 37 | protected void stopThread() { 38 | thread.interrupt(); 39 | running = false; 40 | } 41 | 42 | /** 43 | * Get whether the thread is still running. 44 | * @return 45 | */ 46 | public boolean isRunning() { 47 | return running; 48 | } 49 | } -------------------------------------------------------------------------------- /src/main/java/com/tjplaysnow/discord/object/ReactionAddEvent.java: -------------------------------------------------------------------------------- 1 | package com.tjplaysnow.discord.object; 2 | 3 | import net.dv8tion.jda.api.events.message.react.MessageReactionAddEvent; 4 | 5 | import java.util.function.Consumer; 6 | 7 | public class ReactionAddEvent { 8 | 9 | private final Long messageID; 10 | private final Consumer event; 11 | 12 | public ReactionAddEvent(Long messageID, Consumer event) { 13 | this.messageID = messageID; 14 | this.event = event; 15 | } 16 | 17 | public Long getMessageID() { 18 | return messageID; 19 | } 20 | 21 | public Consumer getEvent() { 22 | return event; 23 | } 24 | } -------------------------------------------------------------------------------- /src/main/java/com/tjplaysnow/discord/object/SlashCommandEvents.java: -------------------------------------------------------------------------------- 1 | package com.tjplaysnow.discord.object; 2 | 3 | import net.dv8tion.jda.api.events.interaction.command.SlashCommandInteractionEvent; 4 | import net.dv8tion.jda.api.hooks.ListenerAdapter; 5 | import org.jetbrains.annotations.NotNull; 6 | 7 | public class SlashCommandEvents extends ListenerAdapter { 8 | 9 | private final Bot bot; 10 | 11 | public SlashCommandEvents(Bot bot) { 12 | this.bot = bot; 13 | } 14 | 15 | @Override 16 | public void onSlashCommandInteraction(@NotNull SlashCommandInteractionEvent event) { 17 | for (ProgramCommand command : bot.getCommands()) { 18 | if (event.getName().equals(command.getLabel())) { 19 | event.deferReply().queue(); 20 | command.run(event); 21 | } 22 | } 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /src/main/java/com/tjplaysnow/discord/object/ThreadBungee.java: -------------------------------------------------------------------------------- 1 | package com.tjplaysnow.discord.object; 2 | 3 | import net.md_5.bungee.api.ProxyServer; 4 | import net.md_5.bungee.api.plugin.Plugin; 5 | 6 | import java.util.concurrent.TimeUnit; 7 | 8 | public class ThreadBungee extends ProgramThread { 9 | 10 | private final Plugin plugin; 11 | 12 | public ThreadBungee(Plugin plugin) { 13 | super(false); 14 | this.plugin = plugin; 15 | } 16 | 17 | @Override 18 | public void addAction(Runnable action, int seconds) { 19 | ProxyServer.getInstance().getScheduler().schedule(plugin, action, seconds, TimeUnit.SECONDS); 20 | } 21 | 22 | @Override 23 | public void stop() { 24 | } 25 | 26 | @Override 27 | public void run() { 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /src/main/java/com/tjplaysnow/discord/object/ThreadHandle.java: -------------------------------------------------------------------------------- 1 | package com.tjplaysnow.discord.object; 2 | 3 | import java.util.concurrent.Executors; 4 | import java.util.concurrent.ScheduledExecutorService; 5 | import java.util.concurrent.TimeUnit; 6 | 7 | public class ThreadHandle extends ProgramThread { 8 | 9 | private ScheduledExecutorService scheduledExecutorService; 10 | 11 | public ThreadHandle() { 12 | super(false); 13 | scheduledExecutorService = Executors.newScheduledThreadPool(5); 14 | } 15 | 16 | @Override 17 | public void addAction(Runnable action, int seconds) { 18 | scheduledExecutorService.schedule(action, seconds, TimeUnit.SECONDS); 19 | } 20 | 21 | @Override 22 | public void stop() { 23 | scheduledExecutorService.shutdown(); 24 | } 25 | 26 | @Override 27 | public void run() {} 28 | } -------------------------------------------------------------------------------- /src/main/java/com/tjplaysnow/discord/object/ThreadSpigot.java: -------------------------------------------------------------------------------- 1 | package com.tjplaysnow.discord.object; 2 | 3 | import org.bukkit.Bukkit; 4 | import org.bukkit.plugin.Plugin; 5 | 6 | public class ThreadSpigot extends ProgramThread { 7 | 8 | private Plugin plugin; 9 | 10 | public ThreadSpigot(Plugin plugin) { 11 | super(false); 12 | this.plugin = plugin; 13 | } 14 | 15 | @Override 16 | public void addAction(Runnable action, int seconds) { 17 | Bukkit.getScheduler().scheduleSyncDelayedTask(plugin, action, (seconds * 20)); 18 | } 19 | 20 | @Override 21 | public void stop() {} 22 | 23 | @Override 24 | public void run() {} 25 | } -------------------------------------------------------------------------------- /src/main/java/com/tjplaysnow/discord/object/logger/Colors.java: -------------------------------------------------------------------------------- 1 | package com.tjplaysnow.discord.object.logger; 2 | 3 | /** 4 | * Logger Colors 5 | *

Used for logging colors to 6 | * the console. It is known that 7 | * colors don't work in Windows 8 | * console.

9 | * @author TJPlaysNow 10 | */ 11 | public class Colors { 12 | 13 | /** 14 | * Reset color 15 | */ 16 | public static final String RESET = "\033[0m"; 17 | 18 | /** 19 | * Black 20 | */ 21 | public static final String BLACK = "\033[0;30m"; 22 | 23 | /** 24 | * Red 25 | */ 26 | public static final String RED = "\033[0;31m"; 27 | 28 | /** 29 | * Green 30 | */ 31 | public static final String GREEN = "\033[0;32m"; 32 | 33 | /** 34 | * Yellow 35 | */ 36 | public static final String YELLOW = "\033[0;33m"; 37 | 38 | /** 39 | * Blue 40 | */ 41 | public static final String BLUE = "\033[0;34m"; 42 | 43 | /** 44 | * Purple 45 | */ 46 | public static final String PURPLE = "\033[0;35m"; 47 | 48 | /** 49 | * Cyan 50 | */ 51 | public static final String CYAN = "\033[0;36m"; 52 | 53 | /** 54 | * White 55 | */ 56 | public static final String WHITE = "\033[0;37m"; 57 | 58 | // Bold 59 | public static final String BLACK_BOLD = "\033[1;30m"; // BLACK 60 | public static final String RED_BOLD = "\033[1;31m"; // RED 61 | public static final String GREEN_BOLD = "\033[1;32m"; // GREEN 62 | public static final String YELLOW_BOLD = "\033[1;33m"; // YELLOW 63 | public static final String BLUE_BOLD = "\033[1;34m"; // BLUE 64 | public static final String PURPLE_BOLD = "\033[1;35m"; // PURPLE 65 | public static final String CYAN_BOLD = "\033[1;36m"; // CYAN 66 | public static final String WHITE_BOLD = "\033[1;37m"; // WHITE 67 | 68 | // Underline 69 | public static final String BLACK_UNDERLINED = "\033[4;30m"; // BLACK 70 | public static final String RED_UNDERLINED = "\033[4;31m"; // RED 71 | public static final String GREEN_UNDERLINED = "\033[4;32m"; // GREEN 72 | public static final String YELLOW_UNDERLINED = "\033[4;33m"; // YELLOW 73 | public static final String BLUE_UNDERLINED = "\033[4;34m"; // BLUE 74 | public static final String PURPLE_UNDERLINED = "\033[4;35m"; // PURPLE 75 | public static final String CYAN_UNDERLINED = "\033[4;36m"; // CYAN 76 | public static final String WHITE_UNDERLINED = "\033[4;37m"; // WHITE 77 | 78 | // Background 79 | public static final String BLACK_BACKGROUND = "\033[40m"; // BLACK 80 | public static final String RED_BACKGROUND = "\033[41m"; // RED 81 | public static final String GREEN_BACKGROUND = "\033[42m"; // GREEN 82 | public static final String YELLOW_BACKGROUND = "\033[43m"; // YELLOW 83 | public static final String BLUE_BACKGROUND = "\033[44m"; // BLUE 84 | public static final String PURPLE_BACKGROUND = "\033[45m"; // PURPLE 85 | public static final String CYAN_BACKGROUND = "\033[46m"; // CYAN 86 | public static final String WHITE_BACKGROUND = "\033[47m"; // WHITE 87 | 88 | // High Intensity 89 | public static final String BLACK_BRIGHT = "\033[0;90m"; // BLACK 90 | public static final String RED_BRIGHT = "\033[0;91m"; // RED 91 | public static final String GREEN_BRIGHT = "\033[0;92m"; // GREEN 92 | public static final String YELLOW_BRIGHT = "\033[0;93m"; // YELLOW 93 | public static final String BLUE_BRIGHT = "\033[0;94m"; // BLUE 94 | public static final String PURPLE_BRIGHT = "\033[0;95m"; // PURPLE 95 | public static final String CYAN_BRIGHT = "\033[0;96m"; // CYAN 96 | public static final String WHITE_BRIGHT = "\033[0;97m"; // WHITE 97 | 98 | // Bold High Intensity 99 | public static final String BLACK_BOLD_BRIGHT = "\033[1;90m"; // BLACK 100 | public static final String RED_BOLD_BRIGHT = "\033[1;91m"; // RED 101 | public static final String GREEN_BOLD_BRIGHT = "\033[1;92m"; // GREEN 102 | public static final String YELLOW_BOLD_BRIGHT = "\033[1;93m";// YELLOW 103 | public static final String BLUE_BOLD_BRIGHT = "\033[1;94m"; // BLUE 104 | public static final String PURPLE_BOLD_BRIGHT = "\033[1;95m";// PURPLE 105 | public static final String CYAN_BOLD_BRIGHT = "\033[1;96m"; // CYAN 106 | public static final String WHITE_BOLD_BRIGHT = "\033[1;97m"; // WHITE 107 | 108 | // High Intensity backgrounds 109 | public static final String BLACK_BACKGROUND_BRIGHT = "\033[0;100m";// BLACK 110 | public static final String RED_BACKGROUND_BRIGHT = "\033[0;101m";// RED 111 | public static final String GREEN_BACKGROUND_BRIGHT = "\033[0;102m";// GREEN 112 | public static final String YELLOW_BACKGROUND_BRIGHT = "\033[0;103m";// YELLOW 113 | public static final String BLUE_BACKGROUND_BRIGHT = "\033[0;104m";// BLUE 114 | public static final String PURPLE_BACKGROUND_BRIGHT = "\033[0;105m"; // PURPLE 115 | public static final String CYAN_BACKGROUND_BRIGHT = "\033[0;106m"; // CYAN 116 | public static final String WHITE_BACKGROUND_BRIGHT = "\033[0;107m"; // WHITE 117 | } -------------------------------------------------------------------------------- /src/main/java/com/tjplaysnow/discord/object/logger/LogLevel.java: -------------------------------------------------------------------------------- 1 | package com.tjplaysnow.discord.object.logger; 2 | 3 | /** 4 | * The Log Level of a Message 5 | *

Used to determine how to log 6 | * a message to console.

7 | * 8 | * @author TJPlaysNow 9 | */ 10 | public enum LogLevel { 11 | /** 12 | * Log as spam 13 | *

Not visible unless 14 | * in debug mode

15 | */ 16 | SPAM(0), 17 | 18 | /** 19 | * Log as info 20 | *

Visible in 21 | * deffault mode

22 | */ 23 | INFO(1), 24 | 25 | /** 26 | * Log warnings 27 | *

Will normally 28 | * show up.

29 | */ 30 | WARN(2), 31 | 32 | /** 33 | * Log errors 34 | *

Will almost 35 | * always log.

36 | */ 37 | ERROR(3), 38 | 39 | /** 40 | * Log nothing 41 | *

This mode won't 42 | * log anything to the 43 | * console.

44 | */ 45 | NONE(4); 46 | 47 | private int level; 48 | 49 | private LogLevel(int level) { 50 | this.level = level; 51 | } 52 | 53 | /** 54 | * Get the log level 55 | *

The higher the log level 56 | * the more important.

57 | * 58 | * @return The log level in form of int. 59 | */ 60 | public int getLevel() { 61 | return level; 62 | } 63 | } -------------------------------------------------------------------------------- /src/main/java/com/tjplaysnow/discord/object/logger/Logger.java: -------------------------------------------------------------------------------- 1 | package com.tjplaysnow.discord.object.logger; 2 | 3 | /** 4 | * The easy logger lib 5 | *

Used to log messages to the console.

6 | * 7 | * @author TJPlaysNow 8 | * 9 | */ 10 | public class Logger { 11 | 12 | private String log; 13 | private LogLevel printLevel; 14 | 15 | /** 16 | * Create a new Logger 17 | *

Create a new logger with 18 | * a log level.

19 | * 20 | * @param printLevel The LogLevel it will print at. 21 | */ 22 | public Logger(LogLevel printLevel) { 23 | this.printLevel = printLevel; 24 | } 25 | 26 | /** 27 | * Log something to the conosle. 28 | *

Used to log a message to the console.

29 | * 30 | * @param level The level you are logging at. 31 | * @param message The message you are logging. 32 | */ 33 | public void log(LogLevel level, String message) { 34 | if (printLevel.getLevel() >= level.getLevel()) { 35 | if (printLevel.getLevel() <= 0) { 36 | if (level == LogLevel.SPAM) { 37 | log += Colors.WHITE + "[ProgramBot] [SPAM]: " + Colors.RESET + message + "\n"; 38 | System.out.println(Colors.WHITE + "[ProgramBot] [SPAM]: " + Colors.RESET + message); 39 | } 40 | } 41 | if (printLevel.getLevel() <= 1) { 42 | if (level == LogLevel.INFO) { 43 | log += Colors.WHITE + "[ProgramBot] [INFO]: " + Colors.RESET + message + "\n"; 44 | System.out.println(Colors.WHITE + "[ProgramBot] [INFO]: " + Colors.RESET + message); 45 | } 46 | } 47 | if (printLevel.getLevel() <= 2) { 48 | if (level == LogLevel.WARN) { 49 | log += Colors.YELLOW + "[ProgramBot] [WARNING]: " + Colors.RESET + message + "\n"; 50 | System.out.println(Colors.YELLOW + "[ProgramBot] [WARNING]: " + Colors.RESET + message); 51 | } 52 | } 53 | if (printLevel.getLevel() <= 3) { 54 | if (level == LogLevel.ERROR) { 55 | log += Colors.RED + "[ProgramBot] [ERROR]: " + Colors.RESET + message + "\n"; 56 | System.out.println(Colors.RED + "[ProgramBot] [ERROR]: " + Colors.RESET + message); 57 | } 58 | } 59 | } 60 | } 61 | 62 | /** 63 | * Spam messages 64 | *

Used when you are printing 65 | * unneeded data to the console

66 | * 67 | * @param message The spam message. 68 | */ 69 | public void spam(String message) { 70 | if (printLevel.getLevel() <= 0) { 71 | log += Colors.WHITE + "[ProgramBot] [SPAM]: " + Colors.RESET + message + "\n"; 72 | System.out.println(Colors.WHITE + "[ProgramBot] [SPAM]: " + Colors.RESET + message); 73 | } 74 | } 75 | 76 | /** 77 | * Info messages 78 | *

Used when you are printing 79 | * informational data to the console

80 | * 81 | * @param message The info message. 82 | */ 83 | public void info(String message) { 84 | if (printLevel.getLevel() <= 1) { 85 | log += Colors.WHITE + "[ProgramBot] [INFO]: " + Colors.RESET + message + "\n"; 86 | System.out.println(Colors.WHITE + "[ProgramBot] [INFO]: " + Colors.RESET + message); 87 | } 88 | } 89 | 90 | /** 91 | * Warning messages 92 | *

Used when you are printing 93 | * important data to the console

94 | * 95 | * @param message The warn message. 96 | */ 97 | public void warn(String message) { 98 | if (printLevel.getLevel() <= 2) { 99 | log += Colors.YELLOW + "[ProgramBot] [WARNING]: " + Colors.RESET + message + "\n"; 100 | System.out.println(Colors.YELLOW + "[ProgramBot] [WARNING]: " + Colors.RESET + message); 101 | } 102 | } 103 | 104 | /** 105 | * Error messages 106 | *

Used when you are printing 107 | * extreme data to the console

108 | * 109 | * @param message The error message. 110 | */ 111 | public void error(String message) { 112 | if (printLevel.getLevel() <= 3) { 113 | log += Colors.RED + "[ProgramBot] [ERROR]: " + Colors.RESET + message + "\n"; 114 | System.out.println(Colors.RED + "[ProgramBot] [ERROR]: " + Colors.RESET + message); 115 | } 116 | } 117 | 118 | /** 119 | * Get the total Discord ProgramBot Log 120 | * @return String 121 | */ 122 | public String getLog() { 123 | return log; 124 | } 125 | } -------------------------------------------------------------------------------- /src/main/java/com/tjplaysnow/discord/object/logger/package-info.java: -------------------------------------------------------------------------------- 1 | package com.tjplaysnow.discord.object.logger; -------------------------------------------------------------------------------- /src/main/java/com/tjplaysnow/discord/object/package-info.java: -------------------------------------------------------------------------------- 1 | package com.tjplaysnow.discord.object; -------------------------------------------------------------------------------- /src/main/resources/bungee.yml: -------------------------------------------------------------------------------- 1 | name: DiscordBotAPI 2 | version: '5.1' 3 | main: com.tjplaysnow.discord.main.BungeeMain 4 | description: This plugin is an API to use a Discord ProgramBot. 5 | author: TJPlaysNow -------------------------------------------------------------------------------- /src/main/resources/logback.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 7 | [%-5level %thread]: %msg%n 8 | 9 | 10 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /src/main/resources/mcmod.info: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "modid": "DiscordBotAPI", 4 | "name": "Discord Bot API", 5 | "version": "5.1", 6 | "description": "This plugin is an API to use a Discord ProgramBot.", 7 | "url": "http://tjplaysnow.com/", 8 | "authorList": [ 9 | "TJPlaysNow" 10 | ], 11 | "dependencies": [ 12 | "spongeapi@7.0.0" 13 | ], 14 | "requiredMods": [ 15 | "spongeapi@7.0.0" 16 | ] 17 | } 18 | ] 19 | -------------------------------------------------------------------------------- /src/main/resources/plugin.yml: -------------------------------------------------------------------------------- 1 | name: DiscordBotAPI 2 | version: 5.1 3 | main: com.tjplaysnow.discord.main.PluginMain 4 | description: This plugin is an API to use a Discord ProgramBot. 5 | author: TJPlaysNow -------------------------------------------------------------------------------- /target/classes/bungee.yml: -------------------------------------------------------------------------------- 1 | name: DiscordBotAPI 2 | version: '5.1' 3 | main: com.tjplaysnow.discord.main.BungeeMain 4 | description: This plugin is an API to use a Discord ProgramBot. 5 | author: TJPlaysNow -------------------------------------------------------------------------------- /target/classes/logback.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 7 | [%-5level %thread]: %msg%n 8 | 9 | 10 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /target/classes/mcmod.info: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "modid": "discordbotapi", 4 | "name": "Discord Bot API", 5 | "version": "1.0", 6 | "description": "This plugin is an API to use a Discord ProgramBot.", 7 | "url": "http://tjplaysnow.com/", 8 | "authorList": [ 9 | "TJPlaysNow" 10 | ], 11 | "dependencies": [ 12 | "spongeapi@7.2.0" 13 | ], 14 | "requiredMods": [ 15 | "spongeapi@7.2.0" 16 | ] 17 | } 18 | ] 19 | -------------------------------------------------------------------------------- /target/classes/plugin.yml: -------------------------------------------------------------------------------- 1 | name: DiscordBotAPI 2 | version: 5.1 3 | main: com.tjplaysnow.discord.main.PluginMain 4 | description: This plugin is an API to use a Discord ProgramBot. 5 | author: TJPlaysNow -------------------------------------------------------------------------------- /target/maven-archiver/pom.properties: -------------------------------------------------------------------------------- 1 | #Generated by Maven 2 | #Sun Apr 11 13:12:08 CDT 2021 3 | groupId=com.tjplaysnow 4 | artifactId=DiscordBotAPI 5 | version=4.0 6 | -------------------------------------------------------------------------------- /target/maven-status/maven-compiler-plugin/compile/default-compile/createdFiles.lst: -------------------------------------------------------------------------------- 1 | com\tjplaysnow\discord\object\Bot$1.class 2 | com\tjplaysnow\discord\main\consolecommands\SpongeMain.class 3 | com\tjplaysnow\discord\main\commands\MuteCommand.class 4 | com\tjplaysnow\discord\main\Main.class 5 | com\tjplaysnow\discord\object\ProgramConsoleCommandManager.class 6 | com\tjplaysnow\discord\object\ThreadHandle.class 7 | com\tjplaysnow\discord\object\CommandSpongerManager.class 8 | com\tjplaysnow\discord\object\logger\LogLevel.class 9 | com\tjplaysnow\discord\object\CommandBukkit.class 10 | com\tjplaysnow\discord\object\ProgramCommandConsole.class 11 | com\tjplaysnow\discord\main\BungeeMain.class 12 | com\tjplaysnow\discord\main\PluginMain.class 13 | com\tjplaysnow\discord\main\commands\UnmuteCommand.class 14 | com\tjplaysnow\discord\main\consolecommands\StopConsoleCommand.class 15 | com\tjplaysnow\discord\object\ReactionAddEvent.class 16 | com\tjplaysnow\discord\main\consolecommands\BroadcastConsoleCommand.class 17 | com\tjplaysnow\discord\object\ProgramThread.class 18 | com\tjplaysnow\discord\main\commands\HelpCommand.class 19 | com\tjplaysnow\discord\main\consolecommands\HelpConsoleCommand.class 20 | com\tjplaysnow\discord\object\ConsoleCommand.class 21 | com\tjplaysnow\discord\object\Command.class 22 | com\tjplaysnow\discord\object\ProgramBot.class 23 | com\tjplaysnow\discord\object\Bot$2.class 24 | com\tjplaysnow\discord\config\Config.class 25 | com\tjplaysnow\discord\object\ThreadSpigot.class 26 | com\tjplaysnow\discord\object\CommandConsoleManager.class 27 | com\tjplaysnow\discord\object\ProgramCommand.class 28 | com\tjplaysnow\discord\object\logger\Colors.class 29 | com\tjplaysnow\discord\config\File.class 30 | com\tjplaysnow\discord\object\CommandSpigotManager.class 31 | com\tjplaysnow\discord\object\Bot.class 32 | com\tjplaysnow\discord\object\logger\Logger.class 33 | -------------------------------------------------------------------------------- /target/maven-status/maven-compiler-plugin/compile/default-compile/inputFiles.lst: -------------------------------------------------------------------------------- 1 | F:\Workspace\Spigot - Discord Bot API - JDA\src\main\java\com\tjplaysnow\discord\object\logger\Colors.java 2 | F:\Workspace\Spigot - Discord Bot API - JDA\src\main\java\com\tjplaysnow\discord\main\consolecommands\BroadcastConsoleCommand.java 3 | F:\Workspace\Spigot - Discord Bot API - JDA\src\main\java\com\tjplaysnow\discord\main\Main.java 4 | F:\Workspace\Spigot - Discord Bot API - JDA\src\main\java\com\tjplaysnow\discord\object\ProgramCommandConsole.java 5 | F:\Workspace\Spigot - Discord Bot API - JDA\src\main\java\com\tjplaysnow\discord\config\File.java 6 | F:\Workspace\Spigot - Discord Bot API - JDA\src\main\java\com\tjplaysnow\discord\object\logger\package-info.java 7 | F:\Workspace\Spigot - Discord Bot API - JDA\src\main\java\com\tjplaysnow\discord\main\consolecommands\SpongeMain.java 8 | F:\Workspace\Spigot - Discord Bot API - JDA\src\main\java\com\tjplaysnow\discord\object\logger\LogLevel.java 9 | F:\Workspace\Spigot - Discord Bot API - JDA\src\main\java\com\tjplaysnow\discord\main\commands\package-info.java 10 | F:\Workspace\Spigot - Discord Bot API - JDA\src\main\java\com\tjplaysnow\discord\main\consolecommands\StopConsoleCommand.java 11 | F:\Workspace\Spigot - Discord Bot API - JDA\src\main\java\com\tjplaysnow\discord\config\package-info.java 12 | F:\Workspace\Spigot - Discord Bot API - JDA\src\main\java\com\tjplaysnow\discord\main\commands\MuteCommand.java 13 | F:\Workspace\Spigot - Discord Bot API - JDA\src\main\java\com\tjplaysnow\discord\object\package-info.java 14 | F:\Workspace\Spigot - Discord Bot API - JDA\src\main\java\com\tjplaysnow\discord\object\logger\Logger.java 15 | F:\Workspace\Spigot - Discord Bot API - JDA\src\main\java\com\tjplaysnow\discord\main\commands\HelpCommand.java 16 | F:\Workspace\Spigot - Discord Bot API - JDA\src\main\java\com\tjplaysnow\discord\main\commands\UnmuteCommand.java 17 | F:\Workspace\Spigot - Discord Bot API - JDA\src\main\java\com\tjplaysnow\discord\object\CommandSpigotManager.java 18 | F:\Workspace\Spigot - Discord Bot API - JDA\src\main\java\com\tjplaysnow\discord\object\ThreadHandle.java 19 | F:\Workspace\Spigot - Discord Bot API - JDA\src\main\java\com\tjplaysnow\discord\config\Config.java 20 | F:\Workspace\Spigot - Discord Bot API - JDA\src\main\java\com\tjplaysnow\discord\object\Bot.java 21 | F:\Workspace\Spigot - Discord Bot API - JDA\src\main\java\com\tjplaysnow\discord\main\PluginMain.java 22 | F:\Workspace\Spigot - Discord Bot API - JDA\src\main\java\com\tjplaysnow\discord\object\ProgramBot.java 23 | F:\Workspace\Spigot - Discord Bot API - JDA\src\main\java\com\tjplaysnow\discord\object\ProgramConsoleCommandManager.java 24 | F:\Workspace\Spigot - Discord Bot API - JDA\src\main\java\com\tjplaysnow\discord\object\ProgramThread.java 25 | F:\Workspace\Spigot - Discord Bot API - JDA\src\main\java\com\tjplaysnow\discord\object\CommandSpongerManager.java 26 | F:\Workspace\Spigot - Discord Bot API - JDA\src\main\java\com\tjplaysnow\discord\main\BungeeMain.java 27 | F:\Workspace\Spigot - Discord Bot API - JDA\src\main\java\com\tjplaysnow\discord\main\consolecommands\HelpConsoleCommand.java 28 | F:\Workspace\Spigot - Discord Bot API - JDA\src\main\java\com\tjplaysnow\discord\object\ReactionAddEvent.java 29 | F:\Workspace\Spigot - Discord Bot API - JDA\src\main\java\com\tjplaysnow\discord\object\CommandConsoleManager.java 30 | F:\Workspace\Spigot - Discord Bot API - JDA\src\main\java\com\tjplaysnow\discord\object\CommandBukkit.java 31 | F:\Workspace\Spigot - Discord Bot API - JDA\src\main\java\com\tjplaysnow\discord\object\ThreadSpigot.java 32 | F:\Workspace\Spigot - Discord Bot API - JDA\src\main\java\com\tjplaysnow\discord\object\ConsoleCommand.java 33 | F:\Workspace\Spigot - Discord Bot API - JDA\src\main\java\com\tjplaysnow\discord\object\Command.java 34 | F:\Workspace\Spigot - Discord Bot API - JDA\src\main\java\com\tjplaysnow\discord\object\ProgramCommand.java 35 | F:\Workspace\Spigot - Discord Bot API - JDA\src\main\java\com\tjplaysnow\discord\main\consolecommands\package-info.java 36 | --------------------------------------------------------------------------------