Skip to content

A light and fast command library for making bots in JDA.

Notifications You must be signed in to change notification settings

comboardent/JDA-Command

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

30 Commits
 
 
 
 
 
 
 
 

Repository files navigation

JDA-Command

Small, powerful and lightweight command library for JDA.

This command library was built to help people make amazing bots within JDA!
It uses maven for dependency management because I am an XML fanboy,
but I also find gradle cool and use it for some projects.
Thank you for the amazing people at JDA for inspiring the creation of this library,
go and check them out at https://github.com/DV8FromTheWorld/JDA/

Examples:

This is a command which echoes the input of the user if their sentence begins with the bot's prefix and echo, repeat or copy.

If the input was bot, echo hello! the output would be hello! (If the prefix was bot, )

@CommandDescription(name = "Echo", triggers = {"echo", "repeat", "copy"}, 
    description = "This command echoes what you say!", 
args = 1)
public class Echo implements Command {

    @Override
    public void execute(Message message, String args) {
        message.getChannel().sendMessage(args).queue();
    }
}

For more detailed examples please see the example repository here.

Bots using JDA-Command:


Examples marked with a * may not be suitable for beginners.

Use JDA-Command in your projects today!

The current promoted version is 1.0.7

Maven
<!--Repository for JDA-Command-->
<repository>
    <id>jitpack.io</id>
    <name>jitpack</name>
    <url>https://jitpack.io</url>
</repository>
<!--Repository for JDA-->
<repository>
    <id>jcenter</id>
    <name>jcenter-bintray</name>
    <url>http://jcenter.bintray.com</url>
</repository>
<!--Dependency for JDA-Command-->
<dependency>
   <groupId>com.github.Comportment</groupId>
   <artifactId>JDA-Command</artifactId>
   <version>1.0.7</version>
</dependency>
<!--Dependency for JDA-->
<dependency>
    <groupId>net.dv8tion</groupId>
    <artifactId>JDA</artifactId>
    <version>3.1.0_206</version>
</dependency>
Gradle
repositories {
    //This repository is needed for JDA.
    jcenter()
    //Make sure this repository is last.
    maven { url 'https://jitpack.io' }
}

dependencies {
    //JDA-Command dependency
    compile 'com.github.Comportment:JDA-Command:1.0.7'
    //JDA dependency
    compile group: 'net.dv8tion', name: 'JDA', version: '3.1.0_206'
}

About

A light and fast command library for making bots in JDA.

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages