mirror of
https://github.com/Xiao-MoMi/Custom-Nameplates.git
synced 2025-12-19 15:09:23 +00:00
2.4.8.1
This commit is contained in:
@@ -7,7 +7,7 @@ plugins {
|
||||
|
||||
allprojects {
|
||||
|
||||
version = "2.4.8"
|
||||
version = "2.4.8.1"
|
||||
|
||||
apply<JavaPlugin>()
|
||||
apply(plugin = "java")
|
||||
|
||||
@@ -85,10 +85,12 @@ public class ActionBarManagerImpl implements ActionBarManager, Listener {
|
||||
}
|
||||
|
||||
Bukkit.getPluginManager().registerEvents(this, plugin);
|
||||
if (CNConfig.catchOtherActionBar) {
|
||||
if (actionBarListener != null) ProtocolLibrary.getProtocolManager().addPacketListener(actionBarListener);
|
||||
if (systemChatListener != null) ProtocolLibrary.getProtocolManager().addPacketListener(systemChatListener);
|
||||
if (chatMessageListener != null) ProtocolLibrary.getProtocolManager().addPacketListener(chatMessageListener);
|
||||
}
|
||||
}
|
||||
|
||||
public void unload() {
|
||||
for (ActionBarReceiver receiver : receiverMap.values()) {
|
||||
|
||||
@@ -88,6 +88,7 @@ public class CNConfig {
|
||||
public static boolean carbonChatChannel;
|
||||
public static boolean advancedChatChannel;
|
||||
public static boolean hasLibsDisguise;
|
||||
public static boolean catchOtherActionBar;
|
||||
|
||||
public static void load() {
|
||||
try {
|
||||
@@ -182,6 +183,8 @@ public class CNConfig {
|
||||
createRealTeam = config.getBoolean("other-settings.create-real-teams", false);
|
||||
|
||||
hasLibsDisguise = Bukkit.getPluginManager().getPlugin("LibsDisguises") != null;
|
||||
|
||||
catchOtherActionBar = config.getBoolean("other-settings.catch-other-plugin-actionbar", true);
|
||||
}
|
||||
|
||||
public static boolean isOtherTeamPluginHooked() {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
# Do not change
|
||||
config-version: '27'
|
||||
config-version: '28'
|
||||
|
||||
# Debug mode
|
||||
debug: false
|
||||
@@ -113,3 +113,6 @@ other-settings:
|
||||
# The more people on your server, the higher the efficiency of the caching system's operation.
|
||||
# In most cases you don't have to edit this value. You can increase this value appropriately, especially when there are many players on your server.
|
||||
cache-size: 256
|
||||
|
||||
# Decides whether CustomNameplates should catch actionbar sent by other plugins
|
||||
catch-other-plugin-actionbar: true
|
||||
Reference in New Issue
Block a user