creayun fix mabe mabe

This commit is contained in:
Chayapak 2023-06-23 19:06:44 +07:00
parent c102214a4b
commit 13b8831d0e
4 changed files with 6 additions and 3 deletions

View file

@ -114,6 +114,7 @@ public class Configuration {
@Getter public int port;
@Getter public String username;
@Getter public boolean kaboom = false;
@Getter public boolean creayun = false;
@Getter public String serverName;
@Getter @Setter public boolean useCore = true;
@Getter @Setter public boolean useChat = false;

View file

@ -29,7 +29,7 @@ public class CreayunChatParser implements ChatParser {
public PlayerMessage parse (Component message) {
final String stringified = ComponentUtilities.stringify(message);
if (stringified.length() > 512) return null; // will this fix the fard problem?
if (bot.options().creayun()) return null;
final Matcher matcher = PATTERN.matcher(stringified);

View file

@ -137,7 +137,7 @@ public class PlayersPlugin extends Bot.Listener {
object.addProperty("uuid", target.profile().getIdAsString());
object.add("lastSeen", new JsonObject());
playersObject.add(target.profile().getName(), object);
playersObject.add(bot.options().creayun() ? target.profile().getName().replaceAll("§.", "") : target.profile().getName(), object);
PersistentDataUtilities.put("players", playersObject);
} else for (Listener listener : listeners) { listener.playerUnVanished(target); }

View file

@ -83,7 +83,8 @@ selfCare:
username: true # MIGHT cause problem(s) if set to false (not tested,.,.)
bots:
# username - optional, if not specified it will just use a random username
# kaboom - defaults to false mabe
# kaboom - defaults to false
# creayun - same as kaboom
# serverName - name it whatever you like, it will be used as server name in trusted broadcast and in console
# useCore - if enabled it just sends the command using chat instead of using core. recommended to enable useChat too when this is enabled
# useChat - when the bot tellraws it will chat instead of using the core to run tellraw
@ -94,6 +95,7 @@ bots:
port: 25565
username: 'ChomeNS_Bot'
kaboom: false
creayun: false
serverName: 'Localhost'
useCore: true
useChat: false