Skip to content

Commit

Permalink
make PlayerProvider#provideSuggestions static via suggest()
Browse files Browse the repository at this point in the history
  • Loading branch information
Badbird5907 committed Jan 5, 2024
1 parent 5859104 commit e6376b3
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 17 deletions.
8 changes: 1 addition & 7 deletions Commander-Bukkit/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@

plugins {
id("java")
id("io.freefair.lombok") version "8.4"
}

group = "net.octopvp"
Expand All @@ -46,13 +47,6 @@ dependencies {
testImplementation("org.junit.jupiter:junit-jupiter-api:5.9.2")
testRuntimeOnly("org.junit.jupiter:junit-jupiter-engine:5.9.2")

//Lombok
compileOnly("org.projectlombok:lombok:1.18.26")
annotationProcessor("org.projectlombok:lombok:1.18.26")

testCompileOnly("org.projectlombok:lombok:1.18.26")
testAnnotationProcessor("org.projectlombok:lombok:1.18.26")

implementation("org.reflections:reflections:0.10.2")
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,11 @@ public Player provideDefault(CommandContext context, CommandInfo commandInfo, Pa
}

@Override
public List<String> provideSuggestions(String input, String lastArg, CoreCommandSender s) {
public List<String> provideSuggestions(String input, String lastArg, CoreCommandSender s) {
return suggest(input, s);
}

public static List<String> suggest(String input, CoreCommandSender s) {
List<String> list = new ArrayList<>();
BukkitCommandSenderImpl sender = (BukkitCommandSenderImpl) s;
if (sender instanceof Player) {
Expand Down
9 changes: 2 additions & 7 deletions Commander-Core/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,11 @@

plugins {
id("java")
id("io.freefair.lombok") version "8.4"
}

group = "net.octopvp"
version = "0.0.7-REL"
version = "0.0.8-REL"

repositories {
mavenCentral()
Expand All @@ -37,12 +38,6 @@ dependencies {
testImplementation("org.junit.jupiter:junit-jupiter-api:5.9.2")
testRuntimeOnly("org.junit.jupiter:junit-jupiter-engine:5.9.2")

compileOnly("org.projectlombok:lombok:1.18.26")
annotationProcessor("org.projectlombok:lombok:1.18.26")

testCompileOnly("org.projectlombok:lombok:1.18.26")
testAnnotationProcessor("org.projectlombok:lombok:1.18.26")

implementation("org.reflections:reflections:0.10.2")
}

Expand Down
2 changes: 1 addition & 1 deletion Commander-JDA/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ plugins {
}

group = "net.octopvp"
version = "0.0.7-REL"
version = "0.0.8-REL"

repositories {
mavenCentral()
Expand Down
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
@@ -1 +1 @@
version=0.0.7-REL
version=0.0.8-REL

0 comments on commit e6376b3

Please sign in to comment.