mirror of
https://github.com/CarmJos/UltraDepository.git
synced 2024-09-19 19:55:45 +00:00
[v1.1.8] [U] 添加安静模式下不收到提示。
This commit is contained in:
parent
27ad14c7ab
commit
fcdda893f1
@ -176,6 +176,9 @@
|
||||
# UltraDepository.use
|
||||
- 超级仓库的基本使用权限 (默认所有人都有)
|
||||
|
||||
# UltraDepository.silent
|
||||
- 拥有该权限将不再接收到放入背包的提示。
|
||||
|
||||
# UltraDepository.Command.Sell
|
||||
- 玩家使用Sell指令的权限
|
||||
|
||||
|
@ -165,11 +165,13 @@ public class DepositoryManager {
|
||||
int finalAmount = collectItemEvent.getItemAmount();
|
||||
|
||||
collectItemEvent.getUserData().addItemAmount(depository.getIdentifier(), typeID, finalAmount);
|
||||
PluginMessages.COLLECTED.send(player, new Object[]{
|
||||
depository.getItems().get(typeID).getName(),
|
||||
finalAmount, depository.getName()
|
||||
});
|
||||
PluginConfig.Sounds.COLLECT.play(player);
|
||||
if (!player.hasPermission("UltraDepository.silent")) {
|
||||
PluginMessages.COLLECTED.send(player, new Object[]{
|
||||
depository.getItems().get(typeID).getName(),
|
||||
finalAmount, depository.getName()
|
||||
});
|
||||
PluginConfig.Sounds.COLLECT.play(player);
|
||||
}
|
||||
UltraDepository.getInstance().debug("Item collected successfully.");
|
||||
return true;
|
||||
}
|
||||
|
@ -30,6 +30,9 @@ permissions:
|
||||
description: "超级仓库的基本使用权限"
|
||||
default: true
|
||||
|
||||
"UltraDepository.silent":
|
||||
description: "超级仓库的安静模式权限,拥有该权限将不再接收到放入背包的提示。"
|
||||
|
||||
"UltraDepository.auto":
|
||||
description: "超级仓库的自动收集权限"
|
||||
default: op
|
||||
|
Loading…
Reference in New Issue
Block a user