Skip to content

Commit

Permalink
rm: 移除LibsDisguises依赖
Browse files Browse the repository at this point in the history
rm: 移除GSit集成
  • Loading branch information
MATRIX-feather committed Dec 16, 2023
1 parent 4ce9900 commit 603277d
Show file tree
Hide file tree
Showing 11 changed files with 10 additions and 1,199 deletions.
12 changes: 6 additions & 6 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,10 @@ repositories {
url = uri("https://repo.extendedclip.com/content/repositories/placeholderapi/")
}

maven {
url = uri("https://repo.dmulloy2.net/repository/public/")
}

maven {
url = uri("https://repo.maven.apache.org/maven2/")
}
Expand All @@ -44,11 +48,7 @@ repositories {
dependencies {
paperweight.paperDevBundle("${project.property("minecraft_version")}")

compileOnly("LibsDisguises:LibsDisguises:${project.property("ld_version")}")
{
exclude("org.spigotmc", "spigot-api")
exclude("org.spigotmc", "spigot")
}
compileOnly("com.comphenix.protocol:ProtocolLib:${project.property("protocollib_version")}")

compileOnly(files("libs/CMILib1.4.3.5.jar"))
compileOnly(files("libs/Residence5.1.4.0.jar"))
Expand All @@ -70,7 +70,7 @@ dependencies {
exclude("com.google.code.gson", "gson")
}

compileOnly("com.github.Gecolay:GSit:${project.property("gsit_version")}")
//compileOnly("com.github.Gecolay:GSit:${project.property("gsit_version")}")
compileOnly("me.clip:placeholderapi:${project.property("papi_version")}")
}

Expand Down
3 changes: 2 additions & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@ protocols_local_version=0.13.2
minecraft_version=1.20.4-R0.1-SNAPSHOT

# Dependencies
ld_version=10.0.33
protocollib_version=5.1.0
#ld_version=10.0.33
pluginbase_version=306d580
gsit_version=1.6.0
papi_version=2.11.5
Expand Down
24 changes: 2 additions & 22 deletions src/main/java/xiamomc/morph/MorphManager.java
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
import xiamomc.morph.backends.DisguiseBackend;
import xiamomc.morph.backends.DisguiseWrapper;
import xiamomc.morph.backends.fallback.NilBackend;
import xiamomc.morph.backends.libsdisg.LibsBackend;
import xiamomc.morph.backends.server.ServerBackend;
import xiamomc.morph.config.ConfigOption;
import xiamomc.morph.config.MorphConfigManager;
Expand Down Expand Up @@ -120,31 +119,12 @@ private void tryBackends()
}
catch (NoClassDefFoundError e)
{
logger.error("Unable to initialize renderer as our disguise backend, maybe ProtocolLib it's not installed on the server.");
logger.error("Trying LibsBackend...");
}
catch (Throwable t)
{
logger.error("Unable to initialize renderer as our disguise backend: " + t.getMessage());
logger.error("Please consider reporting this issue to our GitHub: https://github.com/XiaMoZhiShi/MorphPlugin/issues");
logger.error("Trying LibsBackend...");

t.printStackTrace();
}

try
{
this.currentBackend = new LibsBackend();
return;
}
catch (NoClassDefFoundError e)
{
logger.error("Unable to initialize LibsDisguises as our disguise backend, maybe it's not installed on the server.");
logger.error("Unable to initialize ServerBackend as our disguise backend, maybe ProtocolLib is not installed on the server.");
logger.error("Using NilBackend, displaying disguises at the server side will not be supported this run.");
}
catch (Throwable t)
{
logger.error("Unable to initialize LibsDisguises as our disguise backend: " + t.getMessage());
logger.error("Unable to initialize ServerBackend as our disguise backend: " + t.getMessage());
logger.error("Using NilBackend, displaying disguises at the server side will not be supported this run.");
logger.error("Please consider reporting this issue to our GitHub: https://github.com/XiaMoZhiShi/MorphPlugin/issues");

Expand Down
9 changes: 0 additions & 9 deletions src/main/java/xiamomc/morph/MorphPlugin.java
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@
import xiamomc.morph.misc.PlayerOperationSimulator;
import xiamomc.morph.misc.integrations.residence.ResidenceEventProcessor;
import xiamomc.morph.updates.UpdateHandler;
import xiamomc.morph.misc.integrations.gsit.GSitCompactProcessor;
import xiamomc.morph.misc.integrations.placeholderapi.PlaceholderIntegration;
import xiamomc.morph.network.server.MorphClientHandler;
import xiamomc.morph.skills.MorphSkillHandler;
Expand All @@ -30,8 +29,6 @@
import xiamomc.pluginbase.Messages.MessageStore;
import xiamomc.pluginbase.XiaMoJavaPlugin;

import java.util.Arrays;

public final class MorphPlugin extends XiaMoJavaPlugin
{
private static MorphPlugin instance;
Expand Down Expand Up @@ -96,12 +93,6 @@ public void onEnable()

var playerTracker = new PlayerTracker();

softDeps.setHandle("GSit", s ->
{
logger.info("GSit detected, applying integrations...");
this.registerListener(new GSitCompactProcessor());
}, true);

softDeps.setHandle("PlaceholderAPI", p ->
{
logger.info("Registering Placeholders...");
Expand Down
220 changes: 0 additions & 220 deletions src/main/java/xiamomc/morph/backends/libsdisg/LibsBackend.java

This file was deleted.

Loading

0 comments on commit 603277d

Please sign in to comment.