mirror of
https://github.com/CitizensDev/Citizens2.git
synced 2025-01-25 01:21:24 +01:00
Bump adventure dependency
This commit is contained in:
parent
ea2df83ca5
commit
4e4112d531
@ -10,7 +10,7 @@
|
||||
<properties>
|
||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||
<craftbukkit.version>1.20.4-R0.1-SNAPSHOT</craftbukkit.version>
|
||||
<placeholderapi.version>2.11.2</placeholderapi.version>
|
||||
<placeholderapi.version>2.11.5</placeholderapi.version>
|
||||
<citizensapi.version>${project.version}</citizensapi.version>
|
||||
<worldguard.version>7.1.0-SNAPSHOT</worldguard.version>
|
||||
<powermock.version>1.4.12</powermock.version>
|
||||
@ -121,13 +121,13 @@
|
||||
<dependency>
|
||||
<groupId>net.kyori</groupId>
|
||||
<artifactId>adventure-text-minimessage</artifactId>
|
||||
<version>4.14.0</version>
|
||||
<version>4.15.0</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>net.kyori</groupId>
|
||||
<artifactId>adventure-platform-bukkit</artifactId>
|
||||
<version>4.3.1</version>
|
||||
<version>4.3.2</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
@ -275,6 +275,10 @@ public class Citizens extends JavaPlugin implements CitizensPlugin {
|
||||
return getClassLoader();
|
||||
}
|
||||
|
||||
public ProtocolLibListener getProtocolLibListener() {
|
||||
return protocolListener;
|
||||
}
|
||||
|
||||
public StoredShops getShops() {
|
||||
return shops;
|
||||
}
|
||||
@ -296,21 +300,21 @@ public class Citizens extends JavaPlugin implements CitizensPlugin {
|
||||
lib.loadLibrary(Library.builder().groupId("net{}sf{}trove4j").artifactId("trove4j").version("3.0.3")
|
||||
.relocate("gnu{}trove", "clib{}trove").build());
|
||||
lib.loadLibrary(Library.builder().groupId("net{}kyori").artifactId("adventure-text-minimessage")
|
||||
.version("4.14.0").relocate("net{}kyori", "clib{}net{}kyori").build());
|
||||
lib.loadLibrary(Library.builder().groupId("net{}kyori").artifactId("adventure-api").version("4.14.0")
|
||||
.version("4.15.0").relocate("net{}kyori", "clib{}net{}kyori").build());
|
||||
lib.loadLibrary(Library.builder().groupId("net{}kyori").artifactId("adventure-api").version("4.15.0")
|
||||
.relocate("net{}kyori", "clib{}net{}kyori").build());
|
||||
lib.loadLibrary(Library.builder().groupId("net{}kyori").artifactId("adventure-key").version("4.14.0")
|
||||
lib.loadLibrary(Library.builder().groupId("net{}kyori").artifactId("adventure-key").version("4.15.0")
|
||||
.relocate("net{}kyori", "clib{}net{}kyori").build());
|
||||
lib.loadLibrary(Library.builder().groupId("net{}kyori").artifactId("examination-api").version("1.3.0")
|
||||
.relocate("net{}kyori", "clib{}net{}kyori").build());
|
||||
lib.loadLibrary(Library.builder().groupId("net{}kyori").artifactId("examination-string").version("1.3.0")
|
||||
.relocate("net{}kyori", "clib{}net{}kyori").build());
|
||||
lib.loadLibrary(Library.builder().groupId("net{}kyori").artifactId("adventure-platform-bukkit").version("4.3.1")
|
||||
lib.loadLibrary(Library.builder().groupId("net{}kyori").artifactId("adventure-platform-bukkit").version("4.3.2")
|
||||
.relocate("net{}kyori", "clib{}net{}kyori").build());
|
||||
lib.loadLibrary(Library.builder().groupId("net{}kyori").artifactId("adventure-platform-api").version("4.3.1")
|
||||
lib.loadLibrary(Library.builder().groupId("net{}kyori").artifactId("adventure-platform-api").version("4.3.2")
|
||||
.relocate("net{}kyori", "clib{}net{}kyori").build());
|
||||
lib.loadLibrary(Library.builder().groupId("net{}kyori").artifactId("adventure-text-serializer-bungeecord")
|
||||
.version("4.3.1").relocate("net{}kyori", "clib{}net{}kyori").build());
|
||||
.version("4.3.2").relocate("net{}kyori", "clib{}net{}kyori").build());
|
||||
lib.loadLibrary(Library.builder().groupId("net{}kyori").artifactId("adventure-text-serializer-legacy")
|
||||
.version("4.13.1").relocate("net{}kyori", "clib{}net{}kyori").build());
|
||||
lib.loadLibrary(Library.builder().groupId("net{}kyori").artifactId("adventure-nbt").version("4.13.1")
|
||||
@ -319,10 +323,10 @@ public class Citizens extends JavaPlugin implements CitizensPlugin {
|
||||
.version("4.13.1").relocate("net{}kyori", "clib{}net{}kyori").build());
|
||||
lib.loadLibrary(Library.builder().groupId("net{}kyori").artifactId("adventure-text-serializer-gson-legacy-impl")
|
||||
.version("4.13.1").relocate("net{}kyori", "clib{}net{}kyori").build());
|
||||
lib.loadLibrary(Library.builder().groupId("net{}kyori").artifactId("adventure-platform-facet").version("4.3.1")
|
||||
lib.loadLibrary(Library.builder().groupId("net{}kyori").artifactId("adventure-platform-facet").version("4.3.2")
|
||||
.relocate("net{}kyori", "clib{}net{}kyori").build());
|
||||
lib.loadLibrary(Library.builder().groupId("net{}kyori").artifactId("adventure-platform-viaversion")
|
||||
.version("4.3.1").relocate("net{}kyori", "clib{}net{}kyori").build());
|
||||
.version("4.3.2").relocate("net{}kyori", "clib{}net{}kyori").build());
|
||||
try {
|
||||
Class.forName("org.joml.Vector3f");
|
||||
} catch (Throwable t) {
|
||||
|
@ -55,6 +55,7 @@ import com.google.common.collect.Lists;
|
||||
import com.google.common.io.BaseEncoding;
|
||||
|
||||
import net.citizensnpcs.Citizens;
|
||||
import net.citizensnpcs.ProtocolLibListener;
|
||||
import net.citizensnpcs.Settings.Setting;
|
||||
import net.citizensnpcs.StoredShops;
|
||||
import net.citizensnpcs.api.CitizensAPI;
|
||||
@ -162,6 +163,7 @@ import net.citizensnpcs.util.Util;
|
||||
@Requirements(selected = true, ownership = true)
|
||||
public class NPCCommands {
|
||||
private final CommandHistory history;
|
||||
private final ProtocolLibListener protocolListener;
|
||||
private final NPCSelector selector;
|
||||
private final StoredShops shops;
|
||||
private final NPCRegistry temporaryRegistry;
|
||||
@ -171,6 +173,7 @@ public class NPCCommands {
|
||||
shops = plugin.getShops();
|
||||
temporaryRegistry = CitizensAPI.createCitizensBackedNPCRegistry(new MemoryNPCDataStore());
|
||||
history = new CommandHistory(selector);
|
||||
protocolListener = plugin.getProtocolLibListener();
|
||||
}
|
||||
|
||||
@Command(
|
||||
@ -1703,7 +1706,11 @@ public class NPCCommands {
|
||||
max = 1,
|
||||
permission = "citizens.npc.mirror")
|
||||
@Requirements(selected = true, ownership = true)
|
||||
public void mirror(CommandContext args, CommandSender sender, NPC npc, @Flag("name") Boolean name) {
|
||||
public void mirror(CommandContext args, CommandSender sender, NPC npc, @Flag("name") Boolean name)
|
||||
throws CommandException {
|
||||
if (protocolListener == null)
|
||||
throw new CommandException("ProtocolLib must be enabled to use this feature");
|
||||
|
||||
MirrorTrait trait = npc.getOrAddTrait(MirrorTrait.class);
|
||||
if (name != null) {
|
||||
trait.setEnabled(true);
|
||||
|
Loading…
Reference in New Issue
Block a user