Make the prefix optional
This commit is contained in:
parent
93de55318f
commit
71ce9cd901
@ -241,6 +241,11 @@ public class Settings {
|
||||
*/
|
||||
public Setting<Boolean> pathThroughCachedOnly = new Setting<>(false);
|
||||
|
||||
/**
|
||||
* Whether or not to use the "#" command prefix
|
||||
*/
|
||||
public Setting<Boolean> prefix = new Setting<>(false);
|
||||
|
||||
public final Map<String, Setting<?>> byLowerName;
|
||||
public final List<Setting<?>> allSettings;
|
||||
|
||||
|
@ -55,7 +55,7 @@ public class ExampleBaritoneControl extends Behavior {
|
||||
return;
|
||||
}
|
||||
String msg = event.getMessage();
|
||||
if (!msg.startsWith("#"))
|
||||
if (Baritone.settings().prefix.get() && !msg.startsWith("#"))
|
||||
return;
|
||||
|
||||
msg = msg.substring(1);
|
||||
|
Loading…
Reference in New Issue
Block a user