mirror of
https://github.com/Xiao-MoMi/craft-engine.git
synced 2025-12-25 18:09:27 +00:00
重构框架
This commit is contained in:
@@ -7,15 +7,12 @@ repositories {
|
||||
maven("https://jitpack.io/")
|
||||
maven("https://repo.papermc.io/repository/maven-public/")
|
||||
maven("https://repo.momirealms.net/releases/")
|
||||
maven("https://repo.skriptlang.org/releases/") // skript
|
||||
mavenCentral()
|
||||
}
|
||||
|
||||
dependencies {
|
||||
compileOnly(project(":core"))
|
||||
compileOnly(project(":shared"))
|
||||
compileOnly(project(":bukkit:compatibility"))
|
||||
compileOnly(project(":bukkit:compatibility:legacy"))
|
||||
compileOnly(project(":bukkit:legacy"))
|
||||
// Anti Grief
|
||||
compileOnly("net.momirealms:antigrieflib:${rootProject.properties["anti_grief_version"]}")
|
||||
@@ -60,8 +57,6 @@ dependencies {
|
||||
compileOnly("org.bstats:bstats-bukkit:${rootProject.properties["bstats_version"]}")
|
||||
// Aho-Corasick java implementation
|
||||
compileOnly("org.ahocorasick:ahocorasick:${rootProject.properties["ahocorasick_version"]}")
|
||||
// Skript
|
||||
compileOnly("com.github.SkriptLang:Skript:2.11.0")
|
||||
}
|
||||
|
||||
java {
|
||||
|
||||
@@ -10,10 +10,13 @@ repositories {
|
||||
maven("https://mvn.lumine.io/repository/maven-public/") // model engine
|
||||
maven("https://nexus.phoenixdevt.fr/repository/maven-public/") // mmoitems
|
||||
maven("https://repo.viaversion.com") // via
|
||||
maven("https://repo.skriptlang.org/releases/") // skript
|
||||
}
|
||||
|
||||
dependencies {
|
||||
compileOnly(project(":core"))
|
||||
compileOnly(project(":bukkit"))
|
||||
compileOnly(project(":bukkit:compatibility:legacy"))
|
||||
compileOnly("net.momirealms:sparrow-nbt:${rootProject.properties["sparrow_nbt_version"]}")
|
||||
// Platform
|
||||
compileOnly("io.papermc.paper:paper-api:${rootProject.properties["paper_version"]}-R0.1-SNAPSHOT")
|
||||
@@ -37,6 +40,8 @@ dependencies {
|
||||
compileOnly("net.luckperms:api:5.4")
|
||||
// viaversion
|
||||
compileOnly("com.viaversion:viaversion-api:5.3.2")
|
||||
// Skript
|
||||
compileOnly("com.github.SkriptLang:Skript:2.11.0")
|
||||
}
|
||||
|
||||
java {
|
||||
|
||||
@@ -13,7 +13,6 @@ import net.momirealms.sparrow.nbt.CompoundTag;
|
||||
import net.momirealms.sparrow.nbt.NBT;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.lang.ref.WeakReference;
|
||||
import java.util.Optional;
|
||||
|
||||
|
||||
@@ -0,0 +1,188 @@
|
||||
package net.momirealms.craftengine.bukkit.compatibility;
|
||||
|
||||
import net.momirealms.craftengine.bukkit.block.BukkitBlockManager;
|
||||
import net.momirealms.craftengine.bukkit.compatibility.bettermodel.BetterModelModel;
|
||||
import net.momirealms.craftengine.bukkit.compatibility.item.MMOItemsProvider;
|
||||
import net.momirealms.craftengine.bukkit.compatibility.item.NeigeItemsProvider;
|
||||
import net.momirealms.craftengine.bukkit.compatibility.legacy.slimeworld.LegacySlimeFormatStorageAdaptor;
|
||||
import net.momirealms.craftengine.bukkit.compatibility.modelengine.ModelEngineModel;
|
||||
import net.momirealms.craftengine.bukkit.compatibility.modelengine.ModelEngineUtils;
|
||||
import net.momirealms.craftengine.bukkit.compatibility.papi.PlaceholderAPIUtils;
|
||||
import net.momirealms.craftengine.bukkit.compatibility.permission.LuckPermsEventListeners;
|
||||
import net.momirealms.craftengine.bukkit.compatibility.skript.classes.CraftEngineClasses;
|
||||
import net.momirealms.craftengine.bukkit.compatibility.skript.condition.CondIsBlockCustomBlock;
|
||||
import net.momirealms.craftengine.bukkit.compatibility.skript.event.EvtCustomBlock;
|
||||
import net.momirealms.craftengine.bukkit.compatibility.skript.expression.ExprBlockCustomBlockID;
|
||||
import net.momirealms.craftengine.bukkit.compatibility.skript.expression.ExprBlockCustomBlockState;
|
||||
import net.momirealms.craftengine.bukkit.compatibility.slimeworld.SlimeFormatStorageAdaptor;
|
||||
import net.momirealms.craftengine.bukkit.compatibility.viaversion.ViaVersionUtils;
|
||||
import net.momirealms.craftengine.bukkit.compatibility.worldedit.WorldEditBlockRegister;
|
||||
import net.momirealms.craftengine.bukkit.font.BukkitFontManager;
|
||||
import net.momirealms.craftengine.bukkit.item.BukkitItemManager;
|
||||
import net.momirealms.craftengine.bukkit.plugin.BukkitCraftEngine;
|
||||
import net.momirealms.craftengine.core.entity.furniture.AbstractExternalModel;
|
||||
import net.momirealms.craftengine.core.entity.player.Player;
|
||||
import net.momirealms.craftengine.core.plugin.CompatibilityManager;
|
||||
import net.momirealms.craftengine.core.util.Key;
|
||||
import net.momirealms.craftengine.core.util.VersionHelper;
|
||||
import net.momirealms.craftengine.core.world.WorldManager;
|
||||
import org.bukkit.Bukkit;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
public class BukkitCompatibilityManager implements CompatibilityManager {
|
||||
private final BukkitCraftEngine plugin;
|
||||
private boolean hasPlaceholderAPI;
|
||||
private boolean hasViaVersion;
|
||||
|
||||
public BukkitCompatibilityManager(BukkitCraftEngine plugin) {
|
||||
this.plugin = plugin;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onLoad() {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onEnable() {
|
||||
this.initSlimeWorldHook();
|
||||
if (this.isPluginEnabled("PlaceholderAPI")) {
|
||||
PlaceholderAPIUtils.registerExpansions(this.plugin);
|
||||
this.hasPlaceholderAPI = true;
|
||||
logHook("PlaceholderAPI");
|
||||
}
|
||||
// skript
|
||||
if (this.isPluginEnabled("Skript")) {
|
||||
CraftEngineClasses.register();
|
||||
EvtCustomBlock.register();
|
||||
CondIsBlockCustomBlock.register();
|
||||
ExprBlockCustomBlockID.register();
|
||||
ExprBlockCustomBlockState.register();
|
||||
logHook("Skript");
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onDelayedEnable() {
|
||||
this.initItemHooks();
|
||||
// WorldEdit
|
||||
if (this.isPluginEnabled("FastAsyncWorldEdit")) {
|
||||
this.initFastAsyncWorldEditHook();
|
||||
logHook("FastAsyncWorldEdit");
|
||||
} else if (this.isPluginEnabled("WorldEdit")) {
|
||||
this.initWorldEditHook();
|
||||
logHook("WorldEdit");
|
||||
}
|
||||
if (this.isPluginEnabled("LuckPerms")) {
|
||||
this.initLuckPermsHook();
|
||||
logHook("LuckPerms");
|
||||
}
|
||||
}
|
||||
|
||||
private void logHook(String plugin) {
|
||||
this.plugin.logger().info("[Compatibility] " + plugin + " hooked");
|
||||
}
|
||||
|
||||
@Override
|
||||
public AbstractExternalModel createModelEngineModel(String id) {
|
||||
return new ModelEngineModel(id);
|
||||
}
|
||||
|
||||
@Override
|
||||
public AbstractExternalModel createBetterModelModel(String id) {
|
||||
return new BetterModelModel(id);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int interactionToBaseEntity(int id) {
|
||||
return ModelEngineUtils.interactionToBaseEntity(id);
|
||||
}
|
||||
|
||||
private void initLuckPermsHook() {
|
||||
new LuckPermsEventListeners(plugin.bootstrap(), (uuid) -> {
|
||||
BukkitFontManager fontManager = (BukkitFontManager) plugin.fontManager();
|
||||
fontManager.refreshEmojiSuggestions(uuid);
|
||||
});
|
||||
}
|
||||
|
||||
private void initSlimeWorldHook() {
|
||||
WorldManager worldManager = this.plugin.worldManager();
|
||||
if (VersionHelper.isVersionNewerThan1_21_4()) {
|
||||
try {
|
||||
Class.forName("com.infernalsuite.asp.api.AdvancedSlimePaperAPI");
|
||||
SlimeFormatStorageAdaptor adaptor = new SlimeFormatStorageAdaptor(worldManager);
|
||||
worldManager.setStorageAdaptor(adaptor);
|
||||
Bukkit.getPluginManager().registerEvents(adaptor, plugin.bootstrap());
|
||||
logHook("AdvancedSlimePaper");
|
||||
} catch (ClassNotFoundException ignored) {
|
||||
}
|
||||
} else {
|
||||
try {
|
||||
Class.forName("com.infernalsuite.aswm.api.SlimePlugin");
|
||||
LegacySlimeFormatStorageAdaptor adaptor = new LegacySlimeFormatStorageAdaptor(worldManager, 1);
|
||||
worldManager.setStorageAdaptor(adaptor);
|
||||
Bukkit.getPluginManager().registerEvents(adaptor, plugin.bootstrap());
|
||||
logHook("AdvancedSlimePaper");
|
||||
} catch (ClassNotFoundException ignored) {
|
||||
if (Bukkit.getPluginManager().isPluginEnabled("SlimeWorldPlugin")) {
|
||||
LegacySlimeFormatStorageAdaptor adaptor = new LegacySlimeFormatStorageAdaptor(worldManager, 2);
|
||||
worldManager.setStorageAdaptor(adaptor);
|
||||
Bukkit.getPluginManager().registerEvents(adaptor, plugin.bootstrap());
|
||||
logHook("AdvancedSlimePaper");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void initFastAsyncWorldEditHook() {
|
||||
new WorldEditBlockRegister(BukkitBlockManager.instance(), true);
|
||||
}
|
||||
|
||||
private void initWorldEditHook() {
|
||||
WorldEditBlockRegister weBlockRegister = new WorldEditBlockRegister(BukkitBlockManager.instance(), false);
|
||||
try {
|
||||
for (Key newBlockId : BukkitBlockManager.instance().blockRegisterOrder()) {
|
||||
weBlockRegister.register(newBlockId);
|
||||
}
|
||||
} catch (Exception e) {
|
||||
this.plugin.logger().warn("Failed to initialize world edit hook", e);
|
||||
}
|
||||
}
|
||||
|
||||
private void initItemHooks() {
|
||||
BukkitItemManager itemManager = BukkitItemManager.instance();
|
||||
if (this.isPluginEnabled("NeigeItems")) {
|
||||
itemManager.registerExternalItemProvider(new NeigeItemsProvider());
|
||||
logHook("NeigeItems");
|
||||
}
|
||||
if (this.isPluginEnabled("MMOItems")) {
|
||||
itemManager.registerExternalItemProvider(new MMOItemsProvider());
|
||||
logHook("MMOItems");
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean hasPlaceholderAPI() {
|
||||
return this.hasPlaceholderAPI;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isPluginEnabled(String plugin) {
|
||||
return Bukkit.getPluginManager().isPluginEnabled(plugin);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean hasPlugin(String plugin) {
|
||||
return Bukkit.getPluginManager().getPlugin(plugin) != null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String parse(Player player, String text) {
|
||||
return PlaceholderAPIUtils.parse((org.bukkit.entity.Player) player.platformPlayer(), text);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getPlayerProtocolVersion(UUID uuid) {
|
||||
return ViaVersionUtils.getPlayerProtocolVersion(uuid);
|
||||
}
|
||||
}
|
||||
@@ -42,16 +42,16 @@ public class LuckPermsEventListeners {
|
||||
this.subscriptions.add(eventBus.subscribe(this.plugin, GroupDataRecalculateEvent.class, this::onGroupPermissionChange));
|
||||
}
|
||||
|
||||
public void unregisterListeners() {
|
||||
this.subscriptions.forEach(subscription -> {
|
||||
try {
|
||||
subscription.close();
|
||||
} catch (Exception e) {
|
||||
this.plugin.getLogger().log(Level.WARNING, "Failed to close event subscription", e);
|
||||
}
|
||||
});
|
||||
this.subscriptions.clear();
|
||||
}
|
||||
// public void unregisterListeners() {
|
||||
// this.subscriptions.forEach(subscription -> {
|
||||
// try {
|
||||
// subscription.close();
|
||||
// } catch (Exception e) {
|
||||
// this.plugin.getLogger().log(Level.WARNING, "Failed to close event subscription", e);
|
||||
// }
|
||||
// });
|
||||
// this.subscriptions.clear();
|
||||
// }
|
||||
|
||||
private void onUserPermissionChange(UserDataRecalculateEvent event) {
|
||||
CraftEngine.instance().scheduler().async().execute(() -> {
|
||||
|
||||
@@ -2,15 +2,11 @@ package net.momirealms.craftengine.bukkit.compatibility.skript.expression;
|
||||
|
||||
import ch.njol.skript.expressions.base.SimplePropertyExpression;
|
||||
import net.momirealms.craftengine.bukkit.api.CraftEngineBlocks;
|
||||
import net.momirealms.craftengine.core.block.CustomBlock;
|
||||
import net.momirealms.craftengine.core.block.ImmutableBlockState;
|
||||
import org.bukkit.block.Block;
|
||||
import org.bukkit.block.BlockState;
|
||||
import org.bukkit.block.data.BlockData;
|
||||
import org.jetbrains.annotations.Nullable;
|
||||
|
||||
import java.util.Optional;
|
||||
|
||||
public class ExprBlockCustomBlockState extends SimplePropertyExpression<Object, ImmutableBlockState> {
|
||||
|
||||
public static void register() {
|
||||
@@ -11,7 +11,6 @@ import net.momirealms.sparrow.nbt.CompoundTag;
|
||||
import net.momirealms.sparrow.nbt.NBT;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.lang.ref.WeakReference;
|
||||
import java.util.Map;
|
||||
|
||||
|
||||
@@ -1,27 +0,0 @@
|
||||
package net.momirealms.craftengine.bukkit.compatibility.viaversion;
|
||||
|
||||
import com.viaversion.viaversion.api.Via;
|
||||
import com.viaversion.viaversion.api.ViaAPI;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
|
||||
public class ViaVersionProtocol {
|
||||
private final boolean hasPlugin;
|
||||
private final ViaAPI<?> viaAPI;
|
||||
|
||||
public ViaVersionProtocol(boolean hasPlugin) {
|
||||
this.hasPlugin = hasPlugin;
|
||||
this.viaAPI = hasPlugin ? Via.getAPI() : null;
|
||||
}
|
||||
|
||||
public int getPlayerProtocolVersion(UUID uuid) {
|
||||
if (!hasPlugin) return -1;
|
||||
System.out.println(this.viaAPI.getPlayerProtocolVersion(uuid).getVersion());
|
||||
return this.viaAPI.getPlayerProtocolVersion(uuid).getVersion();
|
||||
}
|
||||
|
||||
public boolean hasPlugin() {
|
||||
return hasPlugin;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
package net.momirealms.craftengine.bukkit.compatibility.viaversion;
|
||||
|
||||
import com.viaversion.viaversion.api.Via;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
public final class ViaVersionUtils {
|
||||
|
||||
private ViaVersionUtils() {}
|
||||
|
||||
public static int getPlayerProtocolVersion(UUID uuid) {
|
||||
return Via.getAPI().getPlayerProtocolVersion(uuid).getVersion();
|
||||
}
|
||||
}
|
||||
@@ -5,7 +5,6 @@ import net.momirealms.craftengine.core.block.CustomBlock;
|
||||
import net.momirealms.craftengine.core.block.ImmutableBlockState;
|
||||
import org.bukkit.Location;
|
||||
import org.bukkit.block.Block;
|
||||
import org.bukkit.entity.Player;
|
||||
import org.bukkit.event.Cancellable;
|
||||
import org.bukkit.event.HandlerList;
|
||||
import org.bukkit.event.player.PlayerEvent;
|
||||
|
||||
@@ -7,7 +7,6 @@ import net.momirealms.craftengine.bukkit.plugin.BukkitCraftEngine;
|
||||
import net.momirealms.craftengine.bukkit.plugin.user.BukkitServerPlayer;
|
||||
import net.momirealms.craftengine.bukkit.util.*;
|
||||
import net.momirealms.craftengine.bukkit.world.BukkitWorld;
|
||||
import net.momirealms.craftengine.core.block.BlockSettings;
|
||||
import net.momirealms.craftengine.core.block.ImmutableBlockState;
|
||||
import net.momirealms.craftengine.core.block.properties.Property;
|
||||
import net.momirealms.craftengine.core.entity.player.InteractionHand;
|
||||
|
||||
@@ -7,7 +7,6 @@ import com.google.gson.JsonArray;
|
||||
import com.google.gson.JsonElement;
|
||||
import com.google.gson.JsonObject;
|
||||
import dev.dejvokep.boostedyaml.YamlDocument;
|
||||
import net.momirealms.craftengine.bukkit.compatibility.worldedit.WorldEditBlockRegister;
|
||||
import net.momirealms.craftengine.bukkit.nms.FastNMS;
|
||||
import net.momirealms.craftengine.bukkit.plugin.BukkitCraftEngine;
|
||||
import net.momirealms.craftengine.bukkit.plugin.injector.BukkitInjector;
|
||||
@@ -117,6 +116,10 @@ public class BukkitBlockManager extends AbstractBlockManager {
|
||||
this.resetPacketConsumers();
|
||||
}
|
||||
|
||||
public List<Key> blockRegisterOrder() {
|
||||
return Collections.unmodifiableList(this.blockRegisterOrder);
|
||||
}
|
||||
|
||||
public static BukkitBlockManager instance() {
|
||||
return instance;
|
||||
}
|
||||
@@ -127,12 +130,6 @@ public class BukkitBlockManager extends AbstractBlockManager {
|
||||
if (this.fallingBlockRemoveListener != null) {
|
||||
Bukkit.getPluginManager().registerEvents(this.fallingBlockRemoveListener, plugin.bootstrap());
|
||||
}
|
||||
// WorldEdit
|
||||
if (this.plugin.isPluginEnabled("FastAsyncWorldEdit")) {
|
||||
this.initFastAsyncWorldEditHook();
|
||||
} else if (this.plugin.isPluginEnabled("WorldEdit")) {
|
||||
this.initWorldEditHook();
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -171,20 +168,6 @@ public class BukkitBlockManager extends AbstractBlockManager {
|
||||
this.tempVanillaBlockStateModels.clear();
|
||||
}
|
||||
|
||||
public void initFastAsyncWorldEditHook() {
|
||||
new WorldEditBlockRegister(this, true);
|
||||
}
|
||||
|
||||
public void initWorldEditHook() {
|
||||
WorldEditBlockRegister weBlockRegister = new WorldEditBlockRegister(this, false);
|
||||
try {
|
||||
for (Key newBlockId : this.blockRegisterOrder) {
|
||||
weBlockRegister.register(newBlockId);
|
||||
}
|
||||
} catch (Exception e) {
|
||||
this.plugin.logger().warn("Failed to initialize world edit hook", e);
|
||||
}
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public Object getMinecraftBlockHolder(int stateId) {
|
||||
|
||||
@@ -1,7 +1,5 @@
|
||||
package net.momirealms.craftengine.bukkit.entity.furniture;
|
||||
|
||||
import net.momirealms.craftengine.bukkit.compatibility.bettermodel.BetterModelModel;
|
||||
import net.momirealms.craftengine.bukkit.compatibility.modelengine.ModelEngineModel;
|
||||
import net.momirealms.craftengine.bukkit.entity.furniture.hitbox.InteractionHitBox;
|
||||
import net.momirealms.craftengine.bukkit.nms.CollisionEntity;
|
||||
import net.momirealms.craftengine.bukkit.nms.FastNMS;
|
||||
@@ -149,9 +147,9 @@ public class BukkitFurnitureManager extends AbstractFurnitureManager {
|
||||
// external model providers
|
||||
Optional<ExternalModel> externalModel;
|
||||
if (placementArguments.containsKey("model-engine")) {
|
||||
externalModel = Optional.of(new ModelEngineModel(placementArguments.get("model-engine").toString()));
|
||||
externalModel = Optional.of(plugin.compatibilityManager().createModelEngineModel(placementArguments.get("model-engine").toString()));
|
||||
} else if (placementArguments.containsKey("better-model")) {
|
||||
externalModel = Optional.of(new BetterModelModel(placementArguments.get("better-model").toString()));
|
||||
externalModel = Optional.of(plugin.compatibilityManager().createBetterModelModel(placementArguments.get("better-model").toString()));
|
||||
} else {
|
||||
externalModel = Optional.empty();
|
||||
}
|
||||
|
||||
@@ -5,7 +5,6 @@ import com.google.gson.JsonObject;
|
||||
import io.papermc.paper.event.player.AsyncChatCommandDecorateEvent;
|
||||
import io.papermc.paper.event.player.AsyncChatDecorateEvent;
|
||||
import net.kyori.adventure.text.Component;
|
||||
import net.momirealms.craftengine.bukkit.compatibility.permission.LuckPermsEventListeners;
|
||||
import net.momirealms.craftengine.bukkit.plugin.BukkitCraftEngine;
|
||||
import net.momirealms.craftengine.bukkit.util.ComponentUtils;
|
||||
import net.momirealms.craftengine.bukkit.util.LegacyInventoryUtils;
|
||||
@@ -35,7 +34,6 @@ import java.util.*;
|
||||
|
||||
public class BukkitFontManager extends AbstractFontManager implements Listener {
|
||||
private final BukkitCraftEngine plugin;
|
||||
private LuckPermsEventListeners luckPermsEventListeners;
|
||||
|
||||
public BukkitFontManager(BukkitCraftEngine plugin) {
|
||||
super(plugin);
|
||||
@@ -44,9 +42,6 @@ public class BukkitFontManager extends AbstractFontManager implements Listener {
|
||||
|
||||
@Override
|
||||
public void delayedInit() {
|
||||
if (this.plugin.isPluginEnabled("LuckPerms")) {
|
||||
luckPermsEventListeners = new LuckPermsEventListeners(plugin.bootstrap(), this::refreshEmojiSuggestions);
|
||||
}
|
||||
Bukkit.getPluginManager().registerEvents(this, plugin.bootstrap());
|
||||
}
|
||||
|
||||
@@ -54,9 +49,6 @@ public class BukkitFontManager extends AbstractFontManager implements Listener {
|
||||
public void disable() {
|
||||
super.disable();
|
||||
HandlerList.unregisterAll(this);
|
||||
if (luckPermsEventListeners != null && this.plugin.isPluginEnabled("LuckPerms")) {
|
||||
luckPermsEventListeners.unregisterListeners();
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -76,7 +68,8 @@ public class BukkitFontManager extends AbstractFontManager implements Listener {
|
||||
plugin.scheduler().async().execute(() -> this.addEmojiSuggestions(event.getPlayer(), getEmojiSuggestion(event.getPlayer())));
|
||||
}
|
||||
|
||||
private void refreshEmojiSuggestions(UUID uuid) {
|
||||
@Override
|
||||
public void refreshEmojiSuggestions(UUID uuid) {
|
||||
Player player = Bukkit.getPlayer(uuid);
|
||||
if (player == null) return;
|
||||
removeEmojiSuggestions(player);
|
||||
|
||||
@@ -1,7 +1,5 @@
|
||||
package net.momirealms.craftengine.bukkit.item;
|
||||
|
||||
import net.momirealms.craftengine.bukkit.compatibility.item.MMOItemsProvider;
|
||||
import net.momirealms.craftengine.bukkit.compatibility.item.NeigeItemsProvider;
|
||||
import net.momirealms.craftengine.bukkit.item.behavior.AxeItemBehavior;
|
||||
import net.momirealms.craftengine.bukkit.item.behavior.BoneMealItemBehavior;
|
||||
import net.momirealms.craftengine.bukkit.item.behavior.BucketItemBehavior;
|
||||
@@ -131,16 +129,6 @@ public class BukkitItemManager extends AbstractItemManager<ItemStack> {
|
||||
public void delayedInit() {
|
||||
Bukkit.getPluginManager().registerEvents(this.itemEventListener, this.plugin.bootstrap());
|
||||
Bukkit.getPluginManager().registerEvents(this.debugStickListener, this.plugin.bootstrap());
|
||||
this.hookExternalPlugins();
|
||||
}
|
||||
|
||||
private void hookExternalPlugins() {
|
||||
if (this.plugin.isPluginEnabled("NeigeItems")) {
|
||||
registerExternalItemProvider(new NeigeItemsProvider());
|
||||
}
|
||||
if (this.plugin.isPluginEnabled("MMOItems")) {
|
||||
registerExternalItemProvider(new MMOItemsProvider());
|
||||
}
|
||||
}
|
||||
|
||||
public static BukkitItemManager instance() {
|
||||
|
||||
@@ -5,12 +5,6 @@ import net.momirealms.craftengine.bukkit.advancement.BukkitAdvancementManager;
|
||||
import net.momirealms.craftengine.bukkit.api.event.CraftEngineReloadEvent;
|
||||
import net.momirealms.craftengine.bukkit.block.BukkitBlockManager;
|
||||
import net.momirealms.craftengine.bukkit.block.behavior.BukkitBlockBehaviors;
|
||||
import net.momirealms.craftengine.bukkit.compatibility.papi.PlaceholderAPIUtils;
|
||||
import net.momirealms.craftengine.bukkit.compatibility.skript.classes.CraftEngineClasses;
|
||||
import net.momirealms.craftengine.bukkit.compatibility.skript.condition.CondIsBlockCustomBlock;
|
||||
import net.momirealms.craftengine.bukkit.compatibility.skript.event.EvtCustomBlock;
|
||||
import net.momirealms.craftengine.bukkit.compatibility.skript.expression.ExprBlockCustomBlockID;
|
||||
import net.momirealms.craftengine.bukkit.compatibility.skript.expression.ExprBlockCustomBlockState;
|
||||
import net.momirealms.craftengine.bukkit.entity.furniture.BukkitFurnitureManager;
|
||||
import net.momirealms.craftengine.bukkit.entity.furniture.hitbox.BukkitHitBoxTypes;
|
||||
import net.momirealms.craftengine.bukkit.font.BukkitFontManager;
|
||||
@@ -30,8 +24,8 @@ import net.momirealms.craftengine.bukkit.sound.BukkitSoundManager;
|
||||
import net.momirealms.craftengine.bukkit.util.EventUtils;
|
||||
import net.momirealms.craftengine.bukkit.util.Reflections;
|
||||
import net.momirealms.craftengine.bukkit.world.BukkitWorldManager;
|
||||
import net.momirealms.craftengine.core.entity.player.Player;
|
||||
import net.momirealms.craftengine.core.item.ItemManager;
|
||||
import net.momirealms.craftengine.core.plugin.CompatibilityManager;
|
||||
import net.momirealms.craftengine.core.plugin.CraftEngine;
|
||||
import net.momirealms.craftengine.core.plugin.classpath.ReflectionClassPathAppender;
|
||||
import net.momirealms.craftengine.core.plugin.command.sender.SenderFactory;
|
||||
@@ -56,10 +50,12 @@ import java.io.*;
|
||||
import java.lang.reflect.Field;
|
||||
import java.nio.file.Path;
|
||||
import java.util.List;
|
||||
import java.util.Objects;
|
||||
import java.util.Optional;
|
||||
|
||||
@SuppressWarnings("unchecked")
|
||||
public class BukkitCraftEngine extends CraftEngine {
|
||||
private static final String COMPATIBILITY_CLASS = "net.momirealms.craftengine.bukkit.compatibility.BukkitCompatibilityManager";
|
||||
private static BukkitCraftEngine instance;
|
||||
private final JavaPlugin bootstrap;
|
||||
private SchedulerTask tickTask;
|
||||
@@ -68,7 +64,6 @@ public class BukkitCraftEngine extends CraftEngine {
|
||||
private boolean requiresRestart = false;
|
||||
private boolean hasMod = false;
|
||||
private AntiGriefLib antiGrief;
|
||||
private boolean hasPlaceholderAPI;
|
||||
|
||||
public BukkitCraftEngine(JavaPlugin bootstrap) {
|
||||
super((p) -> {
|
||||
@@ -90,6 +85,12 @@ public class BukkitCraftEngine extends CraftEngine {
|
||||
} catch (Exception ignore) {
|
||||
}
|
||||
}
|
||||
Class<?> compatibilityClass = Objects.requireNonNull(ReflectionUtils.getClazz(COMPATIBILITY_CLASS), "Compatibility class not found");
|
||||
try {
|
||||
super.compatibilityManager = (CompatibilityManager) Objects.requireNonNull(ReflectionUtils.getConstructor(compatibilityClass, 0)).newInstance(this);
|
||||
} catch (ReflectiveOperationException e) {
|
||||
logger().warn("Compatibility class could not be instantiated: " + compatibilityClass.getName());
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -101,6 +102,7 @@ public class BukkitCraftEngine extends CraftEngine {
|
||||
super.blockManager = new BukkitBlockManager(this);
|
||||
super.furnitureManager = new BukkitFurnitureManager(this);
|
||||
this.successfullyLoaded = true;
|
||||
super.compatibilityManager().onLoad();
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -164,20 +166,7 @@ public class BukkitCraftEngine extends CraftEngine {
|
||||
super.fontManager = new BukkitFontManager(this);
|
||||
super.advancementManager = new BukkitAdvancementManager(this);
|
||||
super.onPluginEnable();
|
||||
// compatibility
|
||||
// register expansion
|
||||
if (this.isPluginEnabled("PlaceholderAPI")) {
|
||||
PlaceholderAPIUtils.registerExpansions(this);
|
||||
this.hasPlaceholderAPI = true;
|
||||
}
|
||||
// skript
|
||||
if (this.isPluginEnabled("Skript")) {
|
||||
CraftEngineClasses.register();
|
||||
EvtCustomBlock.register();
|
||||
CondIsBlockCustomBlock.register();
|
||||
ExprBlockCustomBlockID.register();
|
||||
ExprBlockCustomBlockState.register();
|
||||
}
|
||||
super.compatibilityManager().onEnable();
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -217,6 +206,7 @@ public class BukkitCraftEngine extends CraftEngine {
|
||||
}
|
||||
}, 1, 1);
|
||||
}
|
||||
super.compatibilityManager().onDelayedEnable();
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -283,21 +273,6 @@ public class BukkitCraftEngine extends CraftEngine {
|
||||
return instance;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean hasPlaceholderAPI() {
|
||||
return this.hasPlaceholderAPI;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isPluginEnabled(String plugin) {
|
||||
return Bukkit.getPluginManager().isPluginEnabled(plugin);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String parse(Player player, String text) {
|
||||
return PlaceholderAPIUtils.parse((org.bukkit.entity.Player) player.platformPlayer(), text);
|
||||
}
|
||||
|
||||
@Override
|
||||
public BukkitNetworkManager networkManager() {
|
||||
return (BukkitNetworkManager) networkManager;
|
||||
|
||||
@@ -371,9 +371,8 @@ public class BukkitInjector {
|
||||
public static void injectLevelChunkSection(Object targetSection, CESection ceSection, CEWorld ceWorld, SectionPos pos) {
|
||||
try {
|
||||
Object container = FastNMS.INSTANCE.field$LevelChunkSection$states(targetSection);
|
||||
if (!clazz$InjectedPalettedContainer.isInstance(container)) {
|
||||
InjectedPalettedContainerHolder injectedObject = (InjectedPalettedContainerHolder) Reflections.UNSAFE.allocateInstance(clazz$InjectedPalettedContainer);
|
||||
varHandle$InjectedPalettedContainer$target.set(injectedObject, container);
|
||||
if (!(container instanceof InjectedPalettedContainerHolder)) {
|
||||
InjectedPalettedContainerHolder injectedObject = FastNMS.INSTANCE.createInjectedPalettedContainerHolder(container);
|
||||
injectedObject.ceSection(ceSection);
|
||||
injectedObject.ceWorld(ceWorld);
|
||||
injectedObject.cePos(pos);
|
||||
|
||||
@@ -7,7 +7,6 @@ import io.netty.handler.codec.MessageToMessageDecoder;
|
||||
import io.netty.handler.codec.MessageToMessageEncoder;
|
||||
import io.netty.util.internal.logging.InternalLogger;
|
||||
import io.netty.util.internal.logging.InternalLoggerFactory;
|
||||
import net.momirealms.craftengine.bukkit.compatibility.viaversion.ViaVersionProtocol;
|
||||
import net.momirealms.craftengine.bukkit.nms.FastNMS;
|
||||
import net.momirealms.craftengine.bukkit.plugin.BukkitCraftEngine;
|
||||
import net.momirealms.craftengine.bukkit.plugin.network.id.PacketIds1_20;
|
||||
@@ -56,7 +55,6 @@ public class BukkitNetworkManager implements NetworkManager, Listener, PluginMes
|
||||
private final BiConsumer<Object, Object> packetConsumer;
|
||||
private final BiConsumer<Object, Object> immediatePacketConsumer;
|
||||
private final BukkitCraftEngine plugin;
|
||||
private final ViaVersionProtocol viaVersionProtocol;
|
||||
|
||||
private final Map<ChannelPipeline, BukkitServerPlayer> users = new ConcurrentHashMap<>();
|
||||
private final Map<UUID, BukkitServerPlayer> onlineUsers = new ConcurrentHashMap<>();
|
||||
@@ -72,13 +70,13 @@ public class BukkitNetworkManager implements NetworkManager, Listener, PluginMes
|
||||
private static final String PACKET_DECODER = "craftengine_decoder";
|
||||
|
||||
private static boolean hasModelEngine;
|
||||
private static boolean hasViaVersion;
|
||||
|
||||
public BukkitNetworkManager(BukkitCraftEngine plugin) {
|
||||
instance = this;
|
||||
hasModelEngine = Bukkit.getPluginManager().getPlugin("ModelEngine") != null;
|
||||
hasViaVersion = Bukkit.getPluginManager().getPlugin("ViaVersion") != null;
|
||||
this.plugin = plugin;
|
||||
// hook via
|
||||
this.viaVersionProtocol = new ViaVersionProtocol(Bukkit.getPluginManager().getPlugin("ViaVersion") != null);
|
||||
// set up packet id
|
||||
this.packetIds = setupPacketIds();
|
||||
// register packet handlers
|
||||
@@ -304,6 +302,10 @@ public class BukkitNetworkManager implements NetworkManager, Listener, PluginMes
|
||||
return hasModelEngine;
|
||||
}
|
||||
|
||||
public static boolean hasViaVersion() {
|
||||
return hasViaVersion;
|
||||
}
|
||||
|
||||
public void simulatePacket(@NotNull NetWorkUser player, Object packet) {
|
||||
Channel channel = player.nettyChannel();
|
||||
if (channel.isOpen()) {
|
||||
@@ -635,8 +637,4 @@ public class BukkitNetworkManager implements NetworkManager, Listener, PluginMes
|
||||
}
|
||||
return output;
|
||||
}
|
||||
|
||||
public ViaVersionProtocol viaVersionProtocol() {
|
||||
return this.viaVersionProtocol;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -9,8 +9,6 @@ import net.momirealms.craftengine.bukkit.api.CraftEngineFurniture;
|
||||
import net.momirealms.craftengine.bukkit.api.event.FurnitureBreakEvent;
|
||||
import net.momirealms.craftengine.bukkit.api.event.FurnitureInteractEvent;
|
||||
import net.momirealms.craftengine.bukkit.block.BukkitBlockManager;
|
||||
import net.momirealms.craftengine.bukkit.compatibility.modelengine.ModelEngineUtils;
|
||||
import net.momirealms.craftengine.bukkit.compatibility.viaversion.ViaVersionProtocol;
|
||||
import net.momirealms.craftengine.bukkit.entity.furniture.BukkitFurnitureManager;
|
||||
import net.momirealms.craftengine.bukkit.entity.furniture.LoadedFurniture;
|
||||
import net.momirealms.craftengine.bukkit.item.behavior.FurnitureItemBehavior;
|
||||
@@ -64,7 +62,6 @@ public class PacketConsumers {
|
||||
private static int[] mappingsMOD;
|
||||
private static IntIdentityList BLOCK_LIST;
|
||||
private static IntIdentityList BIOME_LIST;
|
||||
private static final UUID EMPTY_UUID = new UUID(0, 0);
|
||||
|
||||
public static void init(Map<Integer, Integer> map, int registrySize) {
|
||||
mappings = new int[registrySize];
|
||||
@@ -1249,9 +1246,8 @@ public class PacketConsumers {
|
||||
player.setConnectionState(ConnectionState.PLAY);
|
||||
Object dimensionKey;
|
||||
if (!VersionHelper.isVersionNewerThan1_20_2()) {
|
||||
ViaVersionProtocol viaVersionProtocol = BukkitNetworkManager.instance().viaVersionProtocol();
|
||||
if (viaVersionProtocol.hasPlugin()) {
|
||||
user.setProtocolVersion(viaVersionProtocol.getPlayerProtocolVersion(player.uuid()));
|
||||
if (BukkitNetworkManager.hasViaVersion()) {
|
||||
user.setProtocolVersion(CraftEngine.instance().compatibilityManager().getPlayerProtocolVersion(player.uuid()));
|
||||
}
|
||||
dimensionKey = Reflections.field$ClientboundLoginPacket$dimension.get(packet);
|
||||
} else {
|
||||
@@ -1590,7 +1586,7 @@ public class PacketConsumers {
|
||||
int entityId;
|
||||
if (BukkitNetworkManager.hasModelEngine()) {
|
||||
int fakeId = FastNMS.INSTANCE.field$ServerboundInteractPacket$entityId(packet);
|
||||
entityId = ModelEngineUtils.interactionToBaseEntity(fakeId);
|
||||
entityId = CraftEngine.instance().compatibilityManager().interactionToBaseEntity(fakeId);
|
||||
} else {
|
||||
entityId = FastNMS.INSTANCE.field$ServerboundInteractPacket$entityId(packet);
|
||||
}
|
||||
@@ -2186,7 +2182,7 @@ public class PacketConsumers {
|
||||
|
||||
public static final TriConsumer<NetWorkUser, NMSPacketEvent, Object> HANDSHAKE_C2S = (user, event, packet) -> {
|
||||
try {
|
||||
if (BukkitNetworkManager.instance().viaVersionProtocol().hasPlugin()) return;
|
||||
if (BukkitNetworkManager.hasViaVersion()) return;
|
||||
int protocolVersion = Reflections.field$ClientIntentionPacket$protocolVersion.getInt(packet);
|
||||
user.setProtocolVersion(protocolVersion);
|
||||
} catch (Exception e) {
|
||||
@@ -2196,9 +2192,8 @@ public class PacketConsumers {
|
||||
|
||||
public static final TriConsumer<NetWorkUser, NMSPacketEvent, Object> LOGIN_ACKNOWLEDGED = (user, event, packet) -> {
|
||||
try {
|
||||
ViaVersionProtocol viaVersionProtocol = BukkitNetworkManager.instance().viaVersionProtocol();
|
||||
if (viaVersionProtocol.hasPlugin()) {
|
||||
user.setProtocolVersion(viaVersionProtocol.getPlayerProtocolVersion(user.uuid()));
|
||||
if (BukkitNetworkManager.hasViaVersion()) {
|
||||
user.setProtocolVersion(CraftEngine.instance().compatibilityManager().getPlayerProtocolVersion(user.uuid()));
|
||||
}
|
||||
} catch (Exception e) {
|
||||
CraftEngine.instance().logger().warn("Failed to handle ServerboundLoginAcknowledgedPacket", e);
|
||||
|
||||
@@ -1,7 +1,5 @@
|
||||
package net.momirealms.craftengine.bukkit.world;
|
||||
|
||||
import net.momirealms.craftengine.bukkit.compatibility.legacy.slimeworld.LegacySlimeFormatStorageAdaptor;
|
||||
import net.momirealms.craftengine.bukkit.compatibility.slimeworld.SlimeFormatStorageAdaptor;
|
||||
import net.momirealms.craftengine.bukkit.nms.FastNMS;
|
||||
import net.momirealms.craftengine.bukkit.plugin.BukkitCraftEngine;
|
||||
import net.momirealms.craftengine.bukkit.plugin.injector.BukkitInjector;
|
||||
@@ -11,7 +9,6 @@ import net.momirealms.craftengine.core.block.ImmutableBlockState;
|
||||
import net.momirealms.craftengine.core.plugin.CraftEngine;
|
||||
import net.momirealms.craftengine.core.plugin.config.Config;
|
||||
import net.momirealms.craftengine.core.plugin.scheduler.SchedulerTask;
|
||||
import net.momirealms.craftengine.core.util.VersionHelper;
|
||||
import net.momirealms.craftengine.core.world.CEWorld;
|
||||
import net.momirealms.craftengine.core.world.ChunkPos;
|
||||
import net.momirealms.craftengine.core.world.SectionPos;
|
||||
@@ -53,32 +50,7 @@ public class BukkitWorldManager implements WorldManager, Listener {
|
||||
instance = this;
|
||||
this.plugin = plugin;
|
||||
this.worlds = new HashMap<>();
|
||||
if (VersionHelper.isVersionNewerThan1_21_4()) {
|
||||
try {
|
||||
Class.forName("com.infernalsuite.asp.api.AdvancedSlimePaperAPI");
|
||||
SlimeFormatStorageAdaptor adaptor = new SlimeFormatStorageAdaptor(this);
|
||||
this.storageAdaptor = adaptor;
|
||||
Bukkit.getPluginManager().registerEvents(adaptor, plugin.bootstrap());
|
||||
return;
|
||||
} catch (ClassNotFoundException ignored) {
|
||||
}
|
||||
} else {
|
||||
try {
|
||||
Class.forName("com.infernalsuite.aswm.api.SlimePlugin");
|
||||
LegacySlimeFormatStorageAdaptor adaptor = new LegacySlimeFormatStorageAdaptor(this, 1);
|
||||
this.storageAdaptor = adaptor;
|
||||
Bukkit.getPluginManager().registerEvents(adaptor, plugin.bootstrap());
|
||||
} catch (ClassNotFoundException ignored) {
|
||||
if (Bukkit.getPluginManager().isPluginEnabled("SlimeWorldPlugin")) {
|
||||
LegacySlimeFormatStorageAdaptor adaptor = new LegacySlimeFormatStorageAdaptor(this, 2);
|
||||
this.storageAdaptor = adaptor;
|
||||
Bukkit.getPluginManager().registerEvents(adaptor, plugin.bootstrap());
|
||||
}
|
||||
}
|
||||
}
|
||||
if (this.storageAdaptor == null) {
|
||||
this.storageAdaptor = new DefaultStorageAdaptor();
|
||||
}
|
||||
this.storageAdaptor = new DefaultStorageAdaptor();
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -15,6 +15,7 @@ import org.jetbrains.annotations.Nullable;
|
||||
import java.util.Collection;
|
||||
import java.util.Map;
|
||||
import java.util.Optional;
|
||||
import java.util.UUID;
|
||||
|
||||
public interface FontManager extends Manageable {
|
||||
Key DEFAULT_FONT = Key.of("minecraft:default");
|
||||
@@ -103,4 +104,6 @@ public interface FontManager extends Manageable {
|
||||
}
|
||||
|
||||
Map<String, Component> matchTags(String json);
|
||||
|
||||
void refreshEmojiSuggestions(UUID uuid);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,31 @@
|
||||
package net.momirealms.craftengine.core.plugin;
|
||||
|
||||
import net.momirealms.craftengine.core.entity.furniture.AbstractExternalModel;
|
||||
import net.momirealms.craftengine.core.entity.player.Player;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
public interface CompatibilityManager {
|
||||
|
||||
void onLoad();
|
||||
|
||||
void onEnable();
|
||||
|
||||
void onDelayedEnable();
|
||||
|
||||
AbstractExternalModel createModelEngineModel(String id);
|
||||
|
||||
AbstractExternalModel createBetterModelModel(String id);
|
||||
|
||||
int interactionToBaseEntity(int id);
|
||||
|
||||
boolean hasPlaceholderAPI();
|
||||
|
||||
boolean isPluginEnabled(String plugin);
|
||||
|
||||
boolean hasPlugin(String plugin);
|
||||
|
||||
String parse(Player player, String text);
|
||||
|
||||
int getPlayerProtocolVersion(UUID uuid);
|
||||
}
|
||||
@@ -68,6 +68,7 @@ public abstract class CraftEngine implements Plugin {
|
||||
protected SoundManager soundManager;
|
||||
protected VanillaLootManager vanillaLootManager;
|
||||
protected AdvancementManager advancementManager;
|
||||
protected CompatibilityManager compatibilityManager;
|
||||
|
||||
private final Consumer<CraftEngine> reloadEventDispatcher;
|
||||
private boolean isReloading;
|
||||
@@ -371,8 +372,6 @@ public abstract class CraftEngine implements Plugin {
|
||||
return isInitializing;
|
||||
}
|
||||
|
||||
public abstract boolean hasPlaceholderAPI();
|
||||
|
||||
@Override
|
||||
public DependencyManager dependencyManager() {
|
||||
return dependencyManager;
|
||||
@@ -460,4 +459,9 @@ public abstract class CraftEngine implements Plugin {
|
||||
public VanillaLootManager vanillaLootManager() {
|
||||
return vanillaLootManager;
|
||||
}
|
||||
|
||||
@Override
|
||||
public CompatibilityManager compatibilityManager() {
|
||||
return compatibilityManager;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -90,7 +90,5 @@ public interface Plugin {
|
||||
|
||||
void debug(Supplier<String> message);
|
||||
|
||||
boolean isPluginEnabled(String plugin);
|
||||
|
||||
String parse(Player player, String text);
|
||||
CompatibilityManager compatibilityManager();
|
||||
}
|
||||
|
||||
@@ -20,11 +20,11 @@ public class PlaceholderTag implements TagResolver {
|
||||
|
||||
@Override
|
||||
public @Nullable Tag resolve(@NotNull String name, @NotNull ArgumentQueue arguments, @NotNull Context ctx) throws ParsingException {
|
||||
if (!this.has(name) || !CraftEngine.instance().hasPlaceholderAPI()) {
|
||||
if (!this.has(name) || !CraftEngine.instance().compatibilityManager().hasPlaceholderAPI()) {
|
||||
return null;
|
||||
}
|
||||
String placeholder = arguments.popOr("No argument placeholder provided").toString();
|
||||
String parsed = CraftEngine.instance().parse(player, "%" + placeholder + "%");
|
||||
String parsed = CraftEngine.instance().compatibilityManager().parse(player, "%" + placeholder + "%");
|
||||
return Tag.inserting(AdventureHelper.miniMessage().deserialize(parsed));
|
||||
}
|
||||
|
||||
|
||||
@@ -0,0 +1,9 @@
|
||||
package net.momirealms.craftengine.core.util;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
public final class UUIDUtils {
|
||||
public static final UUID EMPTY = new UUID(0, 0);
|
||||
|
||||
private UUIDUtils() {}
|
||||
}
|
||||
@@ -50,7 +50,7 @@ byte_buddy_version=1.17.5
|
||||
ahocorasick_version=0.6.3
|
||||
snake_yaml_version=2.4
|
||||
anti_grief_version=0.15
|
||||
nms_helper_version=0.61.7
|
||||
nms_helper_version=0.61.8
|
||||
reactive_streams_version=1.0.4
|
||||
amazon_awssdk_version=2.31.23
|
||||
amazon_awssdk_eventstream_version=1.0.1
|
||||
|
||||
Reference in New Issue
Block a user