RegionFix #240
@ -10,8 +10,15 @@ import org.bukkit.entity.Player;
|
|||||||
|
|
||||||
public class CommandColor extends SWCommand {
|
public class CommandColor extends SWCommand {
|
||||||
|
|
||||||
|
private static CommandColor instance = null;
|
||||||
|
|
||||||
public CommandColor() {
|
public CommandColor() {
|
||||||
super("color");
|
super("color");
|
||||||
|
instance = this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static CommandColor getInstance() {
|
||||||
|
return instance;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Register(help = true)
|
@Register(help = true)
|
||||||
@ -44,6 +51,11 @@ public class CommandColor extends SWCommand {
|
|||||||
p.sendMessage(BauSystem.PREFIX + "Regions farben auf §e" + color.name().toLowerCase() + "§7 gesetzt");
|
p.sendMessage(BauSystem.PREFIX + "Regions farben auf §e" + color.name().toLowerCase() + "§7 gesetzt");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Register
|
||||||
|
public void genericColorSet(Player p, ColorizationType colorizationType, Color color) {
|
||||||
|
genericColorSet(p, color, colorizationType);
|
||||||
|
}
|
||||||
|
|
||||||
private boolean permissionCheck(Player p) {
|
private boolean permissionCheck(Player p) {
|
||||||
if (!BauSystem.getOwner().equals(p.getUniqueId())) {
|
if (!BauSystem.getOwner().equals(p.getUniqueId())) {
|
||||||
p.sendMessage(BauSystem.PREFIX + "§cDies ist nicht deine Welt!");
|
p.sendMessage(BauSystem.PREFIX + "§cDies ist nicht deine Welt!");
|
||||||
|
@ -2,6 +2,7 @@ package de.steamwar.bausystem.commands;
|
|||||||
|
|
||||||
import de.steamwar.bausystem.BauSystem;
|
import de.steamwar.bausystem.BauSystem;
|
||||||
import de.steamwar.bausystem.Permission;
|
import de.steamwar.bausystem.Permission;
|
||||||
|
import de.steamwar.bausystem.world.Color;
|
||||||
import de.steamwar.bausystem.world.Welt;
|
import de.steamwar.bausystem.world.Welt;
|
||||||
import de.steamwar.bausystem.world.regions.GlobalRegion;
|
import de.steamwar.bausystem.world.regions.GlobalRegion;
|
||||||
import de.steamwar.bausystem.world.regions.Region;
|
import de.steamwar.bausystem.world.regions.Region;
|
||||||
@ -112,6 +113,11 @@ public class CommandRegion extends SWCommand {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Register("color")
|
||||||
|
public void colorCommand(Player p, Color color) {
|
||||||
|
CommandColor.getInstance().genericColor(p, color);
|
||||||
|
}
|
||||||
|
|
||||||
static boolean checkGlobalRegion(Region region, Player p) {
|
static boolean checkGlobalRegion(Region region, Player p) {
|
||||||
if (GlobalRegion.isGlobalRegion(region)) {
|
if (GlobalRegion.isGlobalRegion(region)) {
|
||||||
p.sendMessage(BauSystem.PREFIX + "§cDu bist in keiner Region");
|
p.sendMessage(BauSystem.PREFIX + "§cDu bist in keiner Region");
|
||||||
|
In neuem Issue referenzieren
Einen Benutzer sperren