This commit is contained in:
Telesphoreo 2021-12-12 01:05:13 -06:00
commit a646134f70
7 changed files with 15 additions and 10 deletions

View file

@ -749,7 +749,7 @@ public class Essentials extends JavaPlugin implements net.ess3.api.IEssentials {
if (getSettings().isCommandDisabled(commandLabel)) {
if (getKnownCommandsProvider().getKnownCommands().containsKey(commandLabel)) {
final Command newCmd = getKnownCommandsProvider().getKnownCommands().get(commandLabel);
if (!(newCmd instanceof PluginIdentifiableCommand) || ((PluginIdentifiableCommand) newCmd).getPlugin() != this) {
if (!(newCmd instanceof PluginIdentifiableCommand) || !isEssentialsPlugin(((PluginIdentifiableCommand) newCmd).getPlugin())) {
return newCmd.execute(cSender, commandLabel, args);
}
}
@ -824,6 +824,10 @@ public class Essentials extends JavaPlugin implements net.ess3.api.IEssentials {
}
}
private boolean isEssentialsPlugin(Plugin plugin) {
return plugin.getDescription().getMain().contains("com.earth2me.essentials") || plugin.getDescription().getMain().contains("net.essentialsx");
}
public void cleanupOpenInventories() {
for (final User user : getOnlineUsers()) {
if (user.isRecipeSee()) {

View file

@ -34,9 +34,9 @@ public final class VersionUtil {
public static final BukkitVersion v1_16_5_R01 = BukkitVersion.fromString("1.16.5-R0.1-SNAPSHOT");
public static final BukkitVersion v1_17_R01 = BukkitVersion.fromString("1.17-R0.1-SNAPSHOT");
public static final BukkitVersion v1_17_1_R01 = BukkitVersion.fromString("1.17.1-R0.1-SNAPSHOT");
public static final BukkitVersion v1_18_R01 = BukkitVersion.fromString("1.18-R0.1-SNAPSHOT");
public static final BukkitVersion v1_18_1_R01 = BukkitVersion.fromString("1.18.1-R0.1-SNAPSHOT");
private static final Set<BukkitVersion> supportedVersions = ImmutableSet.of(v1_8_8_R01, v1_9_4_R01, v1_10_2_R01, v1_11_2_R01, v1_12_2_R01, v1_13_2_R01, v1_14_4_R01, v1_15_2_R01, v1_16_5_R01, v1_17_1_R01, v1_18_R01);
private static final Set<BukkitVersion> supportedVersions = ImmutableSet.of(v1_8_8_R01, v1_9_4_R01, v1_10_2_R01, v1_11_2_R01, v1_12_2_R01, v1_13_2_R01, v1_14_4_R01, v1_15_2_R01, v1_16_5_R01, v1_17_1_R01, v1_18_1_R01);
private static final Map<String, SupportStatus> unsupportedServerClasses;

View file

@ -26,7 +26,7 @@ EssentialsX is almost a completely drop-in replacement for Essentials. However,
* **EssentialsX requires Java 8 or higher.** On older versions, the plugin may not work properly.
* **EssentialsX supports Minecraft versions 1.8.8, 1.9.4, 1.10.2, 1.11.2, 1.12.2, 1.13.2, 1.14.4, 1.15.2, 1.16.5, 1.17.1, and 1.18**
* **EssentialsX supports Minecraft versions 1.8.8, 1.9.4, 1.10.2, 1.11.2, 1.12.2, 1.13.2, 1.14.4, 1.15.2, 1.16.5, 1.17.1, and 1.18.1**
Support

View file

@ -1 +1 @@
const val RUN_PAPER_MINECRAFT_VERSION = "1.17.1"
const val RUN_PAPER_MINECRAFT_VERSION = "1.18.1"

View file

@ -3,14 +3,14 @@ import org.apache.tools.ant.filters.ReplaceTokens
plugins {
id("java")
id("net.kyori.indra")
// id("net.kyori.indra.checkstyle")
id("net.kyori.indra.checkstyle")
id("net.kyori.indra.publishing")
}
val baseExtension = extensions.create<EssentialsBaseExtension>("essentials", project)
//val checkstyleVersion = "8.36.2"
val spigotVersion = "1.18-R0.1-SNAPSHOT"
val checkstyleVersion = "8.36.2"
val spigotVersion = "1.18.1-R0.1-SNAPSHOT"
val junit5Version = "5.7.0"
val mockitoVersion = "3.2.0"
@ -81,7 +81,7 @@ configurations.all {
}
indra {
// checkstyle(checkstyleVersion)
checkstyle(checkstyleVersion)
github("EssentialsX", "Essentials")
gpl3OnlyLicense()

View file

@ -12,7 +12,7 @@ import java.lang.reflect.Field;
import java.util.Locale;
/**
* Stores persistent data on 1.18-1.13 in a manner that's consistent with PDC on 1.14+ to enable
* Stores persistent data on 1.8-1.13 in a manner that's consistent with PDC on 1.14+ to enable
* seamless upgrades.
*/
public class ReflPersistentDataProvider implements PersistentDataProvider {

View file

@ -22,6 +22,7 @@ dependencyResolutionManagement {
}
mavenCentral {
content { includeGroup("net.kyori") }
content { includeGroup("org.apache.logging.log4j") }
}
}
repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)