mirror of
https://github.com/IntellectualSites/PlotSquared.git
synced 2025-06-28 19:54:43 +02:00
Attempt to do stuff with flags xD
This commit is contained in:
@ -360,10 +360,24 @@ public class Set extends SubCommand {
|
||||
PlotHelper.adjustWallFilling(plr, plot, new PlotBlock((short) material.getId(), data));
|
||||
return true;
|
||||
}
|
||||
StringBuilder builder = new StringBuilder();
|
||||
builder.append(C.SUBCOMMAND_SET_OPTIONS_HEADER.s());
|
||||
builder.append(getArgumentList(values));
|
||||
PlayerFunctions.sendMessage(plr, builder.toString());
|
||||
{
|
||||
AbstractFlag af = new AbstractFlag("");
|
||||
try {
|
||||
af = new AbstractFlag(args[0].toLowerCase());
|
||||
}
|
||||
catch (Exception e) {
|
||||
}
|
||||
if (FlagManager.getFlags().contains(af) || ((PlotMain.worldGuardListener != null) && PlotMain.worldGuardListener.str_flags.contains(args[1].toLowerCase()))) {
|
||||
StringBuilder a = new StringBuilder();
|
||||
if(args.length > 1) {
|
||||
for(int x = 1; x < args.length; x++)
|
||||
a.append(" " + args[x]);
|
||||
}
|
||||
plr.performCommand("plot set flag " + args[0] + args);
|
||||
return true;
|
||||
}
|
||||
}
|
||||
PlayerFunctions.sendMessage(plr, C.SUBCOMMAND_SET_OPTIONS_HEADER.s() + getArgumentList(values));
|
||||
return false;
|
||||
}
|
||||
|
||||
|
@ -157,6 +157,7 @@ public class PlotListener {
|
||||
}
|
||||
|
||||
public static void plotExit(Player player, Plot plot) {
|
||||
player.setAllowFlight(false);
|
||||
{
|
||||
PlayerLeavePlotEvent callEvent = new PlayerLeavePlotEvent(player, plot);
|
||||
Bukkit.getPluginManager().callEvent(callEvent);
|
||||
|
Reference in New Issue
Block a user