9
0
mirror of https://github.com/LeavesMC/Leaves.git synced 2025-12-29 11:59:17 +00:00

remove unused imports and codes

This commit is contained in:
MC_XiaoHei
2025-07-03 21:21:12 +08:00
parent 1aea18e943
commit a701c8b93d
10 changed files with 0 additions and 76 deletions

View File

@@ -3,9 +3,7 @@ package org.leavesmc.leaves;
import com.destroystokyo.paper.util.SneakyThrow;
import io.papermc.paper.configuration.GlobalConfiguration;
import net.minecraft.server.MinecraftServer;
import net.minecraft.server.level.ServerLevel;
import net.minecraft.server.level.ServerPlayer;
import net.minecraft.world.entity.Entity;
import net.minecraft.world.entity.player.Player;
import org.bukkit.command.Command;
import org.bukkit.configuration.file.YamlConfiguration;
@@ -30,18 +28,15 @@ import org.leavesmc.leaves.protocol.CarpetServerProtocol.CarpetRules;
import org.leavesmc.leaves.protocol.bladeren.BladerenProtocol.LeavesFeature;
import org.leavesmc.leaves.protocol.bladeren.BladerenProtocol.LeavesFeatureSet;
import org.leavesmc.leaves.region.RegionFileFormat;
import org.leavesmc.leaves.util.ForcePeacefulModeSwitchType;
import org.leavesmc.leaves.util.MathUtils;
import java.io.File;
import java.io.IOException;
import java.util.ArrayList;
import java.util.Collections;
import java.util.HashSet;
import java.util.List;
import java.util.Locale;
import java.util.Random;
import java.util.Set;
import java.util.function.Predicate;
public final class LeavesConfig {

View File

@@ -17,7 +17,6 @@ import net.minecraft.server.level.ServerPlayer;
import net.minecraft.util.ProblemReporter;
import net.minecraft.world.entity.Entity;
import net.minecraft.world.level.Level;
import net.minecraft.world.level.storage.TagValueInput;
import net.minecraft.world.level.storage.ValueInput;
import org.bukkit.Bukkit;
import org.bukkit.Location;
@@ -31,7 +30,6 @@ import org.leavesmc.leaves.event.bot.BotJoinEvent;
import org.leavesmc.leaves.event.bot.BotLoadEvent;
import org.leavesmc.leaves.event.bot.BotRemoveEvent;
import org.leavesmc.leaves.event.bot.BotSpawnLocationEvent;
import org.leavesmc.leaves.util.TagFactory;
import org.slf4j.Logger;
import java.util.List;

View File

@@ -3,13 +3,11 @@ package org.leavesmc.leaves.bot;
import io.netty.channel.ChannelFutureListener;
import net.minecraft.network.Connection;
import net.minecraft.network.DisconnectionDetails;
import net.minecraft.network.PacketSendListener;
import net.minecraft.network.protocol.Packet;
import net.minecraft.network.protocol.PacketFlow;
import net.minecraft.server.MinecraftServer;
import net.minecraft.server.network.CommonListenerCookie;
import net.minecraft.server.network.ServerGamePacketListenerImpl;
import org.bukkit.event.player.PlayerKickEvent;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;

View File

@@ -21,7 +21,6 @@ import java.util.Arrays;
import java.util.HashSet;
import java.util.List;
import java.util.Set;
import java.util.concurrent.atomic.AtomicInteger;
import static net.kyori.adventure.text.Component.text;

View File

@@ -1,6 +1,5 @@
package org.leavesmc.leaves.entity;
import com.google.common.base.Function;
import com.google.common.collect.Lists;
import net.minecraft.server.MinecraftServer;
import org.bukkit.Location;

View File

@@ -31,7 +31,6 @@ import org.leavesmc.leaves.protocol.core.LeavesCustomPayload;
import org.leavesmc.leaves.protocol.core.LeavesProtocol;
import org.leavesmc.leaves.protocol.core.ProtocolHandler;
import org.leavesmc.leaves.protocol.core.ProtocolUtils;
import org.leavesmc.leaves.util.TagFactory;
import org.leavesmc.leaves.util.TagUtil;
import java.util.HashMap;

View File

@@ -1,7 +1,6 @@
package org.leavesmc.leaves.protocol.core.invoker;
import net.minecraft.resources.ResourceLocation;
import net.minecraft.server.level.ServerPlayer;
import org.leavesmc.leaves.protocol.core.IdentifierSelector;
import org.leavesmc.leaves.protocol.core.LeavesProtocol;
import org.leavesmc.leaves.protocol.core.ProtocolHandler;

View File

@@ -5,7 +5,6 @@ import net.minecraft.core.Direction;
import net.minecraft.core.Vec3i;
import net.minecraft.nbt.CompoundTag;
import net.minecraft.nbt.ListTag;
import net.minecraft.server.MinecraftServer;
import net.minecraft.server.level.ServerLevel;
import net.minecraft.world.Container;
import net.minecraft.world.entity.Display;

View File

@@ -10,7 +10,6 @@ import net.minecraft.nbt.NbtOps;
import net.minecraft.nbt.Tag;
import net.minecraft.network.Connection;
import net.minecraft.network.ConnectionProtocol;
import net.minecraft.network.PacketSendListener;
import net.minecraft.network.protocol.BundlePacket;
import net.minecraft.network.protocol.Packet;
import net.minecraft.network.protocol.PacketFlow;

View File

@@ -1,61 +0,0 @@
package org.leavesmc.leaves.util;
import net.minecraft.world.entity.Entity;
import net.minecraft.world.entity.monster.*;
import net.minecraft.world.entity.monster.breeze.Breeze;
import net.minecraft.world.entity.monster.hoglin.Hoglin;
import net.minecraft.world.entity.monster.piglin.Piglin;
import net.minecraft.world.entity.monster.piglin.PiglinBrute;
import net.minecraft.world.entity.monster.warden.Warden;
import net.minecraft.world.entity.boss.wither.WitherBoss;
public enum ForcePeacefulModeSwitchType {
BLAZE(Blaze.class),
CREEPER(Creeper.class),
DROWNED(Drowned.class),
ELDER_GUARDIAN(ElderGuardian.class),
ENDERMAN(EnderMan.class),
ENDERMITE(Endermite.class),
EVOKER(Evoker.class),
GHAST(Ghast.class),
GIANT(Giant.class),
GUARDIAN(Guardian.class),
HOGLIN(Hoglin.class),
HUSK(Husk.class),
ILLUSIONER(Illusioner.class),
MAGMA_CUBE(MagmaCube.class),
PHANTOM(Phantom.class),
PIGLIN(Piglin.class),
PIGLIN_BRUTE(PiglinBrute.class),
PILLAGER(Pillager.class),
RAVAGER(Ravager.class),
SHULKER(Shulker.class),
SILVERFISH(Silverfish.class),
SKELETON(Skeleton.class),
SLIME(Slime.class),
SPIDER(Spider.class),
STRAY(Stray.class),
VEX(Vex.class),
VINDICATOR(Vindicator.class),
WARDEN(Warden.class),
WITCH(Witch.class),
WITHER_SKELETON(WitherSkeleton.class),
ZOGLIN(Zoglin.class),
ZOMBIE(Zombie.class),
ZOMBIE_VILLAGER(ZombieVillager.class),
ZOMBIFIED_PIGLIN(ZombifiedPiglin.class),
WITHER(WitherBoss.class),
CAVE_SPIDER(CaveSpider.class),
BREEZE(Breeze.class),
BOGGED(Bogged.class);
private final Class<? extends Entity> entityClass;
ForcePeacefulModeSwitchType(Class<? extends Entity> entityClass) {
this.entityClass = entityClass;
}
public Class<? extends Entity> getEntityClass() {
return entityClass;
}
}