bugfixes
Dieser Commit ist enthalten in:
Ursprung
30cdc6ec5a
Commit
939f8c86c5
@ -20,9 +20,9 @@ public class ShieldCommand implements CommandExecutor {
|
||||
UserGroup userGroup = steamwarUser.getUserGroup();
|
||||
|
||||
if(userGroup != UserGroup.Developer &&
|
||||
userGroup != UserGroup.Moderator &&
|
||||
userGroup != UserGroup.Admin &&
|
||||
userGroup != UserGroup.Youtuber) {
|
||||
userGroup != UserGroup.Moderator &&
|
||||
userGroup != UserGroup.Admin &&
|
||||
userGroup != UserGroup.Youtuber) {
|
||||
player.sendMessage("§cDu verfügst nicht über die benötigten Rechte!");
|
||||
return false;
|
||||
}
|
||||
|
@ -2,6 +2,8 @@ package de.steamwar.lobby.inventorys;
|
||||
|
||||
import de.steamwar.lobby.utils.ItemBuilder;
|
||||
import de.steamwar.lobby.utils.LobbyPlayer;
|
||||
import de.steamwar.sql.SteamwarUser;
|
||||
import de.steamwar.sql.UserGroup;
|
||||
import org.bukkit.Material;
|
||||
import org.bukkit.entity.Player;
|
||||
|
||||
@ -35,6 +37,14 @@ public class LobbyInventory {
|
||||
.removeAllAtributs()
|
||||
.build());
|
||||
|
||||
|
||||
UserGroup userGroup = SteamwarUser.get(player.getUniqueId()).getUserGroup();
|
||||
if(userGroup != UserGroup.Developer &&
|
||||
userGroup != UserGroup.Moderator &&
|
||||
userGroup != UserGroup.Admin &&
|
||||
userGroup != UserGroup.Youtuber) {
|
||||
return;
|
||||
}
|
||||
player.getInventory().setItem(8, new ItemBuilder(SCHILD)
|
||||
.setDisplayName("§bSchild §8| " + (lobbyPlayer.isShield() ? "§aan" : "§caus"))
|
||||
.setUnbreakable(true)
|
||||
|
In neuem Issue referenzieren
Einen Benutzer sperren