mirror of
https://github.com/AtlasMediaGroup/TotalFreedomMod.git
synced 2024-11-30 10:05:59 +00:00
based palestine
This commit is contained in:
parent
d21c5f0e9d
commit
bd6c7d55a7
@ -103,6 +103,13 @@ public class BlockBlocker extends FreedomService
|
||||
event.setCancelled(true);
|
||||
break;
|
||||
}
|
||||
case GRINDSTONE:
|
||||
{
|
||||
player.sendMessage(ChatColor.GRAY + "Grindstones are disabled.");
|
||||
player.getInventory().setItem(player.getInventory().getHeldItemSlot(), new ItemStack(Material.COOKIE, 1));
|
||||
event.setCancelled(true);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -128,6 +128,19 @@ public class InteractBlocker extends FreedomService
|
||||
event.setCancelled(true);
|
||||
break;
|
||||
}
|
||||
|
||||
case ARMOR_STAND:
|
||||
{
|
||||
if (ConfigEntry.ALLOW_ARMOR_STANDS.getBoolean())
|
||||
{
|
||||
break;
|
||||
}
|
||||
|
||||
player.getInventory().clear(player.getInventory().getHeldItemSlot());
|
||||
player.sendMessage(ChatColor.GRAY + "Armor stands are currently disabled.");
|
||||
event.setCancelled(true);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -38,6 +38,7 @@ public class Command_toggle extends FreedomCommand
|
||||
msg("- explosives [radius]");
|
||||
msg("- unsafeenchs");
|
||||
msg("- bells");
|
||||
msg("- armorstands");
|
||||
return false;
|
||||
}
|
||||
|
||||
@ -165,6 +166,11 @@ public class Command_toggle extends FreedomCommand
|
||||
toggle("The ringing of bells is", ConfigEntry.ALLOW_BELLS);
|
||||
return true;
|
||||
}
|
||||
else if (args[0].equalsIgnoreCase("armorstands"))
|
||||
{
|
||||
toggle("The placement of armor stands is", ConfigEntry.ALLOW_ARMOR_STANDS);
|
||||
return true;
|
||||
}
|
||||
else
|
||||
{
|
||||
return false;
|
||||
@ -183,7 +189,7 @@ public class Command_toggle extends FreedomCommand
|
||||
{
|
||||
return Arrays.asList(
|
||||
"waterplace", "fireplace", "lavaplace", "fluidspread", "lavadmg", "firespread", "frostwalk",
|
||||
"firework", "prelog", "lockdown", "petprotect", "entitywipe", "nonuke", "explosives", "unsafeenchs", "bells");
|
||||
"firework", "prelog", "lockdown", "petprotect", "entitywipe", "nonuke", "explosives", "unsafeenchs", "bells", "armorstands");
|
||||
}
|
||||
|
||||
return Collections.emptyList();
|
||||
|
@ -7,6 +7,7 @@ import org.bukkit.ChatColor;
|
||||
import org.bukkit.command.Command;
|
||||
import org.bukkit.command.CommandSender;
|
||||
import org.bukkit.entity.Player;
|
||||
import org.bukkit.Server;
|
||||
|
||||
@CommandPermissions(level = Rank.SENIOR_ADMIN, source = SourceType.ONLY_CONSOLE, blockHostConsole = true)
|
||||
@CommandParameters(description = "Wipe the flatlands map. Requires manual restart after command is used.", usage = "/<command>")
|
||||
@ -35,6 +36,8 @@ public class Command_wipeflatlands extends FreedomCommand
|
||||
{
|
||||
player.kickPlayer("Server is going offline for flatlands wipe, come back in a few minutes.");
|
||||
}
|
||||
|
||||
server.shutdown();
|
||||
|
||||
if (!plugin.amp.enabled)
|
||||
{
|
||||
|
@ -23,6 +23,7 @@ public enum ConfigEntry
|
||||
ALLOW_FROSTWALKER(Boolean.class, "allow.frostwalker"),
|
||||
ALLOW_UNSAFE_ENCHANTMENTS(Boolean.class, "allow.unsafe_enchantments"),
|
||||
ALLOW_BELLS(Boolean.class, "allow.bells"),
|
||||
ALLOW_ARMOR_STANDS(Boolean.class, "allow.armorstands"),
|
||||
//
|
||||
BLOCKED_CHATCODES(String.class, "blocked_chatcodes"),
|
||||
//
|
||||
|
@ -54,7 +54,7 @@ public class HubWorldRestrictions extends FreedomService
|
||||
|
||||
if (doRestrict(player))
|
||||
{
|
||||
player.sendMessage(ChatColor.RED + "Only Executives can do this!");
|
||||
player.sendMessage(ChatColor.RED + "Only Executives can do this in the Hub World!");
|
||||
event.setCancelled(true);
|
||||
}
|
||||
}
|
||||
@ -66,7 +66,7 @@ public class HubWorldRestrictions extends FreedomService
|
||||
|
||||
if (doRestrict(player))
|
||||
{
|
||||
player.sendMessage(ChatColor.RED + "Only Executives can do this!");
|
||||
player.sendMessage(ChatColor.RED + "Only Executives can do this in the Hub World!");
|
||||
event.setCancelled(true);
|
||||
}
|
||||
}
|
||||
@ -78,7 +78,7 @@ public class HubWorldRestrictions extends FreedomService
|
||||
|
||||
if (doRestrict(player))
|
||||
{
|
||||
player.sendMessage(ChatColor.RED + "Only Executives can do this!");
|
||||
player.sendMessage(ChatColor.RED + "Only Executives can do this in the Hub World!");
|
||||
event.setCancelled(true);
|
||||
}
|
||||
}
|
||||
@ -90,7 +90,7 @@ public class HubWorldRestrictions extends FreedomService
|
||||
|
||||
if (doRestrict(player))
|
||||
{
|
||||
player.sendMessage(ChatColor.RED + "Only Executives can do this!");
|
||||
player.sendMessage(ChatColor.RED + "Only Executives can do this in the Hub World!");
|
||||
event.setCancelled(true);
|
||||
}
|
||||
}
|
||||
@ -104,7 +104,7 @@ public class HubWorldRestrictions extends FreedomService
|
||||
|
||||
if (doRestrict(player))
|
||||
{
|
||||
player.sendMessage(ChatColor.RED + "Only Executives can do this!");
|
||||
player.sendMessage(ChatColor.RED + "Only Executives can do this in the Hub World!");
|
||||
event.setCancelled(true);
|
||||
}
|
||||
}
|
||||
|
@ -84,6 +84,11 @@ public class FUtil
|
||||
{
|
||||
return ConfigEntry.SERVER_OWNERS.getStringList().contains(name) || ConfigEntry.SERVER_EXECUTIVES.getStringList().contains(name);
|
||||
}
|
||||
|
||||
public static boolean isDeveloper(String name)
|
||||
{
|
||||
return FUtil.DEVELOPERS.contains(name);
|
||||
}
|
||||
|
||||
public static boolean canManageMasterBuilders(String name)
|
||||
{
|
||||
|
@ -108,6 +108,7 @@ allow:
|
||||
frostwalker: false
|
||||
unsafe_enchantments: true
|
||||
bells: true
|
||||
armorstands: false
|
||||
|
||||
# Blocked commands:
|
||||
#
|
||||
|
Loading…
Reference in New Issue
Block a user