新增op可绕过经济检查
All checks were successful
Java CI-CD with Maven / build (push) Successful in 8m5s

This commit is contained in:
zhangyuheng 2024-07-21 01:47:07 +08:00
parent 00193c5cb9
commit 9a11f4b1f9
4 changed files with 7 additions and 3 deletions

View File

@ -6,7 +6,7 @@
<groupId>cn.lunadeer</groupId>
<artifactId>Dominion</artifactId>
<version>1.38.5-beta</version>
<version>1.38.6-beta</version>
<packaging>jar</packaging>
<name>Dominion</name>

View File

@ -43,7 +43,7 @@ public class Apis {
Location location2 = new Location(location.getWorld(), location.getX() + size, location.getY() + size, location.getZ() + size);
if (Dominion.config.getLimitVert()) {
location1.setY(Dominion.config.getLimitMinY());
location2.setY(Dominion.config.getLimitMaxY());
location2.setY(Dominion.config.getLimitMaxY() - 1);
}
Map<Integer, Location> points = new HashMap<>();
points.put(0, location1);

View File

@ -765,6 +765,10 @@ public class DominionController {
operator.setResponse(FAIL.addMessage("没有可用的经济插件系统,请联系服主。"));
return true;
}
if (operator.isOp() && Dominion.config.getLimitOpBypass()) {
SUCCESS.addMessage("你是OP已跳过经济检查。");
return false;
}
float priceOrRefund = count * Dominion.config.getEconomyPrice();
if (paid) {
if (VaultConnect.instance.getBalance(operator.getPlayer()) < priceOrRefund) {

View File

@ -52,7 +52,7 @@ public class SelectPointEvents implements Listener {
Notification.info(player, "已选择第二个点: %d %d %d", block.getX(), block.getY(), block.getZ());
Location loc = block.getLocation();
if (Dominion.config.getLimitVert()) {
loc.setY(Dominion.config.getLimitMaxY());
loc.setY(Dominion.config.getLimitMaxY() - 1);
}
points.put(1, loc);
} else {