Add tab completion for gamemode flag

This commit is contained in:
NotMyFault 2021-04-02 23:20:39 +02:00
parent 600d38d3e2
commit b02177e1d0
No known key found for this signature in database
GPG Key ID: 158F5701A6AAD00C

View File

@ -32,6 +32,9 @@ import com.sk89q.worldedit.world.gamemode.GameMode;
import com.sk89q.worldedit.world.gamemode.GameModes;
import org.checkerframework.checker.nullness.qual.NonNull;
import java.util.Arrays;
import java.util.Collection;
public class GamemodeFlag extends PlotFlag<GameMode, GamemodeFlag> {
public static final GameMode DEFAULT = new GameMode("default");
@ -115,4 +118,9 @@ public class GamemodeFlag extends PlotFlag<GameMode, GamemodeFlag> {
}
}
@Override
public Collection<String> getTabCompletions() {
return Arrays.asList("survival", "creative", "adventure", "spectator");
}
}