新增op可无视自定义权限节点
All checks were successful
Java CI-CD with Maven / build (push) Successful in 11m49s

This commit is contained in:
zhangyuheng 2024-07-12 21:09:43 +08:00
parent b52fce2479
commit d629b1daf7
2 changed files with 5 additions and 2 deletions

View File

@ -6,7 +6,7 @@
<groupId>cn.lunadeer</groupId>
<artifactId>MiniPlayerTitle</artifactId>
<version>4.3.0</version>
<version>4.3.1</version>
<packaging>jar</packaging>
<name>MiniPlayerTitle</name>

View File

@ -201,7 +201,10 @@ public class TitleManage {
Notification.error(sender, "该命令只能由玩家执行");
return;
}
if (!sender.hasPermission("mplt.custom")) return;
if (!sender.hasPermission("mplt.custom") || !sender.isOp()) {
Notification.error(sender, "你没有权限使用该命令");
return;
}
Player player = (Player) sender;
if (!MiniPlayerTitle.config.isEnableCustom()) {
Notification.error(sender, "自定义称号功能已关闭");