Search in sources :

Example 11 with ICPlayer

use of com.loohp.interactivechat.objectholders.ICPlayer in project InteractiveChat by LOOHP.

the class SenderFinder method getSender.

public static Optional<ICPlayer> getSender(Component component, String messageKey) {
    ICPlayer keyPlayer = InteractiveChat.keyPlayer.get(messageKey);
    if (keyPlayer != null) {
        return Optional.of(keyPlayer);
    }
    String chat = PlainTextComponentSerializer.plainText().serialize(component);
    for (Entry<String, UUID> entry : InteractiveChat.messages.entrySet()) {
        String msg = entry.getKey();
        if (chat.contains(msg)) {
            UUID uuid = entry.getValue();
            Bukkit.getScheduler().runTaskLaterAsynchronously(InteractiveChat.plugin, () -> InteractiveChat.messages.remove(msg), 5);
            ICPlayer wplayer = ICPlayerFactory.getICPlayer(uuid);
            if (wplayer != null) {
                return Optional.of(wplayer);
            }
        }
    }
    String mostsimular = null;
    double currentsim = 0.5;
    for (Entry<String, UUID> entry : InteractiveChat.messages.entrySet()) {
        String msg = entry.getKey();
        double sim = CustomStringUtils.similarity(chat, msg);
        if (sim > currentsim) {
            mostsimular = msg;
            currentsim = sim;
        }
    }
    if (mostsimular != null) {
        UUID uuid = InteractiveChat.messages.get(mostsimular);
        String finalmostsimular = mostsimular;
        Bukkit.getScheduler().runTaskLaterAsynchronously(InteractiveChat.plugin, () -> InteractiveChat.messages.remove(finalmostsimular), 5);
        ICPlayer wplayer = ICPlayerFactory.getICPlayer(uuid);
        if (wplayer != null) {
            return Optional.of(wplayer);
        }
    }
    Map<String, UUID> names = new HashMap<>();
    ICPlayerFactory.getOnlineICPlayers().forEach((each) -> {
        names.put(ChatColorUtils.stripColor(each.getName()), each.getUniqueId());
        if (!ChatColorUtils.stripColor(each.getName()).equals(ChatColorUtils.stripColor(each.getDisplayName()))) {
            names.put(ChatColorUtils.stripColor(each.getDisplayName()), each.getUniqueId());
        }
    });
    Bukkit.getOnlinePlayers().forEach(each -> {
        List<String> list = InteractiveChatAPI.getNicknames(each.getUniqueId());
        for (String name : list) {
            names.put(ChatColorUtils.stripColor(name), each.getUniqueId());
        }
    });
    UUID currentplayer = null;
    int currentpos = 99999;
    for (Entry<String, UUID> entry : names.entrySet()) {
        int pos = chat.toLowerCase().indexOf(entry.getKey().toLowerCase());
        if (pos >= 0 && pos < currentpos) {
            currentpos = pos;
            currentplayer = entry.getValue();
        }
    }
    if (currentplayer != null) {
        ICPlayer wplayer = ICPlayerFactory.getICPlayer(currentplayer);
        if (wplayer != null) {
            return Optional.of(wplayer);
        }
    }
    return Optional.empty();
}
Also used : ICPlayer(com.loohp.interactivechat.objectholders.ICPlayer) HashMap(java.util.HashMap) UUID(java.util.UUID)

Example 12 with ICPlayer

use of com.loohp.interactivechat.objectholders.ICPlayer in project InteractiveChat by LOOHP.

the class CustomPlaceholderDisplay method process.

public static Component process(Component component, Optional<ICPlayer> optplayer, Player reciever, Collection<ICPlaceholder> placeholderList, long unix) {
    for (ICPlaceholder icplaceholder : placeholderList) {
        if (icplaceholder.isBuildIn()) {
            continue;
        }
        CustomPlaceholder cp = (CustomPlaceholder) icplaceholder;
        ICPlayer parseplayer = (cp.getParsePlayer().equals(ParsePlayer.SENDER) && optplayer.isPresent()) ? optplayer.get() : ICPlayerFactory.getICPlayer(reciever);
        if (InteractiveChat.useCustomPlaceholderPermissions && optplayer.isPresent()) {
            ICPlayer sender = optplayer.get();
            if (!PlayerUtils.hasPermission(sender.getUniqueId(), cp.getPermission(), true, 5)) {
                continue;
            }
        }
        String placeholder = cp.getKeyword().pattern();
        placeholder = (cp.getParseKeyword()) ? PlaceholderParser.parse(parseplayer, placeholder) : placeholder;
        long cooldown = cp.getCooldown();
        boolean hoverEnabled = cp.getHover().isEnabled();
        String hoverText = cp.getHover().getText();
        boolean clickEnabled = cp.getClick().isEnabled();
        ClickEventAction clickAction = cp.getClick().getAction();
        String clickValue = cp.getClick().getValue();
        boolean replaceEnabled = cp.getReplace().isEnabled();
        String replaceText = cp.getReplace().getReplaceText();
        component = processCustomPlaceholder(parseplayer, Pattern.compile(placeholder), cooldown, hoverEnabled, hoverText, clickEnabled, clickAction, clickValue, replaceEnabled, replaceText, component, optplayer, unix);
    }
    if (InteractiveChat.t && WebData.getInstance() != null) {
        for (CustomPlaceholder cp : WebData.getInstance().getSpecialPlaceholders()) {
            ICPlayer parseplayer = (cp.getParsePlayer().equals(ParsePlayer.SENDER) && optplayer.isPresent()) ? optplayer.get() : ICPlayerFactory.getICPlayer(reciever);
            String placeholder = cp.getKeyword().pattern();
            placeholder = (cp.getParseKeyword()) ? PlaceholderParser.parse(parseplayer, placeholder) : placeholder;
            long cooldown = cp.getCooldown();
            boolean hoverEnabled = cp.getHover().isEnabled();
            String hoverText = cp.getHover().getText();
            boolean clickEnabled = cp.getClick().isEnabled();
            ClickEventAction clickAction = cp.getClick().getAction();
            String clickValue = cp.getClick().getValue();
            boolean replaceEnabled = cp.getReplace().isEnabled();
            String replaceText = cp.getReplace().getReplaceText();
            component = processCustomPlaceholder(parseplayer, Pattern.compile(placeholder), cooldown, hoverEnabled, hoverText, clickEnabled, clickAction, clickValue, replaceEnabled, replaceText, component, optplayer, unix);
        }
    }
    return component;
}
Also used : ICPlayer(com.loohp.interactivechat.objectholders.ICPlayer) ICPlaceholder(com.loohp.interactivechat.objectholders.ICPlaceholder) CustomPlaceholder(com.loohp.interactivechat.objectholders.CustomPlaceholder) ClickEventAction(com.loohp.interactivechat.objectholders.CustomPlaceholder.ClickEventAction)

Example 13 with ICPlayer

use of com.loohp.interactivechat.objectholders.ICPlayer in project InteractiveChat by LOOHP.

the class ItemDisplay method process.

@SuppressWarnings("deprecation")
public static Component process(Component component, Optional<ICPlayer> optplayer, Player receiver, long unix) throws Exception {
    String plain = InteractiveChatComponentSerializer.plainText().serialize(component);
    if (InteractiveChat.itemPlaceholder.matcher(plain).find()) {
        String regex = InteractiveChat.itemPlaceholder.pattern();
        if (InteractiveChat.bungeecordMode && optplayer.isPresent() && optplayer.get().isLocal()) {
            ICPlayer player = optplayer.get();
            ItemStack[] equipment;
            if (InteractiveChat.version.isOld()) {
                equipment = new ItemStack[] { player.getEquipment().getHelmet(), player.getEquipment().getChestplate(), player.getEquipment().getLeggings(), player.getEquipment().getBoots(), player.getEquipment().getItemInHand() };
            } else {
                equipment = new ItemStack[] { player.getEquipment().getHelmet(), player.getEquipment().getChestplate(), player.getEquipment().getLeggings(), player.getEquipment().getBoots(), player.getEquipment().getItemInMainHand(), player.getEquipment().getItemInOffHand() };
            }
            try {
                BungeeMessageSender.forwardEquipment(unix, player.getUniqueId(), player.isRightHanded(), player.getSelectedSlot(), player.getExperienceLevel(), equipment);
            } catch (IOException e) {
                e.printStackTrace();
            }
        }
        if (optplayer.isPresent()) {
            ICPlayer player = optplayer.get();
            if (PlayerUtils.hasPermission(player.getUniqueId(), "interactivechat.module.item", true, 5)) {
                Component alternativeHover = null;
                if (!InteractiveChat.itemHover && !InteractiveChat.itemAlternativeHoverMessage.isEmpty()) {
                    alternativeHover = LegacyComponentSerializer.legacySection().deserialize(InteractiveChat.itemAlternativeHoverMessage);
                }
                Component itemComponent = ComponentFlattening.flatten(createItemDisplay(player, receiver, component, unix, InteractiveChat.itemHover, alternativeHover));
                component = ComponentReplacing.replace(component, regex, true, itemComponent);
            }
        } else {
            Component message;
            if (InteractiveChat.playerNotFoundReplaceEnable) {
                message = LegacyComponentSerializer.legacySection().deserialize(InteractiveChat.playerNotFoundReplaceText.replace("{Placeholder}", InteractiveChat.itemName));
            } else {
                message = Component.text(InteractiveChat.itemName);
            }
            if (InteractiveChat.playerNotFoundHoverEnable && InteractiveChat.itemHover) {
                message = message.hoverEvent(HoverEvent.showText(LegacyComponentSerializer.legacySection().deserialize(InteractiveChat.playerNotFoundHoverText.replace("{Placeholder}", InteractiveChat.itemName))));
            }
            if (InteractiveChat.playerNotFoundClickEnable) {
                String clickValue = ChatColorUtils.translateAlternateColorCodes('&', InteractiveChat.playerNotFoundClickValue.replace("{Placeholder}", InteractiveChat.itemName));
                message = message.clickEvent(ClickEvent.clickEvent(ClickEvent.Action.valueOf(InteractiveChat.playerNotFoundClickAction), clickValue));
            }
            component = ComponentReplacing.replace(component, regex, true, message);
        }
    }
    return component;
}
Also used : ICPlayer(com.loohp.interactivechat.objectholders.ICPlayer) OfflineICPlayer(com.loohp.interactivechat.objectholders.OfflineICPlayer) IOException(java.io.IOException) ItemStack(org.bukkit.inventory.ItemStack) Component(net.kyori.adventure.text.Component)

Example 14 with ICPlayer

use of com.loohp.interactivechat.objectholders.ICPlayer in project InteractiveChat by LOOHP.

the class PlayernameDisplay method processPlayer.

private static Component processPlayer(String placeholder, ICPlayer player, Optional<ICPlayer> sender, Player receiver, Component component, Set<HoverEvent<?>> doNotReplace, long unix) {
    String plain = InteractiveChatComponentSerializer.plainText().serialize(component);
    if (InteractiveChat.usePlayerNameCaseSensitive) {
        if (!plain.contains(placeholder)) {
            return component;
        }
    } else {
        if (!plain.toLowerCase().contains(placeholder.toLowerCase())) {
            return component;
        }
    }
    HoverEvent<?> hoverEvent;
    ClickEvent clickEvent;
    if (InteractiveChat.usePlayerNameHoverEnable) {
        String playertext = ChatColorUtils.translateAlternateColorCodes('&', PlaceholderParser.parse(player, InteractiveChat.usePlayerNameHoverText));
        hoverEvent = HoverEvent.showText(LegacyComponentSerializer.legacySection().deserialize(playertext));
    } else {
        hoverEvent = null;
    }
    if (InteractiveChat.usePlayerNameClickEnable) {
        String playertext = PlaceholderParser.parse(player, InteractiveChat.usePlayerNameClickValue);
        clickEvent = ClickEvent.clickEvent(ClickEvent.Action.valueOf(InteractiveChat.usePlayerNameClickAction), playertext);
    } else {
        clickEvent = null;
    }
    String regex = InteractiveChat.usePlayerNameCaseSensitive ? CustomStringUtils.escapeMetaCharacters(placeholder) : "(?i)" + CustomStringUtils.escapeMetaCharacters(placeholder);
    component = ComponentReplacing.replace(component, regex, true, (result, replaced) -> {
        List<Component> children = new ArrayList<>();
        boolean doNotReplaceFlag = false;
        for (Component c : replaced) {
            if (doNotReplace.contains(c.hoverEvent())) {
                doNotReplaceFlag = true;
                break;
            }
            Component edited = c;
            if (hoverEvent != null && (InteractiveChat.usePlayerNameOverrideHover || edited.hoverEvent() == null)) {
                edited = edited.hoverEvent(hoverEvent);
            }
            if (clickEvent != null && (InteractiveChat.usePlayerNameOverrideClick || edited.clickEvent() == null)) {
                edited = edited.clickEvent(clickEvent);
            }
            children.add(edited);
        }
        if (doNotReplaceFlag) {
            return Component.empty().children(replaced);
        }
        return Component.empty().children(children);
    });
    List<Component> children = new ArrayList<>(component.children());
    for (int i = 0; i < children.size(); i++) {
        Component child = children.get(i);
        if (child instanceof TranslatableComponent) {
            TranslatableComponent trans = (TranslatableComponent) child;
            List<Component> withs = new ArrayList<>(trans.args());
            withs.replaceAll(with -> processPlayer(placeholder, player, sender, receiver, with, doNotReplace, unix));
            trans = trans.args(withs);
            children.set(i, trans);
        }
    }
    doNotReplace.add(hoverEvent);
    return ComponentCompacting.optimize(component.children(children));
}
Also used : VanishUtils(com.loohp.interactivechat.utils.VanishUtils) ComponentReplacing(com.loohp.interactivechat.utils.ComponentReplacing) ComponentCompacting(com.loohp.interactivechat.utils.ComponentCompacting) ReplaceTextBundle(com.loohp.interactivechat.objectholders.ReplaceTextBundle) Random(java.util.Random) ClickEvent(net.kyori.adventure.text.event.ClickEvent) Player(org.bukkit.entity.Player) TranslatableComponent(net.kyori.adventure.text.TranslatableComponent) ArrayList(java.util.ArrayList) EventHandler(org.bukkit.event.EventHandler) HashSet(java.util.HashSet) ICPlayer(com.loohp.interactivechat.objectholders.ICPlayer) InteractiveChatComponentSerializer(com.loohp.interactivechat.utils.InteractiveChatComponentSerializer) AtomicInteger(java.util.concurrent.atomic.AtomicInteger) Component(net.kyori.adventure.text.Component) CollectionUtils(com.loohp.interactivechat.utils.CollectionUtils) LegacyComponentSerializer(net.kyori.adventure.text.serializer.legacy.LegacyComponentSerializer) LinkedHashSet(java.util.LinkedHashSet) Bukkit(org.bukkit.Bukkit) Listener(org.bukkit.event.Listener) PlayerLoginEvent(org.bukkit.event.player.PlayerLoginEvent) Collection(java.util.Collection) Set(java.util.Set) InteractiveChat(com.loohp.interactivechat.InteractiveChat) List(java.util.List) EventPriority(org.bukkit.event.EventPriority) ICPlayerFactory(com.loohp.interactivechat.objectholders.ICPlayerFactory) ChatColorUtils(com.loohp.interactivechat.utils.ChatColorUtils) PlayerQuitEvent(org.bukkit.event.player.PlayerQuitEvent) CustomStringUtils(com.loohp.interactivechat.utils.CustomStringUtils) Optional(java.util.Optional) Comparator(java.util.Comparator) PlaceholderParser(com.loohp.interactivechat.utils.PlaceholderParser) HoverEvent(net.kyori.adventure.text.event.HoverEvent) TranslatableComponent(net.kyori.adventure.text.TranslatableComponent) ClickEvent(net.kyori.adventure.text.event.ClickEvent) ArrayList(java.util.ArrayList) ArrayList(java.util.ArrayList) List(java.util.List) TranslatableComponent(net.kyori.adventure.text.TranslatableComponent) Component(net.kyori.adventure.text.Component)

Example 15 with ICPlayer

use of com.loohp.interactivechat.objectholders.ICPlayer in project InteractiveChat by LOOHP.

the class ProcessExternalMessage method processAndRespond0.

public String processAndRespond0(Player receiver, String json) throws Exception {
    Component component = InteractiveChatComponentSerializer.gson().deserialize(json);
    Component originalComponent = component;
    try {
        if (LegacyComponentSerializer.legacySection().serialize(component).isEmpty()) {
            return json;
        }
    } catch (Exception e) {
        return json;
    }
    if ((InteractiveChat.version.isOld()) && JsonUtils.containsKey(InteractiveChatComponentSerializer.gson().serialize(component), "translate")) {
        return json;
    }
    Optional<ICPlayer> sender = Optional.empty();
    String rawMessageKey = InteractiveChatComponentSerializer.plainText().serializeOr(component, "");
    InteractiveChat.keyTime.putIfAbsent(rawMessageKey, System.currentTimeMillis());
    Long timeKey = InteractiveChat.keyTime.get(rawMessageKey);
    long unix = timeKey == null ? System.currentTimeMillis() : timeKey;
    ProcessSenderResult commandSender = ProcessCommands.process(component);
    if (commandSender.getSender() != null) {
        sender = Optional.ofNullable(ICPlayerFactory.getICPlayer(commandSender.getSender()));
    }
    ProcessSenderResult chatSender = null;
    if (!sender.isPresent()) {
        if (InteractiveChat.useAccurateSenderFinder) {
            chatSender = ProcessAccurateSender.process(component);
            if (chatSender.getSender() != null) {
                sender = Optional.ofNullable(ICPlayerFactory.getICPlayer(chatSender.getSender()));
            }
        }
    }
    if (!sender.isPresent() && !InteractiveChat.useAccurateSenderFinder) {
        sender = SenderFinder.getSender(component, rawMessageKey);
    }
    component = commandSender.getComponent();
    if (chatSender != null) {
        component = chatSender.getComponent();
    }
    String text = LegacyComponentSerializer.legacySection().serialize(component);
    if (InteractiveChat.messageToIgnore.stream().anyMatch(each -> text.matches(each))) {
        return json;
    }
    if (sender.isPresent()) {
        InteractiveChat.keyPlayer.put(rawMessageKey, sender.get());
    }
    String server;
    if (sender.isPresent() && !sender.get().isLocal()) {
        try {
            TimeUnit.MILLISECONDS.sleep(InteractiveChat.remoteDelay);
        } catch (InterruptedException e) {
            e.printStackTrace();
        }
        server = sender.get().getServer();
    } else {
        server = ICPlayer.LOCAL_SERVER_REPRESENTATION;
    }
    component = ComponentModernizing.modernize(component);
    component = ComponentReplacing.replace(component, Registry.ID_PATTERN.pattern(), Component.empty());
    if (InteractiveChat.usePlayerName) {
        component = PlayernameDisplay.process(component, sender, receiver, unix);
    }
    if (InteractiveChat.allowMention && sender.isPresent()) {
        PlayerData data = InteractiveChat.playerDataManager.getPlayerData(receiver);
        if (data == null || !data.isMentionDisabled()) {
            component = MentionDisplay.process(component, receiver, sender.get(), unix, !Bukkit.isPrimaryThread());
        }
    }
    component = ComponentReplacing.replace(component, Registry.MENTION_TAG_CONVERTER.getReversePattern().pattern(), true, (result, components) -> {
        return LegacyComponentSerializer.legacySection().deserialize(result.group(2));
    });
    Collection<ICPlaceholder> serverPlaceholderList = InteractiveChat.remotePlaceholderList.get(server);
    if (server.equals(ICPlayer.LOCAL_SERVER_REPRESENTATION) || serverPlaceholderList == null) {
        serverPlaceholderList = InteractiveChat.placeholderList.values();
    }
    component = CustomPlaceholderDisplay.process(component, sender, receiver, serverPlaceholderList, unix);
    if (InteractiveChat.useItem) {
        component = ItemDisplay.process(component, sender, receiver, unix);
    }
    if (InteractiveChat.useInventory) {
        component = InventoryDisplay.process(component, sender, receiver, unix);
    }
    if (InteractiveChat.useEnder) {
        component = EnderchestDisplay.process(component, sender, receiver, unix);
    }
    if (InteractiveChat.clickableCommands) {
        component = CommandsDisplay.process(component);
    }
    if (InteractiveChat.version.isNewerOrEqualTo(MCVersion.V1_16) && InteractiveChat.fontTags) {
        if (!sender.isPresent() || (sender.isPresent() && PlayerUtils.hasPermission(sender.get().getUniqueId(), "interactivechat.customfont.translate", true, 5))) {
            component = ComponentFont.parseFont(component);
        }
    }
    Bukkit.getScheduler().runTaskLater(InteractiveChat.plugin, () -> {
        InteractiveChat.keyTime.remove(rawMessageKey);
        InteractiveChat.keyPlayer.remove(rawMessageKey);
    }, 5);
    String newJson = InteractiveChatComponentSerializer.gson().serialize(component);
    if (InteractiveChat.sendOriginalIfTooLong && newJson.length() > InteractiveChat.packetStringMaxLength) {
        String originalJson = InteractiveChatComponentSerializer.gson().serialize(originalComponent);
        if (originalJson.length() > InteractiveChat.packetStringMaxLength) {
            return "{\"text\":\"\"}";
        } else {
            return originalJson;
        }
    }
    return newJson;
}
Also used : Plugin(org.bukkit.plugin.Plugin) ComponentReplacing(com.loohp.interactivechat.utils.ComponentReplacing) MCVersion(com.loohp.interactivechat.utils.MCVersion) PlayerUtils(com.loohp.interactivechat.utils.PlayerUtils) CustomPlaceholder(com.loohp.interactivechat.objectholders.CustomPlaceholder) InteractiveChatAPI(com.loohp.interactivechat.api.InteractiveChatAPI) PlayerData(com.loohp.interactivechat.data.PlayerDataManager.PlayerData) WebData(com.loohp.interactivechat.objectholders.WebData) Registry(com.loohp.interactivechat.registry.Registry) JsonUtils(com.loohp.interactivechat.utils.JsonUtils) Player(org.bukkit.entity.Player) ComponentModernizing(com.loohp.interactivechat.utils.ComponentModernizing) ICPlayer(com.loohp.interactivechat.objectholders.ICPlayer) ComponentFont(com.loohp.interactivechat.utils.ComponentFont) InteractiveChatComponentSerializer(com.loohp.interactivechat.utils.InteractiveChatComponentSerializer) Matcher(java.util.regex.Matcher) Component(net.kyori.adventure.text.Component) ICPlaceholder(com.loohp.interactivechat.objectholders.ICPlaceholder) LegacyComponentSerializer(net.kyori.adventure.text.serializer.legacy.LegacyComponentSerializer) Method(java.lang.reflect.Method) ItemStackUtils(com.loohp.interactivechat.utils.ItemStackUtils) Material(org.bukkit.Material) ChatColor(net.md_5.bungee.api.ChatColor) Bukkit(org.bukkit.Bukkit) Collection(java.util.Collection) RarityUtils(com.loohp.interactivechat.utils.RarityUtils) UUID(java.util.UUID) Field(java.lang.reflect.Field) ItemStack(org.bukkit.inventory.ItemStack) InteractiveChat(com.loohp.interactivechat.InteractiveChat) TimeUnit(java.util.concurrent.TimeUnit) ICPlayerFactory(com.loohp.interactivechat.objectholders.ICPlayerFactory) ChatColorUtils(com.loohp.interactivechat.utils.ChatColorUtils) CustomStringUtils(com.loohp.interactivechat.utils.CustomStringUtils) Optional(java.util.Optional) Pattern(java.util.regex.Pattern) PlaceholderParser(com.loohp.interactivechat.utils.PlaceholderParser) ProcessSenderResult(com.loohp.interactivechat.objectholders.ProcessSenderResult) ICPlayer(com.loohp.interactivechat.objectholders.ICPlayer) ProcessSenderResult(com.loohp.interactivechat.objectholders.ProcessSenderResult) ICPlaceholder(com.loohp.interactivechat.objectholders.ICPlaceholder) Component(net.kyori.adventure.text.Component) PlayerData(com.loohp.interactivechat.data.PlayerDataManager.PlayerData)

Aggregations

ICPlayer (com.loohp.interactivechat.objectholders.ICPlayer)22 Player (org.bukkit.entity.Player)11 UUID (java.util.UUID)10 Component (net.kyori.adventure.text.Component)10 InteractiveChat (com.loohp.interactivechat.InteractiveChat)9 ICPlayerFactory (com.loohp.interactivechat.objectholders.ICPlayerFactory)9 ArrayList (java.util.ArrayList)9 List (java.util.List)9 Bukkit (org.bukkit.Bukkit)9 ICPlaceholder (com.loohp.interactivechat.objectholders.ICPlaceholder)7 ChatColorUtils (com.loohp.interactivechat.utils.ChatColorUtils)7 ComponentReplacing (com.loohp.interactivechat.utils.ComponentReplacing)7 InteractiveChatComponentSerializer (com.loohp.interactivechat.utils.InteractiveChatComponentSerializer)7 PlaceholderParser (com.loohp.interactivechat.utils.PlaceholderParser)7 HashMap (java.util.HashMap)7 Optional (java.util.Optional)7 ItemStack (org.bukkit.inventory.ItemStack)7 InteractiveChatAPI (com.loohp.interactivechat.api.InteractiveChatAPI)6 CustomStringUtils (com.loohp.interactivechat.utils.CustomStringUtils)6 IOException (java.io.IOException)6