JDA command manager
JDA command manager.
Download
Replace the VERSION key below with the version shown above.
Gradle
dependencies {
implementation 'io.github.thexxiv:jda-command-manager:VERSION'
}
Maven
<dependency>
<groupId>io.github.thexxiv</groupId>
<artifactId>jda-command-manager</artifactId>
<version>VERSION</version>
</dependency>
Example
fun main() {
val manager = Manager("PREFIX")
.addCommand(Hello())
JDABuilder.createDefault("TOKEN")
.addEventListeners(Listener(manager))
.build().awaitReady()
}
class Hello : Command {
override fun run(args: List<String>, event: GuildMessageReceivedEvent) {
event.channel.sendMessage("Hi").queue()
}
override fun getCommand(): String {
return "hello"
}
}
License
JDA command manager is released under the MIT License.