mirror of
https://github.com/IntellectualSites/PlotSquared.git
synced 2025-07-01 13:14:43 +02:00
Update MiniMessage to 4.10.1 (#3617)
* chore!: bump MiniMessage to 4.10.1 BREAKING CHANGE: bumping MiniMessage and Adventure removes the adventure Template class and breaks the whole messaging system api wise * chore: fix minimessage messages, fix circular method reference
This commit is contained in:

committed by
GitHub

parent
d5f8a0842b
commit
62ee60a76c
@ -50,7 +50,9 @@ import com.plotsquared.core.util.EntityUtil;
|
||||
import com.plotsquared.core.util.Permissions;
|
||||
import com.plotsquared.core.util.entity.EntityCategories;
|
||||
import com.sk89q.worldedit.bukkit.BukkitAdapter;
|
||||
import net.kyori.adventure.text.minimessage.Template;
|
||||
import net.kyori.adventure.text.Component;
|
||||
import net.kyori.adventure.text.minimessage.tag.Tag;
|
||||
import net.kyori.adventure.text.minimessage.tag.resolver.TagResolver;
|
||||
import org.bukkit.entity.Arrow;
|
||||
import org.bukkit.entity.Creature;
|
||||
import org.bukkit.entity.Entity;
|
||||
@ -188,7 +190,10 @@ public class BukkitEntityUtil {
|
||||
if (!Permissions.hasPermission(plotPlayer, Permission.PERMISSION_ADMIN_DESTROY + "." + stub)) {
|
||||
plotPlayer.sendMessage(
|
||||
TranslatableCaption.of("permission.no_permission_event"),
|
||||
Template.of("node", Permission.PERMISSION_ADMIN_DESTROY + "." + stub)
|
||||
TagResolver.resolver(
|
||||
"node",
|
||||
Tag.inserting(Component.text(Permission.PERMISSION_ADMIN_DESTROY + "." + stub))
|
||||
)
|
||||
);
|
||||
return false;
|
||||
}
|
||||
@ -200,7 +205,10 @@ public class BukkitEntityUtil {
|
||||
if (!Permissions.hasPermission(plotPlayer, Permission.PERMISSION_ADMIN_DESTROY + "." + stub)) {
|
||||
plotPlayer.sendMessage(
|
||||
TranslatableCaption.of("permission.no_permission_event"),
|
||||
Template.of("node", Permission.PERMISSION_ADMIN_DESTROY + "." + stub)
|
||||
TagResolver.resolver(
|
||||
"node",
|
||||
Tag.inserting(Component.text(Permission.PERMISSION_ADMIN_DESTROY + "." + stub))
|
||||
)
|
||||
);
|
||||
if (plot != null) {
|
||||
plot.debug(player.getName()
|
||||
@ -221,7 +229,10 @@ public class BukkitEntityUtil {
|
||||
if (!Permissions.hasPermission(plotPlayer, Permission.PERMISSION_ADMIN_PVE + "." + stub)) {
|
||||
plotPlayer.sendMessage(
|
||||
TranslatableCaption.of("permission.no_permission_event"),
|
||||
Template.of("node", Permission.PERMISSION_ADMIN_PVE + "." + stub)
|
||||
TagResolver.resolver(
|
||||
"node",
|
||||
Tag.inserting(Component.text(Permission.PERMISSION_ADMIN_PVE + "." + stub))
|
||||
)
|
||||
);
|
||||
if (plot != null) {
|
||||
plot.debug(player.getName() + " could not attack " + entityType
|
||||
@ -242,7 +253,10 @@ public class BukkitEntityUtil {
|
||||
if (!Permissions.hasPermission(plotPlayer, Permission.PERMISSION_ADMIN_PVE + "." + stub)) {
|
||||
plotPlayer.sendMessage(
|
||||
TranslatableCaption.of("permission.no_permission_event"),
|
||||
Template.of("node", Permission.PERMISSION_ADMIN_PVE + "." + stub)
|
||||
TagResolver.resolver(
|
||||
"node",
|
||||
Tag.inserting(Component.text(Permission.PERMISSION_ADMIN_PVE + "." + stub))
|
||||
)
|
||||
);
|
||||
if (plot != null) {
|
||||
plot.debug(player.getName() + " could not attack " + entityType
|
||||
@ -256,7 +270,10 @@ public class BukkitEntityUtil {
|
||||
.hasPermission(plotPlayer, Permission.PERMISSION_ADMIN_PVP + "." + stub)) {
|
||||
plotPlayer.sendMessage(
|
||||
TranslatableCaption.of("permission.no_permission_event"),
|
||||
Template.of("node", Permission.PERMISSION_ADMIN_PVP + "." + stub)
|
||||
TagResolver.resolver(
|
||||
"node",
|
||||
Tag.inserting(Component.text(Permission.PERMISSION_ADMIN_PVP + "." + stub))
|
||||
)
|
||||
);
|
||||
plot.debug(player.getName() + " could not attack " + entityType
|
||||
+ " because pve = false");
|
||||
@ -270,7 +287,10 @@ public class BukkitEntityUtil {
|
||||
if (!Permissions.hasPermission(plotPlayer, Permission.PERMISSION_ADMIN_PVP + "." + stub)) {
|
||||
plotPlayer.sendMessage(
|
||||
TranslatableCaption.of("permission.no_permission_event"),
|
||||
Template.of("node", Permission.PERMISSION_ADMIN_PVP + "." + stub)
|
||||
TagResolver.resolver(
|
||||
"node",
|
||||
Tag.inserting(Component.text(Permission.PERMISSION_ADMIN_PVP + "." + stub))
|
||||
)
|
||||
);
|
||||
return false;
|
||||
}
|
||||
@ -287,7 +307,10 @@ public class BukkitEntityUtil {
|
||||
if (!Permissions.hasPermission(plotPlayer, Permission.PERMISSION_ADMIN_PVE + "." + stub)) {
|
||||
plotPlayer.sendMessage(
|
||||
TranslatableCaption.of("permission.no_permission_event"),
|
||||
Template.of("node", Permission.PERMISSION_ADMIN_PVE + "." + stub)
|
||||
TagResolver.resolver(
|
||||
"node",
|
||||
Tag.inserting(Component.text(Permission.PERMISSION_ADMIN_PVE + "." + stub))
|
||||
)
|
||||
);
|
||||
if (plot != null) {
|
||||
plot.debug(player.getName() + " could not attack " + entityType
|
||||
@ -309,7 +332,10 @@ public class BukkitEntityUtil {
|
||||
if (!Permissions.hasPermission(plotPlayer, Permission.PERMISSION_ADMIN_PVE + "." + stub)) {
|
||||
plotPlayer.sendMessage(
|
||||
TranslatableCaption.of("permission.no_permission_event"),
|
||||
Template.of("node", Permission.PERMISSION_ADMIN_PVE + "." + stub)
|
||||
TagResolver.resolver(
|
||||
"node",
|
||||
Tag.inserting(Component.text(Permission.PERMISSION_ADMIN_PVE + "." + stub))
|
||||
)
|
||||
);
|
||||
if (plot != null) {
|
||||
plot.debug(player.getName() + " could not attack " + entityType
|
||||
|
Reference in New Issue
Block a user