diff --git a/src/api/java/baritone/api/utils/command/defaults/ClickCommand.java b/src/api/java/baritone/api/utils/command/defaults/ClickCommand.java new file mode 100644 index 000000000..120b58674 --- /dev/null +++ b/src/api/java/baritone/api/utils/command/defaults/ClickCommand.java @@ -0,0 +1,55 @@ +/* + * This file is part of Baritone. + * + * Baritone is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * Baritone is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public License + * along with Baritone. If not, see . + */ + +package baritone.api.utils.command.defaults; + +import baritone.api.Settings; +import baritone.api.utils.command.Command; +import baritone.api.utils.command.helpers.arguments.ArgConsumer; + +import java.util.List; +import java.util.stream.Stream; + +import static java.util.Arrays.asList; + +public class ClickCommand extends Command { + public ClickCommand() { + super("click", "Open click"); + } + + @Override + protected void executed(String label, ArgConsumer args, Settings settings) { + args.requireMax(0); + baritone.openClick(); + logDirect("aight dude"); + } + + @Override + protected Stream tabCompleted(String label, ArgConsumer args, Settings settings) { + return Stream.empty(); + } + + @Override + public List getLongDesc() { + return asList( + "Opens click dude", + "", + "Usage:", + "> click" + ); + } +} diff --git a/src/api/java/baritone/api/utils/command/defaults/DefaultCommands.java b/src/api/java/baritone/api/utils/command/defaults/DefaultCommands.java index 18e0bc9d7..fac6422ff 100644 --- a/src/api/java/baritone/api/utils/command/defaults/DefaultCommands.java +++ b/src/api/java/baritone/api/utils/command/defaults/DefaultCommands.java @@ -59,6 +59,7 @@ public class DefaultCommands { new ExploreCommand(), new BlacklistCommand(), new FindCommand(), - new MineCommand() + new MineCommand(), + new ClickCommand() )); } diff --git a/src/api/java/baritone/api/utils/command/defaults/PauseResumeCommands.java b/src/api/java/baritone/api/utils/command/defaults/PauseResumeCommands.java index b0d2e1b58..ff8bc783c 100644 --- a/src/api/java/baritone/api/utils/command/defaults/PauseResumeCommands.java +++ b/src/api/java/baritone/api/utils/command/defaults/PauseResumeCommands.java @@ -19,8 +19,7 @@ import static java.util.Arrays.asList; * * This thing is scoped to hell, private so far you can't even access it using reflection, because you AREN'T SUPPOSED * TO USE THIS to pause and resume Baritone. Make your own process that returns {@link PathingCommandType#REQUEST_PAUSE - * REQUEST_PAUSE} - * as needed. + * REQUEST_PAUSE} as needed. */ public class PauseResumeCommands { public static Command pauseCommand;