Skip to content

Latest commit

 

History

History
85 lines (76 loc) · 3.47 KB

README.md

File metadata and controls

85 lines (76 loc) · 3.47 KB
banner

☄️ LiteCommands dependency Donate Discord OSCS Status

Command framework for Velocity, Bukkit, Paper, BungeeCord and your other implementations.

Helpful links:

Panda Repository (Maven or Gradle) ❤️

<repository>
  <id>panda-repository</id>
  <url>https://repo.panda-lang.org/releases</url>
</repository>
maven { url "https://repo.panda-lang.org/releases" }

Dependencies (Maven or Gradle)

Framework Core

<dependency>
    <groupId>dev.rollczi.litecommands</groupId>
    <artifactId>core</artifactId>
    <version>2.3.4</version>
</dependency>
implementation 'dev.rollczi.litecommands:core:2.3.4'

First Simple Command

/helloworld <text...>

@Section(route = "helloworld")
@Permission("dev.rollczi.helloworld")
public class HelloWorldCommand {

    @Execute
    @Min(1)
    public void execute(LiteSender sender, String[] args) {
        sender.sendMessage(String.join(" ", args));
    }
    
    @Execute(route = "subcommand")
    public void execute(LiteSender sender, @Arg String text) {
        sender.sendMessage(text);
    }

}

Register your first command in plugin main class: (in this case for Velocity)

this.liteCommands = LiteVelocityFactory.builder(proxy)
        .command(HelloWorldCommand.class)
        .register();

Velocity Extension Dependencies (Maven or Gradle)

Add this to your dependencies if you want use ready-made implementation for velocity.

<dependency>
    <groupId>dev.rollczi.litecommands</groupId>
    <artifactId>velocity</artifactId>
    <version>2.3.4</version>
</dependency>
implementation 'dev.rollczi.litecommands:velocity:2.3.4'

All extensions:

Other examples:

See (Important dependencies used)