tak funguj
This commit is contained in:
@@ -21,28 +21,47 @@ public class EventCommand implements CommandExecutor {
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!sender.hasPermission("trixinity.event.*")) {
|
switch (args[0].toLowerCase()) {
|
||||||
|
case "build":
|
||||||
|
if (!sender.hasPermission("trixinity.event.build")) {
|
||||||
sender.sendMessage(ChatColor.RED + "Nemáte oprávnění k použití tohoto příkazu!");
|
sender.sendMessage(ChatColor.RED + "Nemáte oprávnění k použití tohoto příkazu!");
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
switch (args[0].toLowerCase()) {
|
|
||||||
case "build":
|
|
||||||
handleBuild(sender, args);
|
handleBuild(sender, args);
|
||||||
break;
|
break;
|
||||||
case "pvp":
|
case "pvp":
|
||||||
|
if (!sender.hasPermission("trixinity.event.pvp")) {
|
||||||
|
sender.sendMessage(ChatColor.RED + "Nemáte oprávnění k použití tohoto příkazu!");
|
||||||
|
return true;
|
||||||
|
}
|
||||||
handlePvP(sender, args);
|
handlePvP(sender, args);
|
||||||
break;
|
break;
|
||||||
case "spawn":
|
case "spawn":
|
||||||
|
if (!sender.hasPermission("trixinity.event.spawn")) {
|
||||||
|
sender.sendMessage(ChatColor.RED + "Nemáte oprávnění k použití tohoto příkazu!");
|
||||||
|
return true;
|
||||||
|
}
|
||||||
handleSpawn(sender, args);
|
handleSpawn(sender, args);
|
||||||
break;
|
break;
|
||||||
case "gmc":
|
case "gmc":
|
||||||
|
if (!sender.hasPermission("trixinity.event.gamemode")) {
|
||||||
|
sender.sendMessage(ChatColor.RED + "Nemáte oprávnění k použití tohoto příkazu!");
|
||||||
|
return true;
|
||||||
|
}
|
||||||
handleGamemode(sender);
|
handleGamemode(sender);
|
||||||
break;
|
break;
|
||||||
case "heal":
|
case "heal":
|
||||||
|
if (!sender.hasPermission("trixinity.event.heal")) {
|
||||||
|
sender.sendMessage(ChatColor.RED + "Nemáte oprávnění k použití tohoto příkazu!");
|
||||||
|
return true;
|
||||||
|
}
|
||||||
handleHeal(sender, args);
|
handleHeal(sender, args);
|
||||||
break;
|
break;
|
||||||
case "teleport":
|
case "teleport":
|
||||||
|
if (!sender.hasPermission("trixinity.event.teleport")) {
|
||||||
|
sender.sendMessage(ChatColor.RED + "Nemáte oprávnění k použití tohoto příkazu!");
|
||||||
|
return true;
|
||||||
|
}
|
||||||
handleTeleport(sender, args);
|
handleTeleport(sender, args);
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
|
|||||||
@@ -9,6 +9,7 @@ commands:
|
|||||||
trixinity:
|
trixinity:
|
||||||
description: Zobrazí základní informace o pluginu
|
description: Zobrazí základní informace o pluginu
|
||||||
usage: "/trixinity"
|
usage: "/trixinity"
|
||||||
|
permission: trixinity.admin
|
||||||
event:
|
event:
|
||||||
description: Správa event systému
|
description: Správa event systému
|
||||||
usage: |
|
usage: |
|
||||||
@@ -23,11 +24,14 @@ commands:
|
|||||||
§c§l- §cWorldEdit příkazy
|
§c§l- §cWorldEdit příkazy
|
||||||
§c§m---------------------------------
|
§c§m---------------------------------
|
||||||
aliases: [e]
|
aliases: [e]
|
||||||
|
permission: trixinity.event.admin
|
||||||
permissions:
|
permissions:
|
||||||
trixinity.admin:
|
trixinity.admin:
|
||||||
description: Přístup ke všem příkazům pluginu
|
description: Přístup ke všem příkazům pluginu
|
||||||
default: op
|
default: op
|
||||||
trixinity.event.*:
|
children:
|
||||||
|
trixinity.event.admin: true
|
||||||
|
trixinity.event.admin:
|
||||||
description: Přístup ke všem event příkazům
|
description: Přístup ke všem event příkazům
|
||||||
default: op
|
default: op
|
||||||
children:
|
children:
|
||||||
@@ -37,3 +41,21 @@ permissions:
|
|||||||
trixinity.event.gamemode: true
|
trixinity.event.gamemode: true
|
||||||
trixinity.event.heal: true
|
trixinity.event.heal: true
|
||||||
trixinity.event.teleport: true
|
trixinity.event.teleport: true
|
||||||
|
trixinity.event.build:
|
||||||
|
description: Povolení pro build příkazy
|
||||||
|
default: op
|
||||||
|
trixinity.event.pvp:
|
||||||
|
description: Povolení pro pvp příkazy
|
||||||
|
default: op
|
||||||
|
trixinity.event.spawn:
|
||||||
|
description: Povolení pro spawn příkazy
|
||||||
|
default: op
|
||||||
|
trixinity.event.gamemode:
|
||||||
|
description: Povolení pro gamemode příkazy
|
||||||
|
default: op
|
||||||
|
trixinity.event.heal:
|
||||||
|
description: Povolení pro heal příkazy
|
||||||
|
default: op
|
||||||
|
trixinity.event.teleport:
|
||||||
|
description: Povolení pro teleport příkazy
|
||||||
|
default: op
|
||||||
Reference in New Issue
Block a user