*/
@@ -17,8 +16,7 @@ public interface Method
* Encodes the Plugin into an Object disguised as the Plugin. If you want the original Plugin Class you must cast it
* to the correct Plugin, to do so you have to verify the name and or version then cast.
*
- * <
- * pre>
+ *
* if(method.getName().equalsIgnoreCase("iConomy"))
* iConomy plugin = ((iConomy)method.getPlugin());
*
@@ -50,7 +48,8 @@ public interface Method
public String getVersion();
/**
- * Returns the amount of decimal places that get stored NOTE: it will return -1 if there is no rounding
+ * Returns the amount of decimal places that get stored
+ * NOTE: it will return -1 if there is no rounding
*
* @return int
for each decimal place
*/
@@ -89,9 +88,7 @@ public interface Method
public boolean hasAccount(String name);
/**
- * Check to see if an account
- * name
is tied to a
- * bank
.
+ * Check to see if an account name
is tied to a bank
.
*
* @param bank Bank name
* @param name Account name
@@ -110,16 +107,14 @@ public interface Method
/**
* Forces an account creation
*
- * @param name Account name
+ * @param name Account name
* @param balance Initial account balance
* @return boolean
*/
public boolean createAccount(String name, Double balance);
/**
- * Returns a
- * MethodAccount
class for an account
- * name
.
+ * Returns a MethodAccount
class for an account name
.
*
* @param name Account name
* @return MethodAccount
or Null
@@ -127,9 +122,7 @@ public interface Method
public MethodAccount getAccount(String name);
/**
- * Returns a
- * MethodBankAccount
class for an account
- * name
.
+ * Returns a MethodBankAccount
class for an account name
.
*
* @param bank Bank name
* @param name Account name
@@ -138,7 +131,8 @@ public interface Method
public MethodBankAccount getBankAccount(String bank, String name);
/**
- * Checks to verify the compatibility between this Method and a plugin. Internal usage only, for the most part.
+ * Checks to verify the compatibility between this Method and a plugin.
+ * Internal usage only, for the most part.
*
* @param plugin Plugin
* @return boolean
diff --git a/Essentials/src/net/ess3/economy/register/Methods.java b/Essentials/src/net/ess3/economy/register/Methods.java
index 1ac716aa7..3c0772129 100644
--- a/Essentials/src/net/ess3/economy/register/Methods.java
+++ b/Essentials/src/net/ess3/economy/register/Methods.java
@@ -22,10 +22,8 @@ import org.bukkit.plugin.PluginManager;
* preferred: "iConomy"
*
*
- * @author: Nijikokun (
- * @nijikokun)
- * @copyright: Copyright (C) 2011
- * @license: AOL license
+ * @author: Nijikokun (@nijikokun) @copyright: Copyright (C) 2011 @license: AOL license
+ *
*/
public class Methods
{
@@ -257,7 +255,8 @@ public class Methods
/**
* Grab the existing and initialized (hopefully) Method Class.
*
- * @return Method
or Null
+ * @return Method
or
+ * Null
*/
public static Method getMethod()
{
diff --git a/Essentials/src/net/ess3/economy/register/methods/BOSE7.java b/Essentials/src/net/ess3/economy/register/methods/BOSE7.java
index f186dfadd..cbb9b9314 100644
--- a/Essentials/src/net/ess3/economy/register/methods/BOSE7.java
+++ b/Essentials/src/net/ess3/economy/register/methods/BOSE7.java
@@ -9,10 +9,8 @@ import org.bukkit.plugin.Plugin;
* BOSEconomy 7 Implementation of Method
*
* @author Acrobot
- * @author Nijikokun (
- * @nijikokun)
- * @copyright (c) 2011
- * @license AOL license
+ * @author Nijikokun (@nijikokun) @copyright (c) 2011 @license AOL license
+ *
*/
public class BOSE7 implements Method
{
diff --git a/Essentials/src/net/ess3/economy/register/methods/iCo5.java b/Essentials/src/net/ess3/economy/register/methods/iCo5.java
index 9e4dab821..a615ada5d 100644
--- a/Essentials/src/net/ess3/economy/register/methods/iCo5.java
+++ b/Essentials/src/net/ess3/economy/register/methods/iCo5.java
@@ -12,10 +12,8 @@ import org.bukkit.plugin.Plugin;
/**
* iConomy 5 Implementation of Method
*
- * @author Nijikokun (
- * @nijikokun)
- * @copyright (c) 2011
- * @license AOL license
+ * @author Nijikokun (@nijikokun) @copyright (c) 2011 @license AOL license
+ *
*/
public class iCo5 implements Method
{
diff --git a/Essentials/src/net/ess3/economy/register/methods/iCo6.java b/Essentials/src/net/ess3/economy/register/methods/iCo6.java
index d98819828..9dfdabe2e 100644
--- a/Essentials/src/net/ess3/economy/register/methods/iCo6.java
+++ b/Essentials/src/net/ess3/economy/register/methods/iCo6.java
@@ -11,10 +11,8 @@ import org.bukkit.plugin.Plugin;
/**
* iConomy 6 Implementation of Method
*
- * @author Nijikokun (
- * @nijikokun)
- * @copyright (c) 2011
- * @license AOL license
+ * @author Nijikokun (@nijikokun) @copyright (c) 2011 @license AOL license
+ *
*/
public class iCo6 implements Method
{
diff --git a/Essentials/src/net/ess3/listener/EssentialsBlockListener.java b/Essentials/src/net/ess3/listener/EssentialsBlockListener.java
index f72b95e64..8d3f380a7 100644
--- a/Essentials/src/net/ess3/listener/EssentialsBlockListener.java
+++ b/Essentials/src/net/ess3/listener/EssentialsBlockListener.java
@@ -15,7 +15,7 @@ import org.bukkit.inventory.ItemStack;
public class EssentialsBlockListener implements Listener
{
- private final IEssentials ess;
+ private final transient IEssentials ess;
public EssentialsBlockListener(final IEssentials ess)
{
diff --git a/Essentials/src/net/ess3/listener/EssentialsEntityListener.java b/Essentials/src/net/ess3/listener/EssentialsEntityListener.java
index c0b5a54d0..41ed4503a 100644
--- a/Essentials/src/net/ess3/listener/EssentialsEntityListener.java
+++ b/Essentials/src/net/ess3/listener/EssentialsEntityListener.java
@@ -19,7 +19,7 @@ import org.bukkit.inventory.ItemStack;
public class EssentialsEntityListener implements Listener
{
- private final IEssentials ess;
+ private final transient IEssentials ess;
public EssentialsEntityListener(final IEssentials ess)
{
@@ -41,7 +41,7 @@ public class EssentialsEntityListener implements Listener
attacker.updateActivity(true);
if (settings.getData().getGeneral().getLoginAttackDelay() > 0 && !Permissions.PVPDELAY_EXEMPT.isAuthorized(
attacker) && (System.currentTimeMillis() < (attacker.getTimestamp(
- TimestampType.LOGIN) + settings.getData().getGeneral().getLoginAttackDelay())))
+ TimestampType.LOGIN) + settings.getData().getGeneral().getLoginAttackDelay())))
{
event.setCancelled(true);
}
diff --git a/Essentials/src/net/ess3/listener/EssentialsPlayerListener.java b/Essentials/src/net/ess3/listener/EssentialsPlayerListener.java
index b5de18fd1..81ec8a397 100644
--- a/Essentials/src/net/ess3/listener/EssentialsPlayerListener.java
+++ b/Essentials/src/net/ess3/listener/EssentialsPlayerListener.java
@@ -40,9 +40,9 @@ import org.bukkit.inventory.ItemStack;
public class EssentialsPlayerListener implements Listener
{
private static final Logger LOGGER = Logger.getLogger("Minecraft");
- private final Server server;
- private final IEssentials ess;
- private final IUserMap userMap;
+ private final transient Server server;
+ private final transient IEssentials ess;
+ private final transient IUserMap userMap;
public EssentialsPlayerListener(final IEssentials parent)
{
@@ -56,8 +56,7 @@ public class EssentialsPlayerListener implements Listener
public void onPlayerRespawn(final PlayerRespawnEvent event)
{
final Player player = event.getPlayer();
- if (!player.isOnline())
- {
+ if (!player.isOnline()) {
return;
}
final IUser user = userMap.getUser(player);
@@ -174,83 +173,83 @@ public class EssentialsPlayerListener implements Listener
delayedJoin(event.getPlayer());
}
});
- /* TODO: Make sure my update is good
- if (!event.getPlayer().isOnline())
- {
- return;
- }
+/* TODO: Make sure my update is good
+ if (!event.getPlayer().isOnline())
+ {
+ return;
+ }
- ess.getBackup().startTask();
+ ess.getBackup().startTask();
- final String joinMessage = ess.getSettings().getData().getGeneral().getJoinMessage();
- if (joinMessage != null)
- {
- final IText itOutput = new KeywordReplacer(new SimpleTextInput(joinMessage), ess.getUserMap().getUser(event.getPlayer()), ess);
- final SimpleTextPager stPager = new SimpleTextPager(itOutput);
- event.setJoinMessage(FormatUtil.replaceFormat(stPager.getString(0)));
- }
- else
- {
- event.setJoinMessage(joinMessage);
- }
+ final String joinMessage = ess.getSettings().getData().getGeneral().getJoinMessage();
+ if (joinMessage != null)
+ {
+ final IText itOutput = new KeywordReplacer(new SimpleTextInput(joinMessage), ess.getUserMap().getUser(event.getPlayer()), ess);
+ final SimpleTextPager stPager = new SimpleTextPager(itOutput);
+ event.setJoinMessage(FormatUtil.replaceFormat(stPager.getString(0)));
+ }
+ else
+ {
+ event.setJoinMessage(joinMessage);
+ }
- final IUser user = ess.getUserMap().getUser(event.getPlayer());
+ final IUser user = ess.getUserMap().getUser(event.getPlayer());
- user.updateDisplayName();
- user.getData().setIpAddress(user.getPlayer().getAddress().getAddress().getHostAddress());
- user.updateActivity(false);
+ user.updateDisplayName();
+ user.getData().setIpAddress(user.getPlayer().getAddress().getAddress().getHostAddress());
+ user.updateActivity(false);
- for (String p : ess.getVanishedPlayers())
- {
- if (!Permissions.VANISH_SEE_OTHERS.isAuthorized(user))
- {
- user.getPlayer().hidePlayer(ess.getUserMap().getUser(p).getPlayer());
- }
- }
+ for (String p : ess.getVanishedPlayers())
+ {
+ if (!Permissions.VANISH_SEE_OTHERS.isAuthorized(user))
+ {
+ user.getPlayer().hidePlayer(ess.getUserMap().getUser(p).getPlayer());
+ }
+ }
- if (Permissions.SLEEPINGIGNORED.isAuthorized(user))
- {
- user.getPlayer().setSleepingIgnored(true);
- }
- user.queueSave();
+ if (Permissions.SLEEPINGIGNORED.isAuthorized(user))
+ {
+ user.getPlayer().setSleepingIgnored(true);
+ }
+ user.queueSave();
- final ISettings settings = ess.getSettings();
+ final ISettings settings = ess.getSettings();
- if (!settings.getData().getCommands().isDisabled("motd") && Permissions.MOTD.isAuthorized(user))
- {
- try
- {
- final IText input = new TextInput(user, "motd", true, ess);
- final IText output = new KeywordReplacer(input, user, ess);
- final TextPager pager = new TextPager(output, true);
- pager.showPage("1", null, "motd", user);
- }
- catch (IOException ex)
- {
- if (settings.getData().getGeneral().isDebug())
- {
- LOGGER.log(Level.WARNING, ex.getMessage(), ex);
- }
- else
- {
- LOGGER.log(Level.WARNING, ex.getMessage());
- }
- }
- }
+ if (!settings.getData().getCommands().isDisabled("motd") && Permissions.MOTD.isAuthorized(user))
+ {
+ try
+ {
+ final IText input = new TextInput(user, "motd", true, ess);
+ final IText output = new KeywordReplacer(input, user, ess);
+ final TextPager pager = new TextPager(output, true);
+ pager.showPage("1", null, "motd", user);
+ }
+ catch (IOException ex)
+ {
+ if (settings.getData().getGeneral().isDebug())
+ {
+ LOGGER.log(Level.WARNING, ex.getMessage(), ex);
+ }
+ else
+ {
+ LOGGER.log(Level.WARNING, ex.getMessage());
+ }
+ }
+ }
- if (!settings.getData().getCommands().isDisabled("mail") && Permissions.MAIL.isAuthorized(user))
- {
- final List mail = user.getData().getMails();
- if (mail == null || mail.isEmpty())
- {
- user.sendMessage(_("noNewMail"));
- }
- else
- {
- user.sendMessage(_("youHaveNewMail", mail.size()));
- }
- }*/
+ if (!settings.getData().getCommands().isDisabled("mail") && Permissions.MAIL.isAuthorized(user))
+ {
+ final List mail = user.getData().getMails();
+ if (mail == null || mail.isEmpty())
+ {
+ user.sendMessage(_("noNewMail"));
+ }
+ else
+ {
+ user.sendMessage(_("youHaveNewMail", mail.size()));
+ }
+ }*/
}
public void delayedJoin(final Player player)
@@ -331,19 +330,19 @@ public class EssentialsPlayerListener implements Listener
user.sendMessage(_("youHaveNewMail", mail.size()));
}
}
- if (Permissions.FLY_SAFELOGIN.isAuthorized(user))
+ if(Permissions.FLY_SAFELOGIN.isAuthorized(user))
{
final Location loc = user.getPlayer().getLocation();
final World world = loc.getWorld();
final int x = loc.getBlockX();
int y = loc.getBlockY();
final int z = loc.getBlockZ();
- while (LocationUtil.isBlockUnsafe(world, x, y, z) && y > -1)
+ while(LocationUtil.isBlockUnsafe(world, x, y, z) && y > -1)
{
y--;
}
- if (loc.getBlockY() - y > 1 || y < 0)
+ if(loc.getBlockY() - y > 1 || y < 0)
{
user.getPlayer().setAllowFlight(true);
user.getPlayer().setFlying(true);
@@ -352,6 +351,7 @@ public class EssentialsPlayerListener implements Listener
}
}
+
@EventHandler(priority = EventPriority.HIGH)
public void onPlayerLogin(final PlayerLoginEvent event)
{
@@ -449,6 +449,7 @@ public class EssentialsPlayerListener implements Listener
});
}
}
+
private final Pattern spaceSplit = Pattern.compile(" ");
@EventHandler(priority = EventPriority.MONITOR, ignoreCancelled = true)
@@ -612,7 +613,7 @@ public class EssentialsPlayerListener implements Listener
{
final IUser invOwner = userMap.getUser((Player)invHolder);
if (user.isInvSee() && (!Permissions.INVSEE_MODIFY.isAuthorized(user) || Permissions.INVSEE_PREVENT_MODIFY.isAuthorized(
- invOwner) || !invOwner.isOnline()))
+ invOwner) || !invOwner.isOnline()))
{
event.setCancelled(true);
}
@@ -620,7 +621,7 @@ public class EssentialsPlayerListener implements Listener
}
if (event.getView().getTopInventory().getType() == InventoryType.WORKBENCH)
{
- final IUser user = userMap.getUser((Player)event.getWhoClicked());
+ final IUser user = userMap.getUser((Player) event.getWhoClicked());
if (user.isRecipeSee())
{
event.setCancelled(true);
diff --git a/Essentials/src/net/ess3/listener/EssentialsPluginListener.java b/Essentials/src/net/ess3/listener/EssentialsPluginListener.java
index 8f5de1ec2..56e3add3d 100644
--- a/Essentials/src/net/ess3/listener/EssentialsPluginListener.java
+++ b/Essentials/src/net/ess3/listener/EssentialsPluginListener.java
@@ -19,7 +19,7 @@ import org.bukkit.plugin.Plugin;
public class EssentialsPluginListener implements Listener, IReload
{
- private final IEssentials ess;
+ private final transient IEssentials ess;
public EssentialsPluginListener(final IEssentials ess)
{
@@ -36,10 +36,9 @@ public class EssentialsPluginListener implements Listener, IReload
if (!Methods.hasMethod() && Methods.setMethod(ess.getServer().getPluginManager()))
{
ess.getLogger().log(
- Level.INFO, "Payment method found ({0} version: {1})", new Object[]
- {
- Methods.getMethod().getName(), Methods.getMethod().getVersion()
- });
+ Level.INFO, "Payment method found ({0} version: {1})", new Object[]{
+ Methods.getMethod().getName(), Methods.getMethod().getVersion()
+ });
}
}
diff --git a/Essentials/src/net/ess3/metrics/MetricsListener.java b/Essentials/src/net/ess3/metrics/MetricsListener.java
index b83406e35..17664ab61 100644
--- a/Essentials/src/net/ess3/metrics/MetricsListener.java
+++ b/Essentials/src/net/ess3/metrics/MetricsListener.java
@@ -14,8 +14,8 @@ import org.bukkit.event.player.PlayerJoinEvent;
public class MetricsListener implements Listener
{
- private final IEssentials ess;
- private final MetricsStarter starter;
+ private final transient IEssentials ess;
+ private final transient MetricsStarter starter;
public MetricsListener(final IEssentials parent, final MetricsStarter starter)
{
@@ -30,7 +30,7 @@ public class MetricsListener implements Listener
ISettings settings = ess.getSettings();
if (settings.getData().getGeneral().getMetricsEnabled() == null && (Permissions.ESSENTIALS.isAuthorized(
- event.getPlayer()) || event.getPlayer().hasPermission("bukkit.broadcast.admin")))
+ event.getPlayer()) || event.getPlayer().hasPermission("bukkit.broadcast.admin")))
{
player.sendMessage(_("metrics1"));
player.sendMessage(_("metrics2"));
diff --git a/Essentials/src/net/ess3/metrics/MetricsStarter.java b/Essentials/src/net/ess3/metrics/MetricsStarter.java
index 0c1ac9df9..2c5314142 100644
--- a/Essentials/src/net/ess3/metrics/MetricsStarter.java
+++ b/Essentials/src/net/ess3/metrics/MetricsStarter.java
@@ -14,7 +14,7 @@ import net.ess3.metrics.Metrics.Plotter;
public class MetricsStarter implements Runnable
{
private final IEssentials ess;
- private Boolean start;
+ private transient Boolean start;
private enum Modules
@@ -30,7 +30,10 @@ public class MetricsStarter implements Runnable
EssentialsProtect,
EssentialsGeoIP,
EssentialsXMPP
- };
+ }
+
+
+ ;
public MetricsStarter(final IEssentials plugin)
{
diff --git a/Essentials/src/net/ess3/permissions/BasePermission.java b/Essentials/src/net/ess3/permissions/BasePermission.java
index 5312ebb93..b1cb0be68 100644
--- a/Essentials/src/net/ess3/permissions/BasePermission.java
+++ b/Essentials/src/net/ess3/permissions/BasePermission.java
@@ -1,6 +1,5 @@
package net.ess3.permissions;
-
public class BasePermission extends AbstractSuperpermsPermission
{
protected String permission;
diff --git a/Essentials/src/net/ess3/permissions/Permissions.java b/Essentials/src/net/ess3/permissions/Permissions.java
index 4655ca309..c4c1e19c7 100644
--- a/Essentials/src/net/ess3/permissions/Permissions.java
+++ b/Essentials/src/net/ess3/permissions/Permissions.java
@@ -121,7 +121,7 @@ public enum Permissions implements IPermission
private static final String base = "essentials.";
private final String permission;
private final PermissionDefault defaultPerm;
- private String parent = null;
+ private transient String parent = null;
private Permissions()
{
@@ -164,6 +164,7 @@ public enum Permissions implements IPermission
{
return PermissionFactory.checkPermission(sender, this);
}
+
public static DotStarPermission ENCHANT = new DotStarPermission("essentials.enchant");
public static MaterialDotStarPermission GIVE = new MaterialDotStarPermission("essentials.give", PermissionDefault.TRUE);
public static DotStarPermission RANKS = new DotStarPermission("essentials.ranks");
diff --git a/Essentials/src/net/ess3/ranks/GMGroups.java b/Essentials/src/net/ess3/ranks/GMGroups.java
index 9e2bd745f..55a6295d3 100644
--- a/Essentials/src/net/ess3/ranks/GMGroups.java
+++ b/Essentials/src/net/ess3/ranks/GMGroups.java
@@ -12,8 +12,8 @@ import org.bukkit.plugin.Plugin;
public class GMGroups extends AbstractRanks implements IRanks
{
- private final IEssentials ess;
- private final GroupManager groupManager;
+ private final transient IEssentials ess;
+ private final transient GroupManager groupManager;
public GMGroups(final IEssentials ess, final Plugin groupManager)
{
diff --git a/Essentials/src/net/ess3/ranks/Ranks.java b/Essentials/src/net/ess3/ranks/Ranks.java
index 31a9bc34b..4e876b128 100644
--- a/Essentials/src/net/ess3/ranks/Ranks.java
+++ b/Essentials/src/net/ess3/ranks/Ranks.java
@@ -17,11 +17,12 @@ public class Ranks implements StorageObject
final RankOptions defaultOptions = new RankOptions();
ranks.put("default", defaultOptions);
}
+
@Comment(
- {
- "The order of the ranks matters, the ranks are checked from top to bottom.", "All rank names have to be lower case.",
- "The ranks can be connected to users using the permission essentials.ranks.rankname"
- })
+ {
+ "The order of the ranks matters, the ranks are checked from top to bottom.", "All rank names have to be lower case.",
+ "The ranks can be connected to users using the permission essentials.ranks.rankname"
+ })
@MapValueType(RankOptions.class)
private LinkedHashMap ranks = new LinkedHashMap();
}
diff --git a/Essentials/src/net/ess3/settings/Backup.java b/Essentials/src/net/ess3/settings/Backup.java
index 01ba37322..bbdef7bdf 100644
--- a/Essentials/src/net/ess3/settings/Backup.java
+++ b/Essentials/src/net/ess3/settings/Backup.java
@@ -18,16 +18,17 @@ public class Backup implements StorageObject
@Comment("Add a command that backups your data, e.g. 'rdiff-backup World1 backups/World1'")
private String command;
@Comment(
- {
- "Runs these commands before a backup.", "This will run every time time (in minutes) you specify in the interval setting.",
- "ex: say \"Hello World\" will make the server say Hello World"
- })
+ {
+ "Runs these commands before a backup.", "This will run every time time (in minutes) you specify in the interval setting.",
+ "ex: say \"Hello World\" will make the server say Hello World"
+ })
private List commandsBeforeBackup;
+
@Comment(
- {
- "Runs these commands after a backup.", "This will run every time time (in minutes) you specify in the interval setting.",
- "ex: say \"Hello World\" will make the server say Hello World"
- })
+ {
+ "Runs these commands after a backup.", "This will run every time time (in minutes) you specify in the interval setting.",
+ "ex: say \"Hello World\" will make the server say Hello World"
+ })
private List commandsAfterBackup;
public Backup()
@@ -48,4 +49,5 @@ public class Backup implements StorageObject
{
return commandsAfterBackup == null ? Collections.emptyList() : Collections.unmodifiableList(commandsAfterBackup);
}
+
}
diff --git a/Essentials/src/net/ess3/settings/Chat.java b/Essentials/src/net/ess3/settings/Chat.java
index a7a99fe6e..14c7cc702 100644
--- a/Essentials/src/net/ess3/settings/Chat.java
+++ b/Essentials/src/net/ess3/settings/Chat.java
@@ -13,20 +13,20 @@ public class Chat implements StorageObject
@Comment("The character(s) to prefix all nicknames, so that you know they are not true usernames.")
private String nicknamePrefix = "~";
@Comment(
- {
- "Disable this if you have any other plugin, that modifies the displayname of a user.",
- "If it is not set, it will be enabled if EssentialsChat is installed, otherwise not."
- })
+ {
+ "Disable this if you have any other plugin, that modifies the displayname of a user.",
+ "If it is not set, it will be enabled if EssentialsChat is installed, otherwise not."
+ })
private Boolean changeDisplayname;
private String displaynameFormat = "{PREFIX}{NICKNAMEPREFIX}{NAME}{SUFFIX}";
@Comment(
- {
- "If EssentialsChat is installed, this will define how far a player's voice travels, in blocks. Set to 0 to make all chat global.",
- "Note that users with the \"essentials.chat.spy\" permission will hear everything, regardless of this setting.",
- "Users with essentials.chat.shout can override this by prefixing text with an exclamation mark (!)",
- "Or with essentials.chat.question can override this by prefixing text with a question mark (?)",
- "You can add command costs for shout/question by adding chat-shout and chat-question to the command costs section."
- })
+ {
+ "If EssentialsChat is installed, this will define how far a player's voice travels, in blocks. Set to 0 to make all chat global.",
+ "Note that users with the \"essentials.chat.spy\" permission will hear everything, regardless of this setting.",
+ "Users with essentials.chat.shout can override this by prefixing text with an exclamation mark (!)",
+ "Or with essentials.chat.question can override this by prefixing text with a question mark (?)",
+ "You can add command costs for shout/question by adding chat-shout and chat-question to the command costs section."
+ })
private int localRadius = 0;
@Comment("Set the default chat format here, it will be overwritten by group specific chat formats.")
private String defaultFormat = "&7[{GROUP}]&f {DISPLAYNAME}&7:&f {MESSAGE}";
diff --git a/Essentials/src/net/ess3/settings/Commands.java b/Essentials/src/net/ess3/settings/Commands.java
index 6bd29b4c7..e78e09f34 100644
--- a/Essentials/src/net/ess3/settings/Commands.java
+++ b/Essentials/src/net/ess3/settings/Commands.java
@@ -26,16 +26,16 @@ public class Commands implements StorageObject
private Speed speed = new Speed();
@ListType
@Comment(
- {
- "When a command conflicts with another plugin, by default, Essentials will try to force the OTHER plugin to take",
- "priority. If a command is in this list, Essentials will try to give ITSELF priority. This does not always work:",
- "usually whichever plugin was updated most recently wins out. However, the full name of the command will always work.",
- "For example, if WorldGuard and Essentials are both enabled, and WorldGuard takes control over /god, /essentials:god",
- "will still map to Essentials, whereas it might normally get forced upon WorldGuard. Commands prefixed with an \"e\",",
- "such as /egod, will always grant Essentials priority.",
- "We should try to take priority over /god. If this doesn't work, use /essentials:god or /egod.",
- "If god is set using WorldGuard, use /ungod to remove then use whichever you see fit."
- })
+ {
+ "When a command conflicts with another plugin, by default, Essentials will try to force the OTHER plugin to take",
+ "priority. If a command is in this list, Essentials will try to give ITSELF priority. This does not always work:",
+ "usually whichever plugin was updated most recently wins out. However, the full name of the command will always work.",
+ "For example, if WorldGuard and Essentials are both enabled, and WorldGuard takes control over /god, /essentials:god",
+ "will still map to Essentials, whereas it might normally get forced upon WorldGuard. Commands prefixed with an \"e\",",
+ "such as /egod, will always grant Essentials priority.",
+ "We should try to take priority over /god. If this doesn't work, use /essentials:god or /egod.",
+ "If god is set using WorldGuard, use /ungod to remove then use whichever you see fit."
+ })
@Getter(AccessLevel.NONE)
@Setter(AccessLevel.NONE)
private List overridden = null;
diff --git a/Essentials/src/net/ess3/settings/Economy.java b/Essentials/src/net/ess3/settings/Economy.java
index e43992b61..bd37372bd 100644
--- a/Essentials/src/net/ess3/settings/Economy.java
+++ b/Essentials/src/net/ess3/settings/Economy.java
@@ -26,29 +26,32 @@ public class Economy implements StorageObject
{
return currencySymbol == null || currencySymbol.isEmpty() ? "$" : currencySymbol.substring(0, 1);
}
- private final static double MAXMONEY = 10000000000000.0;
+
+ private final transient static double MAXMONEY = 10000000000000.0;
@Comment(
- {
- "Set the maximum amount of money a player can have",
- "The amount is always limited to 10 trillions because of the limitations of a java double"
- })
+ {
+ "Set the maximum amount of money a player can have",
+ "The amount is always limited to 10 trillions because of the limitations of a java double"
+ })
private double maxMoney = MAXMONEY;
public double getMaxMoney()
{
return Math.abs(maxMoney) > MAXMONEY ? MAXMONEY : Math.abs(maxMoney);
}
+
@Comment(
- {
- "Set the minimum amount of money a player can have (must be above the negative of max-money).",
- "Setting this to 0, will disable overdrafts/loans completely. Users need 'essentials.eco.loan' perm to go below 0."
- })
+ {
+ "Set the minimum amount of money a player can have (must be above the negative of max-money).",
+ "Setting this to 0, will disable overdrafts/loans completely. Users need 'essentials.eco.loan' perm to go below 0."
+ })
private double minMoney = -MAXMONEY;
public double getMinMoney()
{
return Math.abs(minMoney) > MAXMONEY ? -MAXMONEY : minMoney;
}
+
@Comment("Enable this to log all interactions with trade/buy/sell signs and sell command")
private boolean logEnabled = false;
private Worth worth = new Worth();
diff --git a/Essentials/src/net/ess3/settings/General.java b/Essentials/src/net/ess3/settings/General.java
index 01ee58704..6fbdb5b8c 100644
--- a/Essentials/src/net/ess3/settings/General.java
+++ b/Essentials/src/net/ess3/settings/General.java
@@ -17,24 +17,24 @@ public class General implements StorageObject
@Comment("Turn this on, if you want to see more error messages, if something goes wrong.")
private boolean debug = false;
@Comment(
- {
- "Set the locale here, if you want to change the language of Essentials.",
- "If this is not set, Essentials will use the language of your computer.", "Available locales: da, de, en, fr, nl"
- })
+ {
+ "Set the locale here, if you want to change the language of Essentials.",
+ "If this is not set, Essentials will use the language of your computer.", "Available locales: da, de, en, fr, nl"
+ })
private String locale;
@Comment(
- {
- "The number of items given, if the quantity parameter is left out in /item or /give.",
- "If this number is below 1, the maximum stack size size is given. If oversized stacks",
- "is not enabled, any number higher then the maximum stack size results in more than one stack."
- })
+ {
+ "The number of items given, if the quantity parameter is left out in /item or /give.",
+ "If this number is below 1, the maximum stack size size is given. If oversized stacks",
+ "is not enabled, any number higher then the maximum stack size results in more than one stack."
+ })
private int defaultStacksize = -1;
@Comment(
- {
- "Oversized stacks are stacks that ignore the normal max stacksize.",
- "They can be obtained using /give and /item, if the player has essentials.oversizedstacks permission.",
- "How many items should be in a oversized stack?"
- })
+ {
+ "Oversized stacks are stacks that ignore the normal max stacksize.",
+ "They can be obtained using /give and /item, if the player has essentials.oversizedstacks permission.",
+ "How many items should be in a oversized stack?"
+ })
private int oversizedStacksize = 64;
@@ -42,19 +42,21 @@ public class General implements StorageObject
{
FILE, GROUPMANAGER, VAULT
}
+
+
@Comment(
- {
- "Sets the place where group options should be stored:", " FILE: Options are stored inside groups.yml in the Essentials folder",
- " GROUPMANAGER: Options are stored using the GroupManager groups",
- " VAULT: Options are stored using a permissions plugin supported by Vault"
- })
+ {
+ "Sets the place where group options should be stored:", " FILE: Options are stored inside groups.yml in the Essentials folder",
+ " GROUPMANAGER: Options are stored using the GroupManager groups",
+ " VAULT: Options are stored using a permissions plugin supported by Vault"
+ })
private GroupStorage groupStorage = GroupStorage.FILE;
@Comment(
- {
- "Set to true to enable per-world permissions for teleporting between worlds with essentials commands",
- "This applies to /world, /back, /tp[a|o][here|all], but not warps.",
- "Give someone permission to teleport to a world with essentials.world."
- })
+ {
+ "Set to true to enable per-world permissions for teleporting between worlds with essentials commands",
+ "This applies to /world, /back, /tp[a|o][here|all], but not warps.",
+ "Give someone permission to teleport to a world with essentials.world."
+ })
private boolean worldTeleportPermissions = false;
private boolean worldHomePermissions = false;
@Comment("Delay to wait before people can cause attack damage after logging in ")
@@ -69,6 +71,7 @@ public class General implements StorageObject
{
this.loginAttackDelay = loginAttackDelay / 1000;
}
+
private Boolean metricsEnabled = null;
@Comment("The join message when players join the server")
private String joinMessage = "&e{PLAYER} has joined the game";
diff --git a/Essentials/src/net/ess3/settings/Kits.java b/Essentials/src/net/ess3/settings/Kits.java
index 2892729c4..f68ac5d83 100644
--- a/Essentials/src/net/ess3/settings/Kits.java
+++ b/Essentials/src/net/ess3/settings/Kits.java
@@ -21,10 +21,11 @@ public class Kits implements StorageObject
kit.setDelay(10.0);
kit.setItems(
Arrays.asList(
- new ItemStack(Material.DIAMOND_SPADE, 1), new ItemStack(Material.DIAMOND_PICKAXE, 1), new ItemStack(Material.DIAMOND_AXE, 1)));
+ new ItemStack(Material.DIAMOND_SPADE, 1), new ItemStack(Material.DIAMOND_PICKAXE, 1), new ItemStack(Material.DIAMOND_AXE, 1)));
kits = new HashMap();
kits.put("tools", kit);
}
+
@MapValueType(Kit.class)
@Getter(AccessLevel.NONE)
@Setter(AccessLevel.NONE)
diff --git a/Essentials/src/net/ess3/settings/Settings.java b/Essentials/src/net/ess3/settings/Settings.java
index 9552c4cc7..a73e5f42d 100644
--- a/Essentials/src/net/ess3/settings/Settings.java
+++ b/Essentials/src/net/ess3/settings/Settings.java
@@ -12,39 +12,39 @@ import net.ess3.storage.StorageObject;
public class Settings implements StorageObject
{
@Comment(
- {
- "##########################################################", "+------------------------------------------------------+ #",
- "| General Settings | #", "+------------------------------------------------------+ #",
- "##########################################################"
- })
+ {
+ "##########################################################", "+------------------------------------------------------+ #",
+ "| General Settings | #", "+------------------------------------------------------+ #",
+ "##########################################################"
+ })
private General general = new General();
@Comment(
- {
- "##########################################################", "+------------------------------------------------------+ #",
- "| Chat Settings | #", "+------------------------------------------------------+ #",
- "##########################################################"
- })
+ {
+ "##########################################################", "+------------------------------------------------------+ #",
+ "| Chat Settings | #", "+------------------------------------------------------+ #",
+ "##########################################################"
+ })
private Chat chat = new Chat();
@Comment(
- {
- "##########################################################", "+------------------------------------------------------+ #",
- "| Economy Settings | #", "+------------------------------------------------------+ #",
- "##########################################################"
- })
+ {
+ "##########################################################", "+------------------------------------------------------+ #",
+ "| Economy Settings | #", "+------------------------------------------------------+ #",
+ "##########################################################"
+ })
private Economy economy = new Economy();
@Comment(
- {
- "##########################################################", "+------------------------------------------------------+ #",
- "| Commands Settings | #", "+------------------------------------------------------+ #",
- "##########################################################"
- })
+ {
+ "##########################################################", "+------------------------------------------------------+ #",
+ "| Commands Settings | #", "+------------------------------------------------------+ #",
+ "##########################################################"
+ })
private Commands commands = new Commands();
@Comment(
- {
- "##########################################################", "+------------------------------------------------------+ #",
- "| Worlds Settings | #", "+------------------------------------------------------+ #",
- "##########################################################"
- })
+ {
+ "##########################################################", "+------------------------------------------------------+ #",
+ "| Worlds Settings | #", "+------------------------------------------------------+ #",
+ "##########################################################"
+ })
@MapValueType(WorldOptions.class)
@Getter(AccessLevel.NONE)
@Setter(AccessLevel.NONE)
diff --git a/Essentials/src/net/ess3/settings/SettingsHolder.java b/Essentials/src/net/ess3/settings/SettingsHolder.java
index 5d5ab3934..e9b7f8af3 100644
--- a/Essentials/src/net/ess3/settings/SettingsHolder.java
+++ b/Essentials/src/net/ess3/settings/SettingsHolder.java
@@ -8,7 +8,7 @@ import net.ess3.storage.AsyncStorageObjectHolder;
public class SettingsHolder extends AsyncStorageObjectHolder implements ISettings
{
- private volatile boolean debug = false;
+ private transient volatile boolean debug = false;
public SettingsHolder(final IEssentials ess)
{
diff --git a/Essentials/src/net/ess3/settings/Spawns.java b/Essentials/src/net/ess3/settings/Spawns.java
index 57a63409c..7d05d55d2 100644
--- a/Essentials/src/net/ess3/settings/Spawns.java
+++ b/Essentials/src/net/ess3/settings/Spawns.java
@@ -16,22 +16,22 @@ import org.bukkit.Location;
public class Spawns implements StorageObject
{
@Comment(
- {
- "Should we announce to the server when someone logs in for the first time?",
- "If so, use this format, replacing {DISPLAYNAME} with the player name.", "If not, set to ''"
- })
+ {
+ "Should we announce to the server when someone logs in for the first time?",
+ "If so, use this format, replacing {DISPLAYNAME} with the player name.", "If not, set to ''"
+ })
private String newPlayerAnnouncement = "&dWelcome {DISPLAYNAME} to the server!";
@Comment(
- {
- "Priority of the respawn event listener", "Set this to lowest, if you want e.g. Multiverse to handle the respawning",
- "Set this to normal, if you want EssentialsSpawn to handle the respawning",
- "Set this to highest, if you want to force EssentialsSpawn to handle the respawning"
- })
+ {
+ "Priority of the respawn event listener", "Set this to lowest, if you want e.g. Multiverse to handle the respawning",
+ "Set this to normal, if you want EssentialsSpawn to handle the respawning",
+ "Set this to highest, if you want to force EssentialsSpawn to handle the respawning"
+ })
private String respawnPriority = "normal";
@Comment(
- {
- "When we spawn for the first time, which spawnpoint do we use?", "Set to none if you want to use the spawn point of the world."
- })
+ {
+ "When we spawn for the first time, which spawnpoint do we use?", "Set to none if you want to use the spawn point of the world."
+ })
private String newbieSpawn = "none";
@Comment("List of all spawnpoints")
@MapValueType(StoredLocation.class)
diff --git a/Essentials/src/net/ess3/settings/SpawnsHolder.java b/Essentials/src/net/ess3/settings/SpawnsHolder.java
index 9aaaaa350..1c310c7c3 100644
--- a/Essentials/src/net/ess3/settings/SpawnsHolder.java
+++ b/Essentials/src/net/ess3/settings/SpawnsHolder.java
@@ -38,7 +38,7 @@ public class SpawnsHolder extends AsyncStorageObjectHolder implements IE
/**
* Sets a spawn location
*
- * @param loc - Location you want to set as spawn
+ * @param loc - Location you want to set as spawn
* @param group - Group to save it undr in the config
*/
public void setSpawn(final Location loc, final String group)
@@ -174,8 +174,8 @@ public class SpawnsHolder extends AsyncStorageObjectHolder implements IE
private class SpawnPlayerListener implements Listener // TODO: What is this for?
{
- private final IEssentials ess;
- private final SpawnsHolder spawns;
+ private final transient IEssentials ess;
+ private final transient SpawnsHolder spawns;
public SpawnPlayerListener(final IEssentials ess, final SpawnsHolder spawns)
{
@@ -187,6 +187,8 @@ public class SpawnsHolder extends AsyncStorageObjectHolder implements IE
public void onPlayerRespawn(final PlayerRespawnEvent event)
{
final IUser user = ess.getUserMap().getUser(event.getPlayer());
+
+ final ISettings settings = ess.getSettings();
boolean respawnAtHome = ess.getSettings().getData().getCommands().getHome().isRespawnAtHome();
if (respawnAtHome)
{
@@ -238,7 +240,7 @@ public class SpawnsHolder extends AsyncStorageObjectHolder implements IE
private class NewPlayerTeleport implements Runnable
{
- private final IUser user;
+ private final transient IUser user;
public NewPlayerTeleport(final IUser user)
{
diff --git a/Essentials/src/net/ess3/settings/WorldOptions.java b/Essentials/src/net/ess3/settings/WorldOptions.java
index 40e57dee7..e49ebb181 100644
--- a/Essentials/src/net/ess3/settings/WorldOptions.java
+++ b/Essentials/src/net/ess3/settings/WorldOptions.java
@@ -26,6 +26,7 @@ public class WorldOptions implements StorageObject
}
}
}
+
@Comment("Disables godmode for all players if they teleport to this world.")
private boolean godmode = true;
@Comment("Prevent creatures spawning")
diff --git a/Essentials/src/net/ess3/settings/Worlds.java b/Essentials/src/net/ess3/settings/Worlds.java
index 10dc63823..c3f1f09d0 100644
--- a/Essentials/src/net/ess3/settings/Worlds.java
+++ b/Essentials/src/net/ess3/settings/Worlds.java
@@ -9,4 +9,5 @@ import net.ess3.storage.StorageObject;
@EqualsAndHashCode(callSuper = false)
public class Worlds implements StorageObject
{
+
}
\ No newline at end of file
diff --git a/Essentials/src/net/ess3/settings/antibuild/Alert.java b/Essentials/src/net/ess3/settings/antibuild/Alert.java
index dc11841b1..481cc39ec 100644
--- a/Essentials/src/net/ess3/settings/antibuild/Alert.java
+++ b/Essentials/src/net/ess3/settings/antibuild/Alert.java
@@ -32,9 +32,8 @@ public class Alert implements StorageObject
public void setupDefaults()
{
- Material[] mat =
- {
- Material.LAVA, Material.STATIONARY_LAVA, Material.TNT, Material.LAVA_BUCKET
+ Material[] mat = {
+ Material.LAVA, Material.STATIONARY_LAVA, Material.TNT, Material.LAVA_BUCKET
};
alertOnPlacement.addAll(Arrays.asList(mat));
alertOnUse.add(Material.LAVA_BUCKET);
diff --git a/Essentials/src/net/ess3/settings/antibuild/AntiBuild.java b/Essentials/src/net/ess3/settings/antibuild/AntiBuild.java
index b45c65e3e..3bbf32f42 100644
--- a/Essentials/src/net/ess3/settings/antibuild/AntiBuild.java
+++ b/Essentials/src/net/ess3/settings/antibuild/AntiBuild.java
@@ -11,22 +11,24 @@ import net.ess3.storage.StorageObject;
public class AntiBuild implements StorageObject
{
@Comment(
- {
- "Should people with build: false in permissions be allowed to build", "Set true to disable building for those people",
- "Setting to false means EssentialsAntiBuild will never prevent you from building"
- })
+ {
+ "Should people with build: false in permissions be allowed to build", "Set true to disable building for those people",
+ "Setting to false means EssentialsAntiBuild will never prevent you from building"
+ })
private boolean disableBuild = true;
@Comment(
- {
- "Should people with build: false in permissions be allowed to use items", "Set true to disable using for those people",
- "Setting to false means EssentialsAntiBuild will never prevent you from using"
- })
+ {
+ "Should people with build: false in permissions be allowed to use items", "Set true to disable using for those people",
+ "Setting to false means EssentialsAntiBuild will never prevent you from using"
+ })
private boolean disableUse = true;
@Comment(
- {
- "Should we tell people they are not allowed to build"
- })
+ {
+ "Should we tell people they are not allowed to build"
+ })
private boolean warnOnBuildDisallow = true;
+
private Alert alert = new Alert();
private BlackList blacklist = new BlackList();
+
}
diff --git a/Essentials/src/net/ess3/settings/antibuild/BlackList.java b/Essentials/src/net/ess3/settings/antibuild/BlackList.java
index ca67ab479..af9205f7e 100644
--- a/Essentials/src/net/ess3/settings/antibuild/BlackList.java
+++ b/Essentials/src/net/ess3/settings/antibuild/BlackList.java
@@ -15,33 +15,33 @@ import org.bukkit.Material;
public class BlackList implements StorageObject
{
@Comment(
- {
- "Which blocks should people be prevented from placing"
- })
+ {
+ "Which blocks should people be prevented from placing"
+ })
@ListType(Material.class)
@Getter(AccessLevel.NONE)
@Setter(AccessLevel.NONE)
private Set placement = new HashSet();
@Comment(
- {
- "Which items should people be prevented from using"
- })
+ {
+ "Which items should people be prevented from using"
+ })
@ListType(Material.class)
@Getter(AccessLevel.NONE)
@Setter(AccessLevel.NONE)
private Set usage = new HashSet();
@Comment(
- {
- "Which blocks should people be prevented from breaking"
- })
+ {
+ "Which blocks should people be prevented from breaking"
+ })
@ListType(Material.class)
@Getter(AccessLevel.NONE)
@Setter(AccessLevel.NONE)
private Set breaking = new HashSet();
@Comment(
- {
- "Which blocks should not be pushed by pistons"
- })
+ {
+ "Which blocks should not be pushed by pistons"
+ })
@ListType(Material.class)
@Getter(AccessLevel.NONE)
@Setter(AccessLevel.NONE)
@@ -49,9 +49,8 @@ public class BlackList implements StorageObject
public void setupDefaults()
{
- Material[] mat =
- {
- Material.LAVA, Material.STATIONARY_LAVA, Material.TNT, Material.LAVA_BUCKET
+ Material[] mat = {
+ Material.LAVA, Material.STATIONARY_LAVA, Material.TNT, Material.LAVA_BUCKET
};
placement.addAll(Arrays.asList(mat));
}
diff --git a/Essentials/src/net/ess3/settings/commands/Afk.java b/Essentials/src/net/ess3/settings/commands/Afk.java
index 2f3ab65dd..5136dd8d0 100644
--- a/Essentials/src/net/ess3/settings/commands/Afk.java
+++ b/Essentials/src/net/ess3/settings/commands/Afk.java
@@ -11,21 +11,22 @@ import net.ess3.storage.StorageObject;
public class Afk implements StorageObject
{
@Comment(
- {
- "After this timeout in seconds, the user will be set as afk.", "Set to -1 for no timeout."
- })
+ {
+ "After this timeout in seconds, the user will be set as afk.", "Set to -1 for no timeout."
+ })
private long autoAFK = 300;
@Comment(
- {
- "Auto-AFK Kick", "After this timeout in seconds, the user will be kicked from the server.", "Set to -1 for no timeout."
- })
+ {
+ "Auto-AFK Kick", "After this timeout in seconds, the user will be kicked from the server.", "Set to -1 for no timeout."
+ })
private long autoAFKKick = -1;
@Comment(
- {
- "Set this to true, if you want to freeze the player, if he is afk.", "Other players or monsters can't push him out of afk mode then.",
- "This will also enable temporary god mode for the afk player.", "The player has to use the command /afk to leave the afk mode.",
- "You have to add a message to your welcome message or help page,", "since the player will not get a message, if he tries to move."
- })
+ {
+ "Set this to true, if you want to freeze the player, if he is afk.", "Other players or monsters can't push him out of afk mode then.",
+ "This will also enable temporary god mode for the afk player.", "The player has to use the command /afk to leave the afk mode.",
+ "You have to add a message to your welcome message or help page,", "since the player will not get a message, if he tries to move."
+ })
private boolean freezeAFKPlayers = false;
+
private boolean disableItemPickupWhileAfk = true;
}
diff --git a/Essentials/src/net/ess3/settings/commands/Back.java b/Essentials/src/net/ess3/settings/commands/Back.java
index e83c53860..c0e7ed7b6 100644
--- a/Essentials/src/net/ess3/settings/commands/Back.java
+++ b/Essentials/src/net/ess3/settings/commands/Back.java
@@ -11,9 +11,9 @@ import net.ess3.storage.StorageObject;
public class Back implements StorageObject
{
@Comment(
- {
- "Do you want essentials to keep track of previous location for /back in the teleport listener?",
- "If you set this to true any plugin that uses teleport will have the previous location registered."
- })
+ {
+ "Do you want essentials to keep track of previous location for /back in the teleport listener?",
+ "If you set this to true any plugin that uses teleport will have the previous location registered."
+ })
private boolean registerBackInListener = false;
}
diff --git a/Essentials/src/net/ess3/settings/commands/Help.java b/Essentials/src/net/ess3/settings/commands/Help.java
index 585426dce..77eeacb55 100644
--- a/Essentials/src/net/ess3/settings/commands/Help.java
+++ b/Essentials/src/net/ess3/settings/commands/Help.java
@@ -13,11 +13,11 @@ public class Help implements StorageObject
@Comment("Show other plugins commands in help")
private boolean showNonEssCommandsInHelp = true;
@Comment(
- {
- "Hide plugins which don't give a permission in their plugin.yml for each command.",
- "You can override a true value here for a single plugin by adding a permission to a user/group.",
- "The individual permission is: essentials.help., anyone with essentials.* or '*' will see all help this setting reguardless.",
- "You can use negative permissions to remove access to just a single plugins help if the following is enabled."
- })
+ {
+ "Hide plugins which don't give a permission in their plugin.yml for each command.",
+ "You can override a true value here for a single plugin by adding a permission to a user/group.",
+ "The individual permission is: essentials.help., anyone with essentials.* or '*' will see all help this setting reguardless.",
+ "You can use negative permissions to remove access to just a single plugins help if the following is enabled."
+ })
private boolean hidePermissionlessCommands = true;
}
diff --git a/Essentials/src/net/ess3/settings/commands/Home.java b/Essentials/src/net/ess3/settings/commands/Home.java
index 8b4c7356b..2ef08fe1f 100644
--- a/Essentials/src/net/ess3/settings/commands/Home.java
+++ b/Essentials/src/net/ess3/settings/commands/Home.java
@@ -13,11 +13,11 @@ public class Home implements StorageObject
@Comment("When players die, should they respawn at their homes, instead of the spawnpoint?")
private boolean respawnAtHome = false;
@Comment(
- {
- "When a player interacts with a bed, should their home be set to that location?",
- "If you enable this and remove default player access to the /sethome command, ",
- "you can make beds the only way for players to set their home location."
- })
+ {
+ "When a player interacts with a bed, should their home be set to that location?",
+ "If you enable this and remove default player access to the /sethome command, ",
+ "you can make beds the only way for players to set their home location."
+ })
private boolean bedSetsHome = false;
@Comment("If no home is set, should the player be send to spawn, when /home is used.")
private boolean spawnIfNoHome = false;
diff --git a/Essentials/src/net/ess3/settings/commands/List.java b/Essentials/src/net/ess3/settings/commands/List.java
index ea47d9115..e2b869aaf 100644
--- a/Essentials/src/net/ess3/settings/commands/List.java
+++ b/Essentials/src/net/ess3/settings/commands/List.java
@@ -1,5 +1,6 @@
package net.ess3.settings.commands;
+
import lombok.Data;
import lombok.EqualsAndHashCode;
import net.ess3.storage.Comment;
diff --git a/Essentials/src/net/ess3/settings/commands/SocialSpy.java b/Essentials/src/net/ess3/settings/commands/SocialSpy.java
index 9cb572689..4460c0cfd 100644
--- a/Essentials/src/net/ess3/settings/commands/SocialSpy.java
+++ b/Essentials/src/net/ess3/settings/commands/SocialSpy.java
@@ -21,6 +21,7 @@ public class SocialSpy implements StorageObject
socialspyCommands.addAll(Arrays.asList("msg", "r", "mail", "m", "t", "emsg", "tell", "er", "reply", "ereply", "email"));
}
}
+
@ListType
@Comment("Commands to listen for in socialspy")
private List socialspyCommands = new ArrayList();
diff --git a/Essentials/src/net/ess3/settings/commands/Speed.java b/Essentials/src/net/ess3/settings/commands/Speed.java
index b9e7a8988..295a6a1b3 100644
--- a/Essentials/src/net/ess3/settings/commands/Speed.java
+++ b/Essentials/src/net/ess3/settings/commands/Speed.java
@@ -10,14 +10,9 @@ import net.ess3.storage.StorageObject;
@EqualsAndHashCode(callSuper = false)
public class Speed implements StorageObject
{
- @Comment(
- {
- "Set the max fly speed, values range from 0.2 to 1.0"
- })
+ @Comment({"Set the max fly speed, values range from 0.2 to 1.0"})
private double maxFlySpeed = 1.0f;
- @Comment(
- {
- "Set the max walk speed, values range from 0.1 to 1.0"
- })
+
+ @Comment({"Set the max walk speed, values range from 0.1 to 1.0"})
private double maxWalkSpeed = 0.8f;
}
diff --git a/Essentials/src/net/ess3/settings/commands/Teleport.java b/Essentials/src/net/ess3/settings/commands/Teleport.java
index 71b41028d..ffa576410 100644
--- a/Essentials/src/net/ess3/settings/commands/Teleport.java
+++ b/Essentials/src/net/ess3/settings/commands/Teleport.java
@@ -11,20 +11,17 @@ import net.ess3.storage.StorageObject;
public class Teleport implements StorageObject
{
@Comment(
- {
- "Set timeout in seconds for players to accept tpa before request is cancelled.", "Set to 0 for no timeout."
- })
+ {
+ "Set timeout in seconds for players to accept tpa before request is cancelled.", "Set to 0 for no timeout."
+ })
private int requestTimeout = 120;
- @Comment(
- {
- "Cancels a request made by tpa / tphere on world change to prevent cross world tp"
- })
+ @Comment({"Cancels a request made by tpa / tphere on world change to prevent cross world tp"})
private boolean cancelRequestsOnWorldChange = false;
@Comment(
- {
- "The delay, in seconds, a player can't be attacked by other players after he has been teleported by a command",
- "This will also prevent that the player can attack other players"
- })
+ {
+ "The delay, in seconds, a player can't be attacked by other players after he has been teleported by a command",
+ "This will also prevent that the player can attack other players"
+ })
private long invulnerability = 0;
public long getInvulnerability()
diff --git a/Essentials/src/net/ess3/settings/protect/Prevent.java b/Essentials/src/net/ess3/settings/protect/Prevent.java
index 524afe6f2..553776c9d 100644
--- a/Essentials/src/net/ess3/settings/protect/Prevent.java
+++ b/Essentials/src/net/ess3/settings/protect/Prevent.java
@@ -10,6 +10,7 @@ import net.ess3.storage.StorageObject;
@EqualsAndHashCode(callSuper = false)
public class Prevent implements StorageObject
{
+
private boolean lavaFlow = false;
private boolean waterFlow = false;
// private boolean waterbucketFlow = false; TODO: Test if this still works
@@ -29,8 +30,8 @@ public class Prevent implements StorageObject
private boolean endermanPickup = false;
private boolean villagerDeath = false;
@Comment(
- {
- "Monsters won't follow players", "permission essentials.protect.entitytarget.bypass disables this"
- })
+ {
+ "Monsters won't follow players", "permission essentials.protect.entitytarget.bypass disables this"
+ })
private boolean entitytarget = false;
}
\ No newline at end of file
diff --git a/Essentials/src/net/ess3/settings/protect/Protect.java b/Essentials/src/net/ess3/settings/protect/Protect.java
index 420c5028e..ff4af10ff 100644
--- a/Essentials/src/net/ess3/settings/protect/Protect.java
+++ b/Essentials/src/net/ess3/settings/protect/Protect.java
@@ -13,13 +13,15 @@ public class Protect implements StorageObject
@Comment("General physics/behavior modifications")
private Prevent prevent = new Prevent();
@Comment(
- {
- "Maximum height the creeper should explode. -1 allows them to explode everywhere.",
- "Set prevent.creeper-explosion to true, if you want to disable creeper explosions."
- })
+ {
+ "Maximum height the creeper should explode. -1 allows them to explode everywhere.",
+ "Set prevent.creeper-explosion to true, if you want to disable creeper explosions."
+ })
private int creeperMaxHeight = -1;
+
@Comment("Disable weather options")
private boolean disableStorm = false;
private boolean disableThunder = false;
private boolean disableLighting = false;
+
}
diff --git a/Essentials/src/net/ess3/storage/AbstractDelayedYamlFileReader.java b/Essentials/src/net/ess3/storage/AbstractDelayedYamlFileReader.java
index 714138349..b38f5750b 100644
--- a/Essentials/src/net/ess3/storage/AbstractDelayedYamlFileReader.java
+++ b/Essentials/src/net/ess3/storage/AbstractDelayedYamlFileReader.java
@@ -11,8 +11,8 @@ import org.bukkit.Bukkit;
public abstract class AbstractDelayedYamlFileReader implements Runnable
{
- private final Class clazz;
- private final IEssentials ess;
+ private final transient Class clazz;
+ private final transient IEssentials ess;
public AbstractDelayedYamlFileReader(final IEssentials ess, final Class clazz)
{
diff --git a/Essentials/src/net/ess3/storage/AbstractDelayedYamlFileWriter.java b/Essentials/src/net/ess3/storage/AbstractDelayedYamlFileWriter.java
index ade8eeb93..2a74c4cd5 100644
--- a/Essentials/src/net/ess3/storage/AbstractDelayedYamlFileWriter.java
+++ b/Essentials/src/net/ess3/storage/AbstractDelayedYamlFileWriter.java
@@ -11,8 +11,8 @@ import org.bukkit.Bukkit;
public abstract class AbstractDelayedYamlFileWriter implements Runnable
{
- private final IEssentials ess;
- private final ReentrantLock lock = new ReentrantLock(); // TODO: Needed?
+ private final transient IEssentials ess;
+ private final transient ReentrantLock lock = new ReentrantLock(); // TODO: Needed?
public AbstractDelayedYamlFileWriter(final IEssentials ess)
{
diff --git a/Essentials/src/net/ess3/storage/AsyncStorageObjectHolder.java b/Essentials/src/net/ess3/storage/AsyncStorageObjectHolder.java
index b4a82b2bc..d4239db8e 100644
--- a/Essentials/src/net/ess3/storage/AsyncStorageObjectHolder.java
+++ b/Essentials/src/net/ess3/storage/AsyncStorageObjectHolder.java
@@ -10,14 +10,14 @@ import org.bukkit.Bukkit;
public abstract class AsyncStorageObjectHolder implements IStorageObjectHolder
{
- private T data;
- private final Class clazz;
- protected final IEssentials ess;
- private final StorageObjectDataWriter writer;
- private final StorageObjectDataReader reader;
- private final AtomicBoolean loaded = new AtomicBoolean(false);
+ private transient T data;
+ private final transient Class clazz;
+ protected final transient IEssentials ess;
+ private final transient StorageObjectDataWriter writer;
+ private final transient StorageObjectDataReader reader;
+ private final transient AtomicBoolean loaded = new AtomicBoolean(false);
private volatile long savetime = 0;
- private final File file;
+ private final transient File file;
public AsyncStorageObjectHolder(final IEssentials ess, final Class clazz, final File file)
{
diff --git a/Essentials/src/net/ess3/storage/BukkitConstructor.java b/Essentials/src/net/ess3/storage/BukkitConstructor.java
index 666c07931..89f20cdf8 100644
--- a/Essentials/src/net/ess3/storage/BukkitConstructor.java
+++ b/Essentials/src/net/ess3/storage/BukkitConstructor.java
@@ -21,9 +21,9 @@ import org.yaml.snakeyaml.nodes.*;
public class BukkitConstructor extends Constructor
{
- private final Pattern DATAPATTERN = Pattern.compile("[:+',;.]");
- private final Pattern WORD = Pattern.compile("\\W");
- private final IPlugin plugin;
+ private final transient Pattern DATAPATTERN = Pattern.compile("[:+',;.]");
+ private final transient Pattern WORD = Pattern.compile("\\W");
+ private final transient IPlugin plugin;
public BukkitConstructor(final Class> clazz, final IPlugin plugin)
{
diff --git a/Essentials/src/net/ess3/storage/ManagedFile.java b/Essentials/src/net/ess3/storage/ManagedFile.java
index 90429968a..0c3def687 100644
--- a/Essentials/src/net/ess3/storage/ManagedFile.java
+++ b/Essentials/src/net/ess3/storage/ManagedFile.java
@@ -18,7 +18,7 @@ import org.bukkit.Bukkit;
public class ManagedFile
{
private final static int BUFFERSIZE = 1024 * 8;
- private final File file;
+ private final transient File file;
public ManagedFile(final String filename, final IEssentials ess)
{
diff --git a/Essentials/src/net/ess3/storage/StorageObjectMap.java b/Essentials/src/net/ess3/storage/StorageObjectMap.java
index aeaf14892..bb7894b51 100644
--- a/Essentials/src/net/ess3/storage/StorageObjectMap.java
+++ b/Essentials/src/net/ess3/storage/StorageObjectMap.java
@@ -26,11 +26,11 @@ import org.apache.commons.io.IOUtils;
public abstract class StorageObjectMap extends CacheLoader implements IStorageObjectMap
{
- protected final IEssentials ess;
- private final File folder;
- protected final Cache cache = CacheBuilder.newBuilder().softValues().build(this);
- protected final ConcurrentSkipListSet keys = new ConcurrentSkipListSet();
- protected final ConcurrentSkipListMap zippedfiles = new ConcurrentSkipListMap();
+ protected final transient IEssentials ess;
+ private final transient File folder;
+ protected final transient Cache cache = CacheBuilder.newBuilder().softValues().build(this);
+ protected final transient ConcurrentSkipListSet keys = new ConcurrentSkipListSet();
+ protected final transient ConcurrentSkipListMap zippedfiles = new ConcurrentSkipListMap();
private final Pattern zipCheck = Pattern.compile("^[a-zA-Z0-9]*-?[a-zA-Z0-9]+\\.yml$");
public StorageObjectMap(final IEssentials ess, final String folderName)
diff --git a/Essentials/src/net/ess3/storage/StorageQueue.java b/Essentials/src/net/ess3/storage/StorageQueue.java
index d602ad84e..5084ba82f 100644
--- a/Essentials/src/net/ess3/storage/StorageQueue.java
+++ b/Essentials/src/net/ess3/storage/StorageQueue.java
@@ -15,7 +15,7 @@ public class StorageQueue implements Runnable
private DelayQueue queue = new DelayQueue();
public final static long DELAY = TimeUnit.NANOSECONDS.convert(1, TimeUnit.SECONDS);
private final AtomicBoolean enabled = new AtomicBoolean(false);
- private final Object lock = new Object();
+ private final transient Object lock = new Object();
private final IPlugin plugin;
public StorageQueue(IPlugin plugin)
diff --git a/Essentials/src/net/ess3/storage/YamlStorageReader.java b/Essentials/src/net/ess3/storage/YamlStorageReader.java
index 0cb0197b0..f49a0b5a2 100644
--- a/Essentials/src/net/ess3/storage/YamlStorageReader.java
+++ b/Essentials/src/net/ess3/storage/YamlStorageReader.java
@@ -13,10 +13,10 @@ import org.yaml.snakeyaml.introspector.BeanAccess;
public class YamlStorageReader implements IStorageReader
{
- private static final Map, Yaml> PREPARED_YAMLS = Collections.synchronizedMap(new HashMap, Yaml>());
- private static final Map, ReentrantLock> LOCKS = new HashMap, ReentrantLock>();
- private final Reader reader;
- private final IPlugin plugin;
+ private transient static final Map, Yaml> PREPARED_YAMLS = Collections.synchronizedMap(new HashMap, Yaml>());
+ private transient static final Map, ReentrantLock> LOCKS = new HashMap, ReentrantLock>();
+ private transient final Reader reader;
+ private transient final IPlugin plugin;
public YamlStorageReader(final Reader reader, final IPlugin plugin)
{
diff --git a/Essentials/src/net/ess3/storage/YamlStorageWriter.java b/Essentials/src/net/ess3/storage/YamlStorageWriter.java
index 2591af79c..e5de1460b 100644
--- a/Essentials/src/net/ess3/storage/YamlStorageWriter.java
+++ b/Essentials/src/net/ess3/storage/YamlStorageWriter.java
@@ -20,9 +20,9 @@ import org.yaml.snakeyaml.Yaml;
public class YamlStorageWriter implements IStorageWriter
{
- private static final Pattern NON_WORD_PATTERN = Pattern.compile("\\W");
- private final PrintWriter writer;
- private static final Yaml YAML = new Yaml();
+ private transient static final Pattern NON_WORD_PATTERN = Pattern.compile("\\W");
+ private transient final PrintWriter writer;
+ private transient static final Yaml YAML = new Yaml();
public YamlStorageWriter(final PrintWriter writer)
{
@@ -51,7 +51,7 @@ public class YamlStorageWriter implements IStorageWriter
for (Field field : clazz.getDeclaredFields())
{
final int modifier = field.getModifiers();
- if (Modifier.isPrivate(modifier) && !Modifier.isStatic(modifier))
+ if (Modifier.isPrivate(modifier) && !Modifier.isTransient(modifier) && !Modifier.isStatic(modifier))
{
field.setAccessible(true);
diff --git a/Essentials/src/net/ess3/user/CooldownException.java b/Essentials/src/net/ess3/user/CooldownException.java
index 2cd9ac543..08e163522 100644
--- a/Essentials/src/net/ess3/user/CooldownException.java
+++ b/Essentials/src/net/ess3/user/CooldownException.java
@@ -3,10 +3,12 @@ package net.ess3.user;
public class CooldownException extends Exception
{
+
private static final long serialVersionUID = 913632836257457319L;
public CooldownException(String timeLeft)
{
super(timeLeft);
}
+
}
diff --git a/Essentials/src/net/ess3/user/IOfflinePlayer.java b/Essentials/src/net/ess3/user/IOfflinePlayer.java
index 97a9ade5a..d520ce833 100644
--- a/Essentials/src/net/ess3/user/IOfflinePlayer.java
+++ b/Essentials/src/net/ess3/user/IOfflinePlayer.java
@@ -10,6 +10,7 @@ public interface IOfflinePlayer
String getDisplayName();
//Location getBedSpawnLocation();
+
void setBanned(boolean bln);
boolean hasPermission(Permission perm);
diff --git a/Essentials/src/net/ess3/user/IOfflineUser.java b/Essentials/src/net/ess3/user/IOfflineUser.java
index 237569825..b5361da4f 100644
--- a/Essentials/src/net/ess3/user/IOfflineUser.java
+++ b/Essentials/src/net/ess3/user/IOfflineUser.java
@@ -5,4 +5,5 @@ import net.ess3.storage.IStorageObjectHolder;
public interface IOfflineUser extends IStorageObjectHolder//, IOfflinePlayer
{
+
}
diff --git a/Essentials/src/net/ess3/user/PlayerNotFoundException.java b/Essentials/src/net/ess3/user/PlayerNotFoundException.java
index 6817a7847..2c3c741c1 100644
--- a/Essentials/src/net/ess3/user/PlayerNotFoundException.java
+++ b/Essentials/src/net/ess3/user/PlayerNotFoundException.java
@@ -5,6 +5,7 @@ import static net.ess3.I18n._;
public class PlayerNotFoundException extends Exception
{
+
private static final long serialVersionUID = -510752839980332640L;
public PlayerNotFoundException()
diff --git a/Essentials/src/net/ess3/user/User.java b/Essentials/src/net/ess3/user/User.java
index 7a3aba0af..4fce959bf 100644
--- a/Essentials/src/net/ess3/user/User.java
+++ b/Essentials/src/net/ess3/user/User.java
@@ -31,22 +31,22 @@ public class User extends UserBase implements IUser
{
private CommandSender replyTo = null;
@Getter
- private IUser teleportRequester;
+ private transient IUser teleportRequester;
@Getter
- private boolean tpRequestHere;
+ private transient boolean tpRequestHere;
@Getter
- private final ITeleport teleport;
+ private transient final ITeleport teleport;
@Getter
- private long teleportRequestTime;
+ private transient long teleportRequestTime;
@Getter
@Setter
- private long lastOnlineActivity;
- private long lastActivity = System.currentTimeMillis();
+ private transient long lastOnlineActivity;
+ private transient long lastActivity = System.currentTimeMillis();
/*@Getter
@Setter
private boolean hidden = false;*/
@Getter
- private boolean vanished;
+ private transient boolean vanished;
@Getter
@Setter
private boolean invSee = false;
@@ -54,7 +54,7 @@ public class User extends UserBase implements IUser
@Setter
private boolean enderSee = false;
private long lastThrottledAction;
- private Location afkPosition;
+ private transient Location afkPosition;
private AtomicBoolean gotMailInfo = new AtomicBoolean(false);
private WeakReference playerCache;
@Getter
@@ -592,7 +592,8 @@ public class User extends UserBase implements IUser
{
return true;
}
- private long teleportInvulnerabilityTimestamp = 0;
+
+ private transient long teleportInvulnerabilityTimestamp = 0;
public void enableInvulnerabilityAfterTeleport()
{
@@ -634,7 +635,7 @@ public class User extends UserBase implements IUser
}
}
ess.getVanishedPlayers().add(getName());
- if (Permissions.VANISH_EFFECT.isAuthorized(this))
+ if(Permissions.VANISH_EFFECT.isAuthorized(this))
{
getPlayer().addPotionEffect(new PotionEffect(PotionEffectType.INVISIBILITY, Integer.MAX_VALUE, 1, false));
}
@@ -646,7 +647,7 @@ public class User extends UserBase implements IUser
p.showPlayer(getPlayer());
}
ess.getVanishedPlayers().remove(getName());
- if (Permissions.VANISH_EFFECT.isAuthorized(this))
+ if(Permissions.VANISH_EFFECT.isAuthorized(this))
{
getPlayer().removePotionEffect(PotionEffectType.INVISIBILITY);
}
diff --git a/Essentials/src/net/ess3/user/UserData.java b/Essentials/src/net/ess3/user/UserData.java
index 9b63fab2f..b9d684930 100644
--- a/Essentials/src/net/ess3/user/UserData.java
+++ b/Essentials/src/net/ess3/user/UserData.java
@@ -6,7 +6,6 @@ import net.ess3.storage.*;
import org.bukkit.Location;
import org.bukkit.Material;
-
@Data
@EqualsAndHashCode(callSuper = false)
public class UserData implements StorageObject
@@ -15,6 +14,8 @@ public class UserData implements StorageObject
{
JAIL, MUTE, LASTHEAL, LASTTELEPORT, LOGIN, LOGOUT, KIT, COMMAND
}
+
+
private String nickname;
private Double money;
@MapValueType(StoredLocation.class)
@@ -26,6 +27,7 @@ public class UserData implements StorageObject
{
return homes == null ? Collections.emptyMap() : Collections.unmodifiableMap(homes);
}
+
@ListType(Material.class)
@Getter(AccessLevel.NONE)
@Setter(AccessLevel.NONE)
@@ -35,6 +37,7 @@ public class UserData implements StorageObject
{
return unlimited == null ? Collections.emptySet() : Collections.unmodifiableSet(unlimited);
}
+
@MapValueType(List.class)
@MapKeyType(Material.class)
@Getter(AccessLevel.NONE)
@@ -45,6 +48,7 @@ public class UserData implements StorageObject
{
return powerTools == null ? Collections.>emptyMap() : Collections.unmodifiableMap(powerTools);
}
+
private StoredLocation lastLocation;
@MapKeyType(String.class)
@MapValueType(Long.class)
@@ -56,6 +60,7 @@ public class UserData implements StorageObject
{
return timestamps == null ? Collections.emptyMap() : Collections.unmodifiableMap(timestamps);
}
+
private String jail;
@ListType
@Getter(AccessLevel.NONE)
@@ -66,6 +71,7 @@ public class UserData implements StorageObject
{
return mails == null ? Collections.emptyList() : Collections.unmodifiableList(mails);
}
+
private Inventory inventory;
private boolean teleportEnabled;
@ListType
@@ -77,6 +83,7 @@ public class UserData implements StorageObject
{
return ignore == null ? Collections.emptySet() : Collections.unmodifiableSet(ignore);
}
+
private boolean godmode;
private boolean muted;
private boolean jailed;
diff --git a/Essentials/src/net/ess3/user/UserMap.java b/Essentials/src/net/ess3/user/UserMap.java
index 9df31e543..c83047f0c 100644
--- a/Essentials/src/net/ess3/user/UserMap.java
+++ b/Essentials/src/net/ess3/user/UserMap.java
@@ -141,6 +141,7 @@ public class UserMap extends StorageObjectMap implements IUserMap
{
return matchUsers(name, false, false, requester);
}
+
private final Pattern comma = Pattern.compile(",");
public Set matchUsers(final String name, final boolean includeHidden, final boolean includeOffline, final Player requester)
diff --git a/Essentials/src/net/ess3/utils/DateUtil.java b/Essentials/src/net/ess3/utils/DateUtil.java
index baf850034..2a38fd7a4 100644
--- a/Essentials/src/net/ess3/utils/DateUtil.java
+++ b/Essentials/src/net/ess3/utils/DateUtil.java
@@ -30,13 +30,11 @@ public class DateUtil
}
StringBuilder sb = new StringBuilder();
- int[] types = new int[]
- {
- Calendar.YEAR, Calendar.MONTH, Calendar.DAY_OF_MONTH, Calendar.HOUR_OF_DAY, Calendar.MINUTE, Calendar.SECOND
+ int[] types = new int[]{
+ Calendar.YEAR, Calendar.MONTH, Calendar.DAY_OF_MONTH, Calendar.HOUR_OF_DAY, Calendar.MINUTE, Calendar.SECOND
};
- String[] names = new String[]
- {
- _("year"), _("years"), _("month"), _("months"), _("day"), _("days"), _("hour"), _("hours"), _("minute"), _("minutes"), _("second"), _("seconds")
+ String[] names = new String[]{
+ _("year"), _("years"), _("month"), _("months"), _("day"), _("days"), _("hour"), _("hours"), _("minute"), _("minutes"), _("second"), _("seconds")
};
for (int i = 0; i < types.length; i++)
{
diff --git a/Essentials/src/net/ess3/utils/ExecuteTimer.java b/Essentials/src/net/ess3/utils/ExecuteTimer.java
index 97b4174d9..012ab9296 100644
--- a/Essentials/src/net/ess3/utils/ExecuteTimer.java
+++ b/Essentials/src/net/ess3/utils/ExecuteTimer.java
@@ -9,8 +9,9 @@ import java.util.Locale;
public class ExecuteTimer
{
- private final List times;
- private final DecimalFormat decimalFormat = new DecimalFormat("#0.000", DecimalFormatSymbols.getInstance(Locale.US));
+ private final transient List times;
+ private final transient DecimalFormat decimalFormat = new DecimalFormat("#0.000", DecimalFormatSymbols.getInstance(Locale.US));
+
public ExecuteTimer()
{
diff --git a/Essentials/src/net/ess3/utils/FormatUtil.java b/Essentials/src/net/ess3/utils/FormatUtil.java
index bbc690e79..4cba2a71b 100644
--- a/Essentials/src/net/ess3/utils/FormatUtil.java
+++ b/Essentials/src/net/ess3/utils/FormatUtil.java
@@ -13,15 +13,15 @@ import net.ess3.permissions.DotStarPermission;
public class FormatUtil
{
- static final Pattern REPLACE_COLOR_PATTERN = Pattern.compile("&([0-9a-f])");
- static final Pattern REPLACE_MAGIC_PATTERN = Pattern.compile("&(k)");
- static final Pattern REPLACE_PATTERN = Pattern.compile("&([0-9a-fk-or])");
- static final Pattern VANILLA_PATTERN = Pattern.compile("\u00a7+[0-9A-FK-ORa-fk-or]");
- static final Pattern VANILLA_COLOR_PATTERN = Pattern.compile("\u00a7+[0-9A-Fa-f]");
- static final Pattern REPLACE_FORMAT_PATTERN = Pattern.compile("&([l-or])");
- static final Pattern VANILLA_FORMAT_PATTERN = Pattern.compile("\u00a7+[L-ORl-or]");
- static final Pattern VANILLA_MAGIC_PATTERN = Pattern.compile("\u00a7+[Kk]");
- static final Pattern URL_PATTERN = Pattern.compile("((?:(?:https?)://)?[\\w-_\\.]{2,})\\.([a-z]{2,3}(?:/\\S+)?)");
+ static final transient Pattern REPLACE_COLOR_PATTERN = Pattern.compile("&([0-9a-f])");
+ static final transient Pattern REPLACE_MAGIC_PATTERN = Pattern.compile("&(k)");
+ static final transient Pattern REPLACE_PATTERN = Pattern.compile("&([0-9a-fk-or])");
+ static final transient Pattern VANILLA_PATTERN = Pattern.compile("\u00a7+[0-9A-FK-ORa-fk-or]");
+ static final transient Pattern VANILLA_COLOR_PATTERN = Pattern.compile("\u00a7+[0-9A-Fa-f]");
+ static final transient Pattern REPLACE_FORMAT_PATTERN = Pattern.compile("&([l-or])");
+ static final transient Pattern VANILLA_FORMAT_PATTERN = Pattern.compile("\u00a7+[L-ORl-or]");
+ static final transient Pattern VANILLA_MAGIC_PATTERN = Pattern.compile("\u00a7+[Kk]");
+ static final transient Pattern URL_PATTERN = Pattern.compile("((?:(?:https?)://)?[\\w-_\\.]{2,})\\.([a-z]{2,3}(?:/\\S+)?)");
static DecimalFormat dFormat = new DecimalFormat("#0.00", DecimalFormatSymbols.getInstance(Locale.US));
static String stripColor(final String input, final Pattern pattern)
diff --git a/Essentials/src/net/ess3/utils/LocationUtil.java b/Essentials/src/net/ess3/utils/LocationUtil.java
index 64fa71f78..5d2af4000 100644
--- a/Essentials/src/net/ess3/utils/LocationUtil.java
+++ b/Essentials/src/net/ess3/utils/LocationUtil.java
@@ -69,6 +69,7 @@ public class LocationUtil
}
return block.getLocation();
}
+
public final static int RADIUS = 3;
public final static Vector3D[] VOLUME;
@@ -81,11 +82,13 @@ public class LocationUtil
this.y = y;
this.z = z;
}
+
public int x;
public int y;
public int z;
}
+
static
{
List pos = new ArrayList();
@@ -210,7 +213,7 @@ public class LocationUtil
}
if ((!AIR_MATERIALS.contains(world.getBlockAt(x, y, z).getType().getId())) || (!AIR_MATERIALS.contains(
- world.getBlockAt(x, y + 1, z).getType().getId())))
+ world.getBlockAt(x, y + 1, z).getType().getId())))
{
return true;
}
diff --git a/Essentials/src/net/ess3/utils/Target.java b/Essentials/src/net/ess3/utils/Target.java
index 04fa17e1f..6e871a051 100644
--- a/Essentials/src/net/ess3/utils/Target.java
+++ b/Essentials/src/net/ess3/utils/Target.java
@@ -30,3 +30,4 @@ public class Target
return location;
}
}
+
diff --git a/Essentials/src/net/ess3/utils/Util.java b/Essentials/src/net/ess3/utils/Util.java
index 6f93b0909..0817448bd 100644
--- a/Essentials/src/net/ess3/utils/Util.java
+++ b/Essentials/src/net/ess3/utils/Util.java
@@ -16,6 +16,7 @@ public final class Util
private Util()
{
}
+
private final static Pattern INVALIDFILECHARS = Pattern.compile("[^\u0020-\u007E\u0085\u00A0-\uD7FF\uE000-\uFFFC]");
private final static Pattern INVALIDCHARS = Pattern.compile("[^\t\n\r\u0020-\u007E\u0085\u00A0-\uD7FF\uE000-\uFFFC]");
@@ -81,7 +82,7 @@ public final class Util
public static ItemStack convertBlockToItem(final Block block)
{
final ItemStack is = new ItemStack(block.getType(), 1, block.getData());
-
+
final short durability = 0;
switch (is.getType())
@@ -214,4 +215,5 @@ public final class Util
}
return buf.toString();
}
+
}
diff --git a/Essentials/src/net/ess3/utils/gnu/inet/encoding/Punycode.java b/Essentials/src/net/ess3/utils/gnu/inet/encoding/Punycode.java
index c1946c84f..ee72d36df 100644
--- a/Essentials/src/net/ess3/utils/gnu/inet/encoding/Punycode.java
+++ b/Essentials/src/net/ess3/utils/gnu/inet/encoding/Punycode.java
@@ -2,26 +2,38 @@ package net.ess3.utils.gnu.inet.encoding;
/**
- * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free Software Foundation, Inc.
+ * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free Software
+ * Foundation, Inc.
*
* Author: Oliver Hitz
*
* This file is part of GNU Libidn.
*
- * This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General
- * Public License as published by the Free Software Foundation; either version 2.1 of the License, or (at your option)
- * any later version.
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
*
- * This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
- * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
- * details.
+ * This library is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Lesser General Public License along with this library; if not, write to
- * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301
+ * USA
*/
+
+
/**
- * This class offers static methods for encoding/decoding strings using the Punycode algorithm. Note that this implementation only supports 16-bit Unicode code points.
+ * This class offers static methods for encoding/decoding strings
+ * using the Punycode algorithm.
+ *
+ * Note that this implementation only supports 16-bit Unicode code
+ * points.
*/
/*
* Changes by snowleo:
@@ -112,7 +124,7 @@ public class Punycode
{
int q = delta;
- for (int k = BASE;; k += BASE)
+ for (int k = BASE; ; k += BASE)
{
int t;
if (k <= bias)
@@ -191,7 +203,7 @@ public class Punycode
int oldi = i;
int w = 1;
- for (int k = BASE;; k += BASE)
+ for (int k = BASE; ; k += BASE)
{
if (d == input.length())
{
diff --git a/Essentials/src/net/ess3/utils/gnu/inet/encoding/PunycodeException.java b/Essentials/src/net/ess3/utils/gnu/inet/encoding/PunycodeException.java
index fb1f3d0ce..7e4da7d79 100644
--- a/Essentials/src/net/ess3/utils/gnu/inet/encoding/PunycodeException.java
+++ b/Essentials/src/net/ess3/utils/gnu/inet/encoding/PunycodeException.java
@@ -2,23 +2,30 @@ package net.ess3.utils.gnu.inet.encoding;
/**
- * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free Software Foundation, Inc.
+ * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free Software
+ * Foundation, Inc.
*
* Author: Oliver Hitz
*
* This file is part of GNU Libidn.
*
- * This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General
- * Public License as published by the Free Software Foundation; either version 2.1 of the License, or (at your option)
- * any later version.
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public License
+ * as published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
*
- * This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
- * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
- * details.
+ * This library is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
*
- * You should have received a copy of the GNU Lesser General Public License along with this library; if not, write to
- * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301
+ * USA
*/
+
+
/**
* Exception handling for Punycode class.
*/
diff --git a/Essentials/src/net/ess3/utils/textreader/ArrayListInput.java b/Essentials/src/net/ess3/utils/textreader/ArrayListInput.java
index 31b1ac991..9fdc87c9b 100644
--- a/Essentials/src/net/ess3/utils/textreader/ArrayListInput.java
+++ b/Essentials/src/net/ess3/utils/textreader/ArrayListInput.java
@@ -8,7 +8,7 @@ import java.util.Map;
public class ArrayListInput implements IText
{
- private final List lines = new ArrayList();
+ private final transient List lines = new ArrayList();
@Override
public List getLines()
@@ -27,4 +27,5 @@ public class ArrayListInput implements IText
{
return Collections.emptyMap();
}
+
}
diff --git a/Essentials/src/net/ess3/utils/textreader/HelpInput.java b/Essentials/src/net/ess3/utils/textreader/HelpInput.java
index 44215c17f..e6510a2e3 100644
--- a/Essentials/src/net/ess3/utils/textreader/HelpInput.java
+++ b/Essentials/src/net/ess3/utils/textreader/HelpInput.java
@@ -18,9 +18,9 @@ public class HelpInput implements IText
private static final String DESCRIPTION = "description";
private static final String PERMISSION = "permission";
private static final String PERMISSIONS = "permissions";
- private final List lines = new ArrayList();
- private final List chapters = new ArrayList();
- private final Map bookmarks = new HashMap();
+ private final transient List lines = new ArrayList();
+ private final transient List chapters = new ArrayList();
+ private final transient Map bookmarks = new HashMap();
private final static Logger logger = Logger.getLogger("Minecraft");
public HelpInput(final IUser user, final String match, final IEssentials ess) throws IOException
@@ -56,8 +56,8 @@ public class HelpInput implements IText
try
{
if (!match.equalsIgnoreCase("") && (!pluginNameLow.contains(match)) && (!k.getKey().toLowerCase(Locale.ENGLISH).contains(
- match)) && (!(k.getValue().get(DESCRIPTION) instanceof String && ((String)k.getValue().get(DESCRIPTION)).toLowerCase(
- Locale.ENGLISH).contains(match))))
+ match)) && (!(k.getValue().get(DESCRIPTION) instanceof String && ((String)k.getValue().get(DESCRIPTION)).toLowerCase(
+ Locale.ENGLISH).contains(match))))
{
continue;
}
diff --git a/Essentials/src/net/ess3/utils/textreader/KeywordReplacer.java b/Essentials/src/net/ess3/utils/textreader/KeywordReplacer.java
index 1194aa266..22466e0ac 100644
--- a/Essentials/src/net/ess3/utils/textreader/KeywordReplacer.java
+++ b/Essentials/src/net/ess3/utils/textreader/KeywordReplacer.java
@@ -17,9 +17,9 @@ import org.bukkit.plugin.Plugin;
public class KeywordReplacer implements IText
{
- private final IText input;
- private final List replaced;
- private final IEssentials ess;
+ private final transient IText input;
+ private final transient List replaced;
+ private final transient IEssentials ess;
public KeywordReplacer(final IText input, final CommandSender sender, final IEssentials ess)
{
@@ -34,15 +34,15 @@ public class KeywordReplacer implements IText
String displayName, ipAddress, balance, mails, world;
String worlds, online, unique, playerlist, date, time;
String worldTime12, worldTime24, worldDate, plugins;
- String version;
+ String userName, address, version; //TODO: unused?
if (sender instanceof IUser)
{
final IUser user = (IUser)sender;
final Player player = user.getPlayer();
displayName = player.getDisplayName();
- String userName = player.getName(); //TODO: unused
+ userName = player.getName();
ipAddress = player.getAddress() == null || player.getAddress().getAddress() == null ? "" : player.getAddress().getAddress().toString();
- String address = player.getAddress() == null ? "" : player.getAddress().toString(); // TODO: unused
+ address = player.getAddress() == null ? "" : player.getAddress().toString();
balance = FormatUtil.displayCurrency(user.getMoney(), ess);
mails = Integer.toString(user.getData().getMails() == null ? 0 : user.getData().getMails().size());
world = player.getLocation() == null || player.getLocation().getWorld() == null ? "" : player.getLocation().getWorld().getName();
diff --git a/Essentials/src/net/ess3/utils/textreader/SimpleTextInput.java b/Essentials/src/net/ess3/utils/textreader/SimpleTextInput.java
index 6ef3731c1..03405df29 100644
--- a/Essentials/src/net/ess3/utils/textreader/SimpleTextInput.java
+++ b/Essentials/src/net/ess3/utils/textreader/SimpleTextInput.java
@@ -8,7 +8,7 @@ import java.util.Map;
public class SimpleTextInput implements IText
{
- private final List lines = new ArrayList();
+ private final transient List lines = new ArrayList();
public SimpleTextInput(final String input)
{
@@ -32,4 +32,5 @@ public class SimpleTextInput implements IText
{
return Collections.emptyMap();
}
+
}
diff --git a/Essentials/src/net/ess3/utils/textreader/SimpleTextPager.java b/Essentials/src/net/ess3/utils/textreader/SimpleTextPager.java
index 0b850b509..ea70010b6 100644
--- a/Essentials/src/net/ess3/utils/textreader/SimpleTextPager.java
+++ b/Essentials/src/net/ess3/utils/textreader/SimpleTextPager.java
@@ -5,7 +5,7 @@ import org.bukkit.command.CommandSender;
public class SimpleTextPager
{
- private final IText text;
+ private final transient IText text;
public SimpleTextPager(final IText text)
{
diff --git a/Essentials/src/net/ess3/utils/textreader/TextInput.java b/Essentials/src/net/ess3/utils/textreader/TextInput.java
index 090afd948..ca38cd528 100644
--- a/Essentials/src/net/ess3/utils/textreader/TextInput.java
+++ b/Essentials/src/net/ess3/utils/textreader/TextInput.java
@@ -13,10 +13,10 @@ import org.bukkit.command.CommandSender;
public class TextInput implements IText
{
- private final List lines;
- private final List chapters;
- private final Map bookmarks;
- private final long lastChange;
+ private final transient List lines;
+ private final transient List chapters;
+ private final transient Map bookmarks;
+ private final transient long lastChange;
private final static HashMap> cache = new HashMap>();
public TextInput(final CommandSender sender, final String filename, final boolean createFile, final IEssentials ess) throws IOException
diff --git a/Essentials/src/net/ess3/utils/textreader/TextPager.java b/Essentials/src/net/ess3/utils/textreader/TextPager.java
index 965bb0d2f..88f00125c 100644
--- a/Essentials/src/net/ess3/utils/textreader/TextPager.java
+++ b/Essentials/src/net/ess3/utils/textreader/TextPager.java
@@ -10,8 +10,8 @@ import org.bukkit.command.CommandSender;
public class TextPager
{
- private final IText text;
- private final boolean onePage;
+ private final transient IText text;
+ private final transient boolean onePage;
public TextPager(final IText text)
{
diff --git a/Essentials/test/net/ess3/EssentialsTest.java b/Essentials/test/net/ess3/EssentialsTest.java
index cedfa3cb6..0daa06abf 100644
--- a/Essentials/test/net/ess3/EssentialsTest.java
+++ b/Essentials/test/net/ess3/EssentialsTest.java
@@ -23,12 +23,12 @@ import org.mockito.stubbing.Answer;
public abstract class EssentialsTest extends TestCase
{
- protected final Server server;
- protected final IPlugin plugin;
- protected final World world;
- protected final Logger logger;
- protected final Essentials ess;
- protected final List playerList;
+ protected final transient Server server;
+ protected final transient IPlugin plugin;
+ protected final transient World world;
+ protected final transient Logger logger;
+ protected final transient Essentials ess;
+ protected final transient List playerList;
public EssentialsTest(final String testName)
{
diff --git a/Essentials/test/net/ess3/StorageTest.java b/Essentials/test/net/ess3/StorageTest.java
index 4c96a165b..4ca05d9a8 100644
--- a/Essentials/test/net/ess3/StorageTest.java
+++ b/Essentials/test/net/ess3/StorageTest.java
@@ -155,28 +155,28 @@ public class StorageTest extends EssentialsTest
}
/*@Test
- public void testOldUserdata()
- {
- ExecuteTimer ext = new ExecuteTimer();
- ext.start();
- OfflinePlayer base1 = server.createPlayer("testPlayer1", ess);
- server.addPlayer(base1);
- ext.mark("fake user created");
- UserData user = (UserData)ess.getUserMap().getUser(base1);
- ext.mark("load empty user");
- for (int j = 0; j < 1; j++)
- {
- user.setHome("home", new Location(world, j, j, j));
- }
- ext.mark("change home 1 times");
- user.save();
- ext.mark("write user");
- user.save();
- ext.mark("write user (cached)");
- user.reloadConfig();
- ext.mark("reloaded file");
- user.reloadConfig();
- ext.mark("reloaded file (cached)");
- System.out.println(ext.end());
- }*/
+ public void testOldUserdata()
+ {
+ ExecuteTimer ext = new ExecuteTimer();
+ ext.start();
+ OfflinePlayer base1 = server.createPlayer("testPlayer1", ess);
+ server.addPlayer(base1);
+ ext.mark("fake user created");
+ UserData user = (UserData)ess.getUserMap().getUser(base1);
+ ext.mark("load empty user");
+ for (int j = 0; j < 1; j++)
+ {
+ user.setHome("home", new Location(world, j, j, j));
+ }
+ ext.mark("change home 1 times");
+ user.save();
+ ext.mark("write user");
+ user.save();
+ ext.mark("write user (cached)");
+ user.reloadConfig();
+ ext.mark("reloaded file");
+ user.reloadConfig();
+ ext.mark("reloaded file (cached)");
+ System.out.println(ext.end());
+ }*/
}
diff --git a/Essentials/test/net/ess3/UserTest.java b/Essentials/test/net/ess3/UserTest.java
index f4c58ad44..ba26e1c6e 100644
--- a/Essentials/test/net/ess3/UserTest.java
+++ b/Essentials/test/net/ess3/UserTest.java
@@ -21,48 +21,49 @@ public class UserTest extends EssentialsTest
}
/*public void testUpdate()
- {
- OfflinePlayer base1alt = server.createPlayer(base1.getName(), ess);
- assertEquals(base1alt, ess.getUserMap().getUser(base1alt).getBase());
- }
+ {
+ OfflinePlayer base1alt = server.createPlayer(base1.getName(), ess);
+ assertEquals(base1alt, ess.getUserMap().getUser(base1alt).getBase());
+ }
- public void testHome()
- {
- IUser user = ess.getUserMap().getUser(base1);
- Location loc = base1.getLocation();
- user.setHome();
- OfflinePlayer base2 = server.createPlayer(base1.getName(), ess);
- IUser user2 = ess.getUserMap().getUser(base2);
+ public void testHome()
+ {
+ IUser user = ess.getUserMap().getUser(base1);
+ Location loc = base1.getLocation();
+ user.setHome();
+ OfflinePlayer base2 = server.createPlayer(base1.getName(), ess);
+ IUser user2 = ess.getUserMap().getUser(base2);
- Location home = user2.getHome(loc);
- assertNotNull(home);
- assertEquals(loc.getWorld().getName(), home.getWorld().getName());
- assertEquals(loc.getX(), home.getX());
- assertEquals(loc.getY(), home.getY());
- assertEquals(loc.getZ(), home.getZ());
- assertEquals(loc.getYaw(), home.getYaw());
- assertEquals(loc.getPitch(), home.getPitch());
- }*/
+ Location home = user2.getHome(loc);
+ assertNotNull(home);
+ assertEquals(loc.getWorld().getName(), home.getWorld().getName());
+ assertEquals(loc.getX(), home.getX());
+ assertEquals(loc.getY(), home.getY());
+ assertEquals(loc.getZ(), home.getZ());
+ assertEquals(loc.getYaw(), home.getYaw());
+ assertEquals(loc.getPitch(), home.getPitch());
+ }*/
/*public void testMoney()
- {
- should("properly set, take, give, and get money");
- IUser user = ess.getUserMap().getUser(base1);
- double i;
- user.setMoney(i = 100.5);
- user.takeMoney(50);
- i -= 50;
- user.giveMoney(25);
- i += 25;
- assertEquals(user.getMoney(), i);
- }*/
+ {
+ should("properly set, take, give, and get money");
+ IUser user = ess.getUserMap().getUser(base1);
+ double i;
+ user.setMoney(i = 100.5);
+ user.takeMoney(50);
+ i -= 50;
+ user.giveMoney(25);
+ i += 25;
+ assertEquals(user.getMoney(), i);
+ }*/
/*public void testGetGroup()
- {
- should("return the default group");
- IUser user = ess.getUserMap().getUser(base1);
- //assertEquals(user.getGroup(), "default");
- }*/
+ {
+ should("return the default group");
+ IUser user = ess.getUserMap().getUser(base1);
+ //assertEquals(user.getGroup(), "default");
+ }*/
+
public void testNoop()
{
assertTrue(true);
diff --git a/Essentials/test/net/ess3/UtilTest.java b/Essentials/test/net/ess3/UtilTest.java
index bfa3f1e51..0364b68aa 100644
--- a/Essentials/test/net/ess3/UtilTest.java
+++ b/Essentials/test/net/ess3/UtilTest.java
@@ -11,6 +11,7 @@ import net.ess3.utils.Util;
public class UtilTest extends EssentialsTest
{
+
public UtilTest(String name)
{
super(name);
diff --git a/Essentials2Compat/pom.xml b/Essentials2Compat/pom.xml
index 74222b99e..81dc96ac8 100644
--- a/Essentials2Compat/pom.xml
+++ b/Essentials2Compat/pom.xml
@@ -1,20 +1,20 @@
- 4.0.0
+ 4.0.0
-
- net.essentials3
- BuildAll
- 3.0-SNAPSHOT
- ../pom.xml
-
+
+ net.essentials3
+ BuildAll
+ 3.0-SNAPSHOT
+ ../pom.xml
+
- Essentials2Compat
-
-
- ${project.groupId}
- Essentials
- ${project.version}
-
-
+ Essentials2Compat
+
+
+ ${project.groupId}
+ Essentials
+ ${project.version}
+
+
diff --git a/Essentials2Compat/src/com/earth2me/essentials/Economy.java b/Essentials2Compat/src/com/earth2me/essentials/Economy.java
index 2943fcf67..15f0045ac 100644
--- a/Essentials2Compat/src/com/earth2me/essentials/Economy.java
+++ b/Essentials2Compat/src/com/earth2me/essentials/Economy.java
@@ -14,6 +14,7 @@ public final class Economy
private Economy()
{
}
+
private static IEssentials ess;
private static final String noCallBeforeLoad = "Essentials API is called before Essentials is loaded.";
@@ -37,10 +38,11 @@ public final class Economy
/**
* Sets the balance of a user
*
- * @param name Name of the user
+ * @param name Name of the user
* @param balance The balance you want to set
* @throws UserDoesNotExistException If a user by that name does not exists
- * @throws net.ess3.api.NoLoanPermittedException If the user is not allowed to have a negative balance
+ * @throws net.ess3.api.NoLoanPermittedException
+ * If the user is not allowed to have a negative balance
*/
public static void setMoney(String name, double balance) throws UserDoesNotExistException, NoLoanPermittedException
{
@@ -54,10 +56,10 @@ public final class Economy
/**
* Adds money to the balance of a user
*
- * @param name Name of the user
+ * @param name Name of the user
* @param amount The money you want to add
* @throws UserDoesNotExistException If a user by that name does not exists
- * @throws NoLoanPermittedException If the user is not allowed to have a negative balance
+ * @throws NoLoanPermittedException If the user is not allowed to have a negative balance
*/
public static void add(String name, double amount) throws UserDoesNotExistException, NoLoanPermittedException
{
@@ -68,10 +70,10 @@ public final class Economy
/**
* Substracts money from the balance of a user
*
- * @param name Name of the user
+ * @param name Name of the user
* @param amount The money you want to substract
* @throws UserDoesNotExistException If a user by that name does not exists
- * @throws NoLoanPermittedException If the user is not allowed to have a negative balance
+ * @throws NoLoanPermittedException If the user is not allowed to have a negative balance
*/
public static void subtract(String name, double amount) throws UserDoesNotExistException, NoLoanPermittedException
{
@@ -82,10 +84,10 @@ public final class Economy
/**
* Divides the balance of a user by a value
*
- * @param name Name of the user
+ * @param name Name of the user
* @param value The balance is divided by this value
* @throws UserDoesNotExistException If a user by that name does not exists
- * @throws NoLoanPermittedException If the user is not allowed to have a negative balance
+ * @throws NoLoanPermittedException If the user is not allowed to have a negative balance
*/
public static void divide(String name, double value) throws UserDoesNotExistException, NoLoanPermittedException
{
@@ -96,10 +98,10 @@ public final class Economy
/**
* Multiplies the balance of a user by a value
*
- * @param name Name of the user
+ * @param name Name of the user
* @param value The balance is multiplied by this value
* @throws UserDoesNotExistException If a user by that name does not exists
- * @throws NoLoanPermittedException If the user is not allowed to have a negative balance
+ * @throws NoLoanPermittedException If the user is not allowed to have a negative balance
*/
public static void multiply(String name, double value) throws UserDoesNotExistException, NoLoanPermittedException
{
@@ -112,7 +114,7 @@ public final class Economy
*
* @param name Name of the user
* @throws UserDoesNotExistException If a user by that name does not exists
- * @throws NoLoanPermittedException If the user is not allowed to have a negative balance
+ * @throws NoLoanPermittedException If the user is not allowed to have a negative balance
*/
public static void resetBalance(String name) throws UserDoesNotExistException, NoLoanPermittedException
{
@@ -124,7 +126,7 @@ public final class Economy
}
/**
- * @param name Name of the user
+ * @param name Name of the user
* @param amount The amount of money the user should have
* @return true, if the user has more or an equal amount of money
* @throws UserDoesNotExistException If a user by that name does not exists
@@ -135,7 +137,7 @@ public final class Economy
}
/**
- * @param name Name of the user
+ * @param name Name of the user
* @param amount The amount of money the user should have
* @return true, if the user has more money
* @throws UserDoesNotExistException If a user by that name does not exists
@@ -146,7 +148,7 @@ public final class Economy
}
/**
- * @param name Name of the user
+ * @param name Name of the user
* @param amount The amount of money the user should not have
* @return true, if the user has less money
* @throws UserDoesNotExistException If a user by that name does not exists
diff --git a/Essentials2Compat/src/com/earth2me/essentials/EssentialsConf.java b/Essentials2Compat/src/com/earth2me/essentials/EssentialsConf.java
index a76ebbe6c..073f45bf5 100644
--- a/Essentials2Compat/src/com/earth2me/essentials/EssentialsConf.java
+++ b/Essentials2Compat/src/com/earth2me/essentials/EssentialsConf.java
@@ -29,9 +29,9 @@ import net.ess3.storage.StoredLocation;
public class EssentialsConf extends YamlConfiguration
{
private static final Logger LOGGER = Logger.getLogger("Minecraft");
- private File configFile;
- private String templateName = null;
- private Class> resourceClass = EssentialsConf.class;
+ private transient File configFile;
+ private transient String templateName = null;
+ private transient Class> resourceClass = EssentialsConf.class;
private static final Charset UTF8 = Charset.forName("UTF-8");
public EssentialsConf(final File configFile)
diff --git a/Essentials2Compat/src/com/earth2me/essentials/ISettings.java b/Essentials2Compat/src/com/earth2me/essentials/ISettings.java
index dfd68f467..93fbd20b3 100644
--- a/Essentials2Compat/src/com/earth2me/essentials/ISettings.java
+++ b/Essentials2Compat/src/com/earth2me/essentials/ISettings.java
@@ -1,5 +1,6 @@
package com.earth2me.essentials;
+
import java.util.List;
import java.util.Map;
import java.util.Set;
@@ -23,6 +24,7 @@ public interface ISettings
long getBackupInterval();
//MessageFormat getChatFormat(String group);
+
int getChatRadius();
double getCommandCost(String label);
diff --git a/Essentials2Compat/src/com/earth2me/essentials/Settings.java b/Essentials2Compat/src/com/earth2me/essentials/Settings.java
index bd8671c7b..a5f454916 100644
--- a/Essentials2Compat/src/com/earth2me/essentials/Settings.java
+++ b/Essentials2Compat/src/com/earth2me/essentials/Settings.java
@@ -16,9 +16,9 @@ import org.bukkit.inventory.ItemStack;
public final class Settings implements ISettings
{
- private final EssentialsConf config;
+ private final transient EssentialsConf config;
private final static Logger logger = Logger.getLogger("Minecraft");
- private final IEssentials ess;
+ private final transient IEssentials ess;
private boolean metricsEnabled = true;
public Settings(IEssentials ess, File file)
@@ -52,6 +52,7 @@ public final class Settings implements ISettings
{
return config.getInt("sethome-multiple." + set, config.getInt("sethome-multiple.default", 3));
}
+
private int chatRadius = 0;
private int _getChatRadius()
@@ -88,6 +89,7 @@ public final class Settings implements ISettings
{
return config.getInt("starting-balance", 0);
}
+
private Set disabledCommands = new HashSet();
@Override
@@ -140,8 +142,10 @@ public final class Settings implements ISettings
}
return config.getBoolean("override-" + name.toLowerCase(Locale.ENGLISH), false);
}
+
private ConfigurationSection commandCosts;
+
public ConfigurationSection _getCommandCosts()
{
if (config.isConfigurationSection("command-costs"))
@@ -174,6 +178,7 @@ public final class Settings implements ISettings
}
return 0.0;
}
+
private String nicknamePrefix = "~";
private String _getNicknamePrefix()
@@ -198,6 +203,7 @@ public final class Settings implements ISettings
{
return config.getDouble("heal-cooldown", 0);
}
+
private ConfigurationSection kits;
public ConfigurationSection _getKits()
@@ -238,6 +244,7 @@ public final class Settings implements ISettings
}
return null;
}
+
private ChatColor operatorColor = null;
@Override
@@ -311,29 +318,31 @@ public final class Settings implements ISettings
{
return config.getString("backup.command", null);
}
+
private Map chatFormats = Collections.synchronizedMap(new HashMap());
/*@Override //TODO: implement this
- public MessageFormat getChatFormat(String group)
- {
- MessageFormat mFormat = chatFormats.get(group);
- if (mFormat == null)
- {
- String format = config.getString("chat.group-formats." + (group == null ? "Default" : group),
- config.getString("chat.format", "&7[{GROUP}]&f {DISPLAYNAME}&7:&f {MESSAGE}"));
- format = Util.replaceFormat(format);
- format = format.replace("{DISPLAYNAME}", "%1$s");
- format = format.replace("{GROUP}", "{0}");
- format = format.replace("{MESSAGE}", "%2$s");
- format = format.replace("{WORLDNAME}", "{1}");
- format = format.replace("{SHORTWORLDNAME}", "{2}");
- format = format.replaceAll("\\{(\\D*?)\\}", "\\[$1\\]");
- format = "§r".concat(format);
- mFormat = new MessageFormat(format);
- chatFormats.put(group, mFormat);
- }
- return mFormat;
- }*/
+ public MessageFormat getChatFormat(String group)
+ {
+ MessageFormat mFormat = chatFormats.get(group);
+ if (mFormat == null)
+ {
+ String format = config.getString("chat.group-formats." + (group == null ? "Default" : group),
+ config.getString("chat.format", "&7[{GROUP}]&f {DISPLAYNAME}&7:&f {MESSAGE}"));
+ format = Util.replaceFormat(format);
+ format = format.replace("{DISPLAYNAME}", "%1$s");
+ format = format.replace("{GROUP}", "{0}");
+ format = format.replace("{MESSAGE}", "%2$s");
+ format = format.replace("{WORLDNAME}", "{1}");
+ format = format.replace("{SHORTWORLDNAME}", "{2}");
+ format = format.replaceAll("\\{(\\D*?)\\}", "\\[$1\\]");
+ format = "§r".concat(format);
+ mFormat = new MessageFormat(format);
+ chatFormats.put(group, mFormat);
+ }
+ return mFormat;
+ }*/
+
public String getDefaultChatformat()
{
return config.getString("chat.format", "&7[{GROUP}]&f {DISPLAYNAME}&7:&f {MESSAGE}");
@@ -375,6 +384,7 @@ public final class Settings implements ISettings
return config.getBoolean("sort-list-by-groups", true);
}
+
public void reloadConfig()
{
config.load();
@@ -405,6 +415,7 @@ public final class Settings implements ISettings
warnOnBuildDisallow = _warnOnBuildDisallow();
mailsPerMinute = _getMailsPerMinute();
}
+
private List itemSpawnBl = new ArrayList();
@Override
@@ -440,6 +451,7 @@ public final class Settings implements ISettings
}
return epItemSpwn;
}
+
private List enabledSigns = new ArrayList();
private boolean signsEnabled = false;
@@ -478,6 +490,7 @@ public final class Settings implements ISettings
}
return newSigns;
}
+
private boolean warnOnBuildDisallow;
private boolean _warnOnBuildDisallow()
@@ -490,6 +503,7 @@ public final class Settings implements ISettings
{
return warnOnBuildDisallow;
}
+
private boolean debug = false;
private boolean configDebug = false;
@@ -582,6 +596,7 @@ public final class Settings implements ISettings
{
return config.getBoolean(configName, def);
}
+
private final static double MAXMONEY = 10000000000000.0;
@Override
@@ -594,6 +609,7 @@ public final class Settings implements ISettings
}
return max;
}
+
private final static double MINMONEY = -10000000000000.0;
@Override
@@ -628,6 +644,7 @@ public final class Settings implements ISettings
{
return config.getBoolean("remove-god-on-disconnect", false);
}
+
private boolean changeDisplayName = true;
private boolean _changeDisplayName()
@@ -640,6 +657,7 @@ public final class Settings implements ISettings
{
return changeDisplayName;
}
+
private boolean changePlayerListName = false;
private boolean _changePlayerListName()
@@ -658,6 +676,7 @@ public final class Settings implements ISettings
{
return config.getBoolean("use-bukkit-permissions", false);
}
+
private boolean prefixsuffixconfigured = false;
private boolean addprefixsuffix = false;
private boolean essentialsChatActive = false;
@@ -683,6 +702,7 @@ public final class Settings implements ISettings
{
return prefixsuffixconfigured ? addprefixsuffix : essentialsChatActive;
}
+
private boolean disablePrefix = false;
private boolean _disablePrefix()
@@ -695,6 +715,7 @@ public final class Settings implements ISettings
{
return disablePrefix;
}
+
private boolean disableSuffix = false;
private boolean _disableSuffix()
@@ -719,6 +740,7 @@ public final class Settings implements ISettings
{
return config.getLong("auto-afk-kick", -1);
}
+
private boolean getFreezeAfkPlayers;
@Override
@@ -731,6 +753,7 @@ public final class Settings implements ISettings
{
return config.getBoolean("freeze-afk-players", false);
}
+
private boolean cancelAfkOnMove;
@Override
@@ -749,6 +772,7 @@ public final class Settings implements ISettings
{
return config.getBoolean("death-messages", true);
}
+
private Set noGodWorlds = new HashSet();
@Override
@@ -780,6 +804,7 @@ public final class Settings implements ISettings
{
return config.getBoolean("world-home-permissions", false);
}
+
private boolean registerBackInListener;
@Override
@@ -792,6 +817,7 @@ public final class Settings implements ISettings
{
return config.getBoolean("register-back-in-listener", false);
}
+
private boolean disableItemPickupWhileAfk;
@Override
@@ -849,6 +875,7 @@ public final class Settings implements ISettings
{
this.metricsEnabled = metricsEnabled;
}
+
private boolean teleportInvulnerability;
@Override
@@ -867,6 +894,7 @@ public final class Settings implements ISettings
{
return teleportInvulnerability;
}
+
private long loginAttackDelay;
private long _getLoginAttackDelay()
@@ -879,6 +907,7 @@ public final class Settings implements ISettings
{
return loginAttackDelay;
}
+
private int signUsePerSecond;
private int _getSignUsePerSecond()
@@ -908,6 +937,7 @@ public final class Settings implements ISettings
double maxSpeed = config.getDouble("max-walk-speed", 0.8);
return maxSpeed > 1.0 ? 1.0 : Math.abs(maxSpeed);
}
+
private int mailsPerMinute;
private int _getMailsPerMinute()
diff --git a/Essentials2Compat/src/com/earth2me/essentials/UpdateUserFiles.java b/Essentials2Compat/src/com/earth2me/essentials/UpdateUserFiles.java
index a34734cf9..040fdd875 100644
--- a/Essentials2Compat/src/com/earth2me/essentials/UpdateUserFiles.java
+++ b/Essentials2Compat/src/com/earth2me/essentials/UpdateUserFiles.java
@@ -134,6 +134,7 @@ class UpdateUserFiles
String realname = getPlayer(name);
return realname == null ? BROKENNAME : realname;
}
+
private final Map players = new HashMap();
private String getPlayer(String check)
diff --git a/Essentials2Compat/src/com/earth2me/essentials/UserData.java b/Essentials2Compat/src/com/earth2me/essentials/UserData.java
index 2dc8d2cec..fdd16c495 100644
--- a/Essentials2Compat/src/com/earth2me/essentials/UserData.java
+++ b/Essentials2Compat/src/com/earth2me/essentials/UserData.java
@@ -12,10 +12,11 @@ import org.bukkit.inventory.ItemStack;
public class UserData
{
- protected final IEssentials ess;
+ protected final transient IEssentials ess;
private EssentialsConf config;
private final File folder;
+
protected UserData(IEssentials ess, File file)
{
this.ess = ess;
@@ -58,6 +59,7 @@ public class UserData
kitTimestamps = _getKitTimestamps();
nickname = _getNickname();
}
+
private double money;
private double _getMoney()
@@ -89,6 +91,7 @@ public class UserData
config.setProperty("money", value);
config.save();
}
+
private Map homes;
private Map _getHomes()
@@ -121,6 +124,7 @@ public class UserData
return config.getLocation("homes." + search, ess.getServer());
}
+
public List getHomes()
{
return new ArrayList(homes.keySet());
@@ -162,6 +166,7 @@ public class UserData
}
return false;
}
+
private String nickname;
public String _getNickname()
@@ -180,6 +185,7 @@ public class UserData
config.setProperty("nickname", nick);
config.save();
}
+
private List unlimited;
private List _getUnlimited()
@@ -210,6 +216,7 @@ public class UserData
config.setProperty("unlimited", unlimited);
config.save();
}
+
private Map powertools;
private Map _getPowertools()
@@ -263,6 +270,7 @@ public class UserData
{
return !powertools.isEmpty();
}
+
private StoredLocation lastLocation;
private StoredLocation _getLastLocation()
@@ -281,6 +289,8 @@ public class UserData
{
return lastLocation;
}
+
+
private long lastTeleportTimestamp;
private long _getLastTeleportTimestamp()
@@ -299,6 +309,7 @@ public class UserData
config.setProperty("timestamps.lastteleport", time);
config.save();
}
+
private long lastHealTimestamp;
private long _getLastHealTimestamp()
@@ -317,6 +328,7 @@ public class UserData
config.setProperty("timestamps.lastheal", time);
config.save();
}
+
private String jail;
private String _getJail()
@@ -343,6 +355,7 @@ public class UserData
}
config.save();
}
+
private List mails;
private List _getMails()
@@ -375,6 +388,7 @@ public class UserData
mails.add(mail);
setMails(mails);
}
+
private boolean teleportEnabled;
private boolean getTeleportEnabled()
@@ -407,6 +421,7 @@ public class UserData
setSocialSpyEnabled(ret);
return ret;
}
+
private List ignoredPlayers;
public List getIgnoredPlayers()
@@ -428,6 +443,8 @@ public class UserData
}
config.save();
}
+
+
private boolean godmode;
private boolean _getGodModeEnabled()
@@ -446,6 +463,7 @@ public class UserData
config.setProperty("godmode", set);
config.save();
}
+
private boolean muted;
public boolean getMuted()
@@ -464,6 +482,7 @@ public class UserData
config.setProperty("muted", set);
config.save();
}
+
private long muteTimeout;
private long _getMuteTimeout()
@@ -482,6 +501,7 @@ public class UserData
config.setProperty("timestamps.mute", time);
config.save();
}
+
private boolean jailed;
private boolean getJailed()
@@ -507,6 +527,7 @@ public class UserData
setJailed(ret);
return ret;
}
+
private long jailTimeout;
private long _getJailTimeout()
@@ -547,6 +568,7 @@ public class UserData
config.setProperty("ban.timeout", time);
config.save();
}
+
private long lastLogin;
private long _getLastLogin()
@@ -564,6 +586,8 @@ public class UserData
lastLogin = time;
config.setProperty("timestamps.login", time);
}
+
+
private long lastLogout;
private long _getLastLogout()
@@ -582,6 +606,7 @@ public class UserData
config.setProperty("timestamps.logout", time);
config.save();
}
+
private String lastLoginAddress;
private String _getLastLoginAddress()
@@ -599,6 +624,7 @@ public class UserData
lastLoginAddress = address;
config.setProperty("ipAddress", address);
}
+
private boolean afk;
private boolean getAfk()
@@ -624,6 +650,7 @@ public class UserData
setAfk(ret);
return ret;
}
+
private boolean newplayer; //TODO: unused variable?
private String geolocation;
@@ -651,6 +678,7 @@ public class UserData
}
config.save();
}
+
private boolean isSocialSpyEnabled;
private boolean _isSocialSpyEnabled()
@@ -669,6 +697,7 @@ public class UserData
config.setProperty("socialspy", status);
config.save();
}
+
private boolean isNPC;
private boolean _isNPC()
@@ -687,6 +716,7 @@ public class UserData
config.setProperty("npc", set);
config.save();
}
+
private boolean arePowerToolsEnabled;
public boolean arePowerToolsEnabled()
@@ -712,6 +742,7 @@ public class UserData
{
return config.getBoolean("powertoolsenabled", true);
}
+
private ConfigurationSection kitTimestamps;
private ConfigurationSection _getKitTimestamps()
diff --git a/Essentials2Compat/src/com/earth2me/essentials/Util.java b/Essentials2Compat/src/com/earth2me/essentials/Util.java
index b6f051328..0500df536 100644
--- a/Essentials2Compat/src/com/earth2me/essentials/Util.java
+++ b/Essentials2Compat/src/com/earth2me/essentials/Util.java
@@ -12,6 +12,7 @@ public class Util
private Util()
{
}
+
private final static Pattern INVALIDFILECHARS = Pattern.compile("[^a-z0-9]");
private final static Pattern INVALIDCHARS = Pattern.compile("[^\t\n\r\u0020-\u007E\u0085\u00A0-\uD7FF\uE000-\uFFFC]");
@@ -32,6 +33,8 @@ public class Util
{
return INVALIDCHARS.matcher(string).replaceAll("");
}
+
+
private static DecimalFormat dFormat = new DecimalFormat("#0.00", DecimalFormatSymbols.getInstance(Locale.US));
public static String formatAsCurrency(final double value)
diff --git a/EssentialsAntiBuild/pom.xml b/EssentialsAntiBuild/pom.xml
index b99f53c5d..0db30ef3b 100644
--- a/EssentialsAntiBuild/pom.xml
+++ b/EssentialsAntiBuild/pom.xml
@@ -1,20 +1,20 @@
- 4.0.0
+ 4.0.0
-
- net.essentials3
- BuildAll
- 3.0-SNAPSHOT
- ../pom.xml
-
+
+ net.essentials3
+ BuildAll
+ 3.0-SNAPSHOT
+ ../pom.xml
+
- EssentialsAntiBuild
-
-
- ${project.groupId}
- Essentials
- ${project.version}
-
-
+ EssentialsAntiBuild
+
+
+ ${project.groupId}
+ Essentials
+ ${project.version}
+
+
diff --git a/EssentialsAntiBuild/src/net/ess3/antibuild/EssentialsAntiBuild.java b/EssentialsAntiBuild/src/net/ess3/antibuild/EssentialsAntiBuild.java
index 1e54f114a..2edb98da0 100644
--- a/EssentialsAntiBuild/src/net/ess3/antibuild/EssentialsAntiBuild.java
+++ b/EssentialsAntiBuild/src/net/ess3/antibuild/EssentialsAntiBuild.java
@@ -7,8 +7,8 @@ import org.bukkit.plugin.java.JavaPlugin;
public class EssentialsAntiBuild extends JavaPlugin implements IAntiBuild
{
- private EssentialsConnect ess = null;
- private AntiBuildHolder settings = null;
+ private transient EssentialsConnect ess = null;
+ private transient AntiBuildHolder settings = null;
@Override
public void onEnable()
diff --git a/EssentialsAntiBuild/src/net/ess3/antibuild/EssentialsAntiBuildListener.java b/EssentialsAntiBuild/src/net/ess3/antibuild/EssentialsAntiBuildListener.java
index 6c5c30b81..52d34c47a 100644
--- a/EssentialsAntiBuild/src/net/ess3/antibuild/EssentialsAntiBuildListener.java
+++ b/EssentialsAntiBuild/src/net/ess3/antibuild/EssentialsAntiBuildListener.java
@@ -26,8 +26,8 @@ import org.bukkit.inventory.ItemStack;
public class EssentialsAntiBuildListener implements Listener
{
- final private IAntiBuild antib;
- final private IEssentials ess;
+ final private transient IAntiBuild antib;
+ final private transient IEssentials ess;
public EssentialsAntiBuildListener(final IAntiBuild parent)
{
diff --git a/EssentialsAntiBuild/src/net/ess3/antibuild/EssentialsConnect.java b/EssentialsAntiBuild/src/net/ess3/antibuild/EssentialsConnect.java
index a58f18dcc..40d760b66 100644
--- a/EssentialsAntiBuild/src/net/ess3/antibuild/EssentialsConnect.java
+++ b/EssentialsAntiBuild/src/net/ess3/antibuild/EssentialsConnect.java
@@ -13,8 +13,8 @@ import org.bukkit.plugin.Plugin;
public class EssentialsConnect
{
private static final Logger LOGGER = Logger.getLogger("Minecraft");
- private final IEssentials ess;
- private final IAntiBuild antib;
+ private final transient IEssentials ess;
+ private final transient IAntiBuild antib;
public EssentialsConnect(Plugin essPlugin, Plugin essProtect)
{
diff --git a/EssentialsAntiBuild/src/net/ess3/antibuild/IAntiBuild.java b/EssentialsAntiBuild/src/net/ess3/antibuild/IAntiBuild.java
index 1cbd4df6e..51e49c463 100644
--- a/EssentialsAntiBuild/src/net/ess3/antibuild/IAntiBuild.java
+++ b/EssentialsAntiBuild/src/net/ess3/antibuild/IAntiBuild.java
@@ -1,5 +1,6 @@
package net.ess3.antibuild;
+
import org.bukkit.plugin.Plugin;
diff --git a/EssentialsAntiBuild/src/net/ess3/antibuild/Permissions.java b/EssentialsAntiBuild/src/net/ess3/antibuild/Permissions.java
index eb980a2b2..96cdf63ac 100644
--- a/EssentialsAntiBuild/src/net/ess3/antibuild/Permissions.java
+++ b/EssentialsAntiBuild/src/net/ess3/antibuild/Permissions.java
@@ -19,7 +19,7 @@ public enum Permissions implements IPermission
private static final String defaultBase = "essentials.build.";
private final String permission;
private final PermissionDefault defaultPerm;
- private String parent = null;
+ private transient String parent = null;
private Permissions()
{
@@ -67,10 +67,12 @@ public enum Permissions implements IPermission
{
return PermissionFactory.checkPermission(sender, this);
}
+
public static MaterialDotStarPermission PLACEMENT = new MaterialDotStarPermission("essentials.build.place");
public static MaterialDotStarPermission BREAK = new MaterialDotStarPermission("essentials.build.break");
public static MaterialDotStarPermission INTERACT = new MaterialDotStarPermission("essentials.build.interact");
public static MaterialDotStarPermission CRAFT = new MaterialDotStarPermission("essentials.build.craft");
public static MaterialDotStarPermission PICKUP = new MaterialDotStarPermission("essentials.build.pickup");
public static MaterialDotStarPermission DROP = new MaterialDotStarPermission("essentials.build.drop");
+
}
diff --git a/EssentialsChat/pom.xml b/EssentialsChat/pom.xml
index 6be18a14c..e59886710 100644
--- a/EssentialsChat/pom.xml
+++ b/EssentialsChat/pom.xml
@@ -1,20 +1,20 @@
- 4.0.0
+ 4.0.0
-
- net.essentials3
- BuildAll
- 3.0-SNAPSHOT
- ../pom.xml
-
+
+ net.essentials3
+ BuildAll
+ 3.0-SNAPSHOT
+ ../pom.xml
+
- EssentialsChat
-
-
- ${project.groupId}
- Essentials
- ${project.version}
-
-
+ EssentialsChat
+
+
+ ${project.groupId}
+ Essentials
+ ${project.version}
+
+
diff --git a/EssentialsChat/src/net/ess3/chat/ChatStore.java b/EssentialsChat/src/net/ess3/chat/ChatStore.java
index d099a3e04..4d696fb36 100644
--- a/EssentialsChat/src/net/ess3/chat/ChatStore.java
+++ b/EssentialsChat/src/net/ess3/chat/ChatStore.java
@@ -7,9 +7,9 @@ import net.ess3.economy.Trade;
public class ChatStore
{
- private final IUser user;
- private final String type;
- private final Trade charge;
+ private final transient IUser user;
+ private final transient String type;
+ private final transient Trade charge;
public ChatStore(final IEssentials ess, final IUser user, final String type)
{
diff --git a/EssentialsChat/src/net/ess3/chat/EssentialsChatPlayer.java b/EssentialsChat/src/net/ess3/chat/EssentialsChatPlayer.java
index 15e2d3b8b..e358cf9e1 100644
--- a/EssentialsChat/src/net/ess3/chat/EssentialsChatPlayer.java
+++ b/EssentialsChat/src/net/ess3/chat/EssentialsChatPlayer.java
@@ -17,10 +17,10 @@ import org.bukkit.event.player.AsyncPlayerChatEvent;
public abstract class EssentialsChatPlayer implements Listener
{
- protected IEssentials ess;
+ protected transient IEssentials ess;
protected final static Logger LOGGER = Logger.getLogger("Minecraft");
- protected final Server server;
- protected final Map chatStorage;
+ protected final transient Server server;
+ protected final transient Map chatStorage;
public EssentialsChatPlayer(
final Server server, final IEssentials ess, final Map chatStorage)
@@ -83,10 +83,9 @@ public abstract class EssentialsChatPlayer implements Listener
{
event.setFormat(
format.format(
- new Object[]
- {
- group, world, world.substring(0, 1).toUpperCase(Locale.ENGLISH)
- }));
+ new Object[]{
+ group, world, world.substring(0, 1).toUpperCase(Locale.ENGLISH)
+ }));
}
}
diff --git a/EssentialsChat/src/net/ess3/chat/EssentialsLocalChatEventListener.java b/EssentialsChat/src/net/ess3/chat/EssentialsLocalChatEventListener.java
index 568657907..b6b93c0bf 100644
--- a/EssentialsChat/src/net/ess3/chat/EssentialsLocalChatEventListener.java
+++ b/EssentialsChat/src/net/ess3/chat/EssentialsLocalChatEventListener.java
@@ -14,8 +14,8 @@ import org.bukkit.event.Listener;
public class EssentialsLocalChatEventListener implements Listener
{
- protected IEssentials ess;
- protected final Server server;
+ protected transient IEssentials ess;
+ protected final transient Server server;
public EssentialsLocalChatEventListener(final Server server, final IEssentials ess)
{
diff --git a/EssentialsExtra/pom.xml b/EssentialsExtra/pom.xml
index 0caa52250..fc2f8e23f 100644
--- a/EssentialsExtra/pom.xml
+++ b/EssentialsExtra/pom.xml
@@ -1,20 +1,20 @@
- 4.0.0
+ 4.0.0
-
- net.essentials3
- BuildAll
- 3.0-SNAPSHOT
- ../pom.xml
-
+
+ net.essentials3
+ BuildAll
+ 3.0-SNAPSHOT
+ ../pom.xml
+
- EssentialsExtra
-
-
- ${project.groupId}
- Essentials
- ${project.version}
-
-
+ EssentialsExtra
+
+
+ ${project.groupId}
+ Essentials
+ ${project.version}
+
+
diff --git a/EssentialsExtra/src/net/ess3/extra/AnnotatedCommand.java b/EssentialsExtra/src/net/ess3/extra/AnnotatedCommand.java
index 258b53bb5..05418e9d8 100644
--- a/EssentialsExtra/src/net/ess3/extra/AnnotatedCommand.java
+++ b/EssentialsExtra/src/net/ess3/extra/AnnotatedCommand.java
@@ -14,7 +14,6 @@ public @interface AnnotatedCommand
String usage() default "";
- String[] aliases() default
- {
+ String[] aliases() default {
};
}
diff --git a/EssentialsExtra/src/net/ess3/extra/EssentialsExtra.java b/EssentialsExtra/src/net/ess3/extra/EssentialsExtra.java
index 90cfb85aa..4445dbd11 100644
--- a/EssentialsExtra/src/net/ess3/extra/EssentialsExtra.java
+++ b/EssentialsExtra/src/net/ess3/extra/EssentialsExtra.java
@@ -68,9 +68,8 @@ public class EssentialsExtra extends JavaPlugin
}
}
}
- urls = new URL[]
- {
- commandDir.toURI().toURL()
+ urls = new URL[]{
+ commandDir.toURI().toURL()
};
}
catch (Exception ex)
diff --git a/EssentialsExtra/src/net/ess3/extra/commands/Commandkittycannon.java b/EssentialsExtra/src/net/ess3/extra/commands/Commandkittycannon.java
index 36ee400e0..a6173a243 100644
--- a/EssentialsExtra/src/net/ess3/extra/commands/Commandkittycannon.java
+++ b/EssentialsExtra/src/net/ess3/extra/commands/Commandkittycannon.java
@@ -1,5 +1,6 @@
package net.ess3.extra.commands;
+
import java.util.Random;
import net.ess3.api.IUser;
import net.ess3.commands.EssentialsCommand;
diff --git a/EssentialsGeoIP/src/net/ess3/geoip/ConfigHolder.java b/EssentialsGeoIP/src/net/ess3/geoip/ConfigHolder.java
index 07e68c3ee..c535ed4a0 100644
--- a/EssentialsGeoIP/src/net/ess3/geoip/ConfigHolder.java
+++ b/EssentialsGeoIP/src/net/ess3/geoip/ConfigHolder.java
@@ -9,8 +9,8 @@ import org.bukkit.plugin.Plugin;
public class ConfigHolder extends AsyncStorageObjectHolder
{
- private final Plugin geoip;
-
+ private final transient Plugin geoip;
+
public ConfigHolder(final IEssentials ess, final Plugin geoip)
{
super(ess, GeoIP.class, new File(geoip.getDataFolder(), "config.yml"));
diff --git a/EssentialsGeoIP/src/net/ess3/geoip/EssentialsGeoIPPlayerListener.java b/EssentialsGeoIP/src/net/ess3/geoip/EssentialsGeoIPPlayerListener.java
index c305c024f..d899ed972 100644
--- a/EssentialsGeoIP/src/net/ess3/geoip/EssentialsGeoIPPlayerListener.java
+++ b/EssentialsGeoIP/src/net/ess3/geoip/EssentialsGeoIPPlayerListener.java
@@ -26,12 +26,12 @@ import org.bukkit.plugin.Plugin;
public class EssentialsGeoIPPlayerListener implements Listener, IReload
{
- private LookupService ls = null;
+ private transient LookupService ls = null;
private static final Logger LOGGER = Logger.getLogger("Minecraft");
- private File databaseFile;
- private final ConfigHolder config;
- private final IEssentials ess;
- private final Plugin geoip;
+ private transient File databaseFile;
+ private final transient ConfigHolder config;
+ private final transient IEssentials ess;
+ private final transient Plugin geoip;
public EssentialsGeoIPPlayerListener(final Plugin geoip, final IEssentials ess)
{
diff --git a/EssentialsProtect/src/net/ess3/protect/EssentialsConnect.java b/EssentialsProtect/src/net/ess3/protect/EssentialsConnect.java
index 7ccbd1f92..b91f6740e 100644
--- a/EssentialsProtect/src/net/ess3/protect/EssentialsConnect.java
+++ b/EssentialsProtect/src/net/ess3/protect/EssentialsConnect.java
@@ -11,8 +11,8 @@ import org.bukkit.plugin.Plugin;
public class EssentialsConnect
{
private static final Logger LOGGER = Logger.getLogger("Minecraft");
- private final IEssentials ess;
- private final IProtect protect;
+ private final transient IEssentials ess;
+ private final transient IProtect protect;
public EssentialsConnect(final Plugin essPlugin, final Plugin essProtect)
{
diff --git a/EssentialsProtect/src/net/ess3/protect/EssentialsProtect.java b/EssentialsProtect/src/net/ess3/protect/EssentialsProtect.java
index dec2ecd8f..98e0596f2 100644
--- a/EssentialsProtect/src/net/ess3/protect/EssentialsProtect.java
+++ b/EssentialsProtect/src/net/ess3/protect/EssentialsProtect.java
@@ -11,8 +11,8 @@ import org.bukkit.plugin.java.JavaPlugin;
public class EssentialsProtect extends JavaPlugin implements IProtect
{
private static final Logger LOGGER = Logger.getLogger("Minecraft");
- private EssentialsConnect ess = null;
- private ProtectHolder settings = null;
+ private transient EssentialsConnect ess = null;
+ private transient ProtectHolder settings = null;
@Override
public void onEnable()
diff --git a/EssentialsProtect/src/net/ess3/protect/EssentialsProtectBlockListener.java b/EssentialsProtect/src/net/ess3/protect/EssentialsProtectBlockListener.java
index 01fc2651b..6446adc44 100644
--- a/EssentialsProtect/src/net/ess3/protect/EssentialsProtectBlockListener.java
+++ b/EssentialsProtect/src/net/ess3/protect/EssentialsProtectBlockListener.java
@@ -13,7 +13,7 @@ import org.bukkit.event.block.BlockIgniteEvent;
public class EssentialsProtectBlockListener implements Listener
{
- final private IProtect prot;
+ final private transient IProtect prot;
public EssentialsProtectBlockListener(final IProtect parent)
{
diff --git a/EssentialsProtect/src/net/ess3/protect/EssentialsProtectEntityListener.java b/EssentialsProtect/src/net/ess3/protect/EssentialsProtectEntityListener.java
index f111c7b78..4fa71139b 100644
--- a/EssentialsProtect/src/net/ess3/protect/EssentialsProtectEntityListener.java
+++ b/EssentialsProtect/src/net/ess3/protect/EssentialsProtectEntityListener.java
@@ -11,7 +11,7 @@ import org.bukkit.event.entity.EntityTargetEvent.TargetReason;
//TODO: remove unnecessary return statements
public class EssentialsProtectEntityListener implements Listener
{
- private final IProtect prot;
+ private final transient IProtect prot;
public EssentialsProtectEntityListener(final IProtect prot)
{
@@ -47,7 +47,7 @@ public class EssentialsProtectEntityListener implements Listener
return;
}
if (cause == DamageCause.BLOCK_EXPLOSION && (Permissions.PREVENTDAMAGE_TNT.isAuthorized(user) && !Permissions.PREVENTDAMAGE_NONE.isAuthorized(
- user)))
+ user)))
{
event.setCancelled(true);
return;
@@ -69,21 +69,21 @@ public class EssentialsProtectEntityListener implements Listener
//Creeper explode prevention
if (eAttack instanceof Creeper && settings.getData().getPrevent().isCreeperExplosion() || (Permissions.PREVENTDAMAGE_CREEPER.isAuthorized(
- user) && !Permissions.PREVENTDAMAGE_NONE.isAuthorized(user)))
+ user) && !Permissions.PREVENTDAMAGE_NONE.isAuthorized(user)))
{
event.setCancelled(true);
return;
}
if ((event.getEntity() instanceof Fireball || event.getEntity() instanceof SmallFireball) && (Permissions.PREVENTDAMAGE_FIREBALL.isAuthorized(
- user) && !Permissions.PREVENTDAMAGE_NONE.isAuthorized(user)))
+ user) && !Permissions.PREVENTDAMAGE_NONE.isAuthorized(user)))
{
event.setCancelled(true);
return;
}
if ((event.getEntity() instanceof WitherSkull && Permissions.PREVENTDAMAGE_WITHERSKULL.isAuthorized(
- user) && !Permissions.PREVENTDAMAGE_NONE.isAuthorized(user)))
+ user) && !Permissions.PREVENTDAMAGE_NONE.isAuthorized(user)))
{
event.setCancelled(true);
return;
@@ -96,9 +96,9 @@ public class EssentialsProtectEntityListener implements Listener
}
if (edEvent.getDamager() instanceof Projectile && ((Permissions.PREVENTDAMAGE_PROJECTILES.isAuthorized(
- user) && !Permissions.PREVENTDAMAGE_NONE.isAuthorized(
- user)) || (((Projectile)edEvent.getDamager()).getShooter() instanceof Player && (!Permissions.PVP.isAuthorized(
- user) || !Permissions.PVP.isAuthorized((Player)((Projectile)edEvent.getDamager()).getShooter())))))
+ user) && !Permissions.PREVENTDAMAGE_NONE.isAuthorized(
+ user)) || (((Projectile)edEvent.getDamager()).getShooter() instanceof Player && (!Permissions.PVP.isAuthorized(
+ user) || !Permissions.PVP.isAuthorized((Player)((Projectile)edEvent.getDamager()).getShooter())))))
{
event.setCancelled(true);
return;
@@ -115,13 +115,13 @@ public class EssentialsProtectEntityListener implements Listener
}
if (cause == DamageCause.SUFFOCATION && (Permissions.PREVENTDAMAGE_SUFFOCATION.isAuthorized(user) && !Permissions.PREVENTDAMAGE_NONE.isAuthorized(
- user)))
+ user)))
{
event.setCancelled(true);
return;
}
if ((cause == DamageCause.FIRE || cause == DamageCause.FIRE_TICK) && (Permissions.PREVENTDAMAGE_FIRE.isAuthorized(
- user) && !Permissions.PREVENTDAMAGE_NONE.isAuthorized(user)))
+ user) && !Permissions.PREVENTDAMAGE_NONE.isAuthorized(user)))
{
event.setCancelled(true);
return;
@@ -132,7 +132,7 @@ public class EssentialsProtectEntityListener implements Listener
return;
}
if (cause == DamageCause.LIGHTNING && (Permissions.PREVENTDAMAGE_LIGHTNING.isAuthorized(user) && !Permissions.PREVENTDAMAGE_NONE.isAuthorized(
- user)))
+ user)))
{
event.setCancelled(true);
}
@@ -143,8 +143,7 @@ public class EssentialsProtectEntityListener implements Listener
}
}
}
- // return statements are probably not needed here
-
+ // return statements are probably not needed here
@EventHandler(priority = EventPriority.HIGHEST, ignoreCancelled = true)
public void onEntityExplode(final EntityExplodeEvent event)
{
diff --git a/EssentialsProtect/src/net/ess3/protect/EssentialsProtectWeatherListener.java b/EssentialsProtect/src/net/ess3/protect/EssentialsProtectWeatherListener.java
index b20f7b17d..c12dc4a52 100644
--- a/EssentialsProtect/src/net/ess3/protect/EssentialsProtectWeatherListener.java
+++ b/EssentialsProtect/src/net/ess3/protect/EssentialsProtectWeatherListener.java
@@ -10,7 +10,7 @@ import org.bukkit.event.weather.WeatherChangeEvent;
public class EssentialsProtectWeatherListener implements Listener
{
- private final IProtect prot;
+ private final transient IProtect prot;
public EssentialsProtectWeatherListener(final IProtect prot)
{
diff --git a/EssentialsProtect/src/net/ess3/protect/Permissions.java b/EssentialsProtect/src/net/ess3/protect/Permissions.java
index 3655924cd..7cacd741f 100644
--- a/EssentialsProtect/src/net/ess3/protect/Permissions.java
+++ b/EssentialsProtect/src/net/ess3/protect/Permissions.java
@@ -29,7 +29,7 @@ public enum Permissions implements IPermission
private static final String base = "essentials.protect.";
private final String permission;
private final PermissionDefault defaultPerm;
- private String parent = null;
+ private transient String parent = null;
private Permissions()
{
@@ -72,5 +72,6 @@ public enum Permissions implements IPermission
{
return PermissionFactory.checkPermission(sender, this);
}
+
public static DotStarPermission ENTITY_TARGET_BYPASS = new DotStarPermission("essentials.protect.entitytarget.bypass");
}
diff --git a/EssentialsSigns/pom.xml b/EssentialsSigns/pom.xml
index 781bd4512..85a47c60b 100644
--- a/EssentialsSigns/pom.xml
+++ b/EssentialsSigns/pom.xml
@@ -1,20 +1,20 @@
- 4.0.0
+ 4.0.0
-
- net.essentials3
- BuildAll
- 3.0-SNAPSHOT
- ../pom.xml
-
+
+ net.essentials3
+ BuildAll
+ 3.0-SNAPSHOT
+ ../pom.xml
+
- EssentialsSigns
-
-
- ${project.groupId}
- Essentials
- ${project.version}
-
-
+ EssentialsSigns
+
+
+ ${project.groupId}
+ Essentials
+ ${project.version}
+
+
diff --git a/EssentialsSigns/src/net/ess3/signs/EssentialsSign.java b/EssentialsSigns/src/net/ess3/signs/EssentialsSign.java
index cf1b44ef8..10ed1989d 100644
--- a/EssentialsSigns/src/net/ess3/signs/EssentialsSign.java
+++ b/EssentialsSigns/src/net/ess3/signs/EssentialsSign.java
@@ -22,7 +22,7 @@ import org.bukkit.inventory.ItemStack;
public class EssentialsSign
{
private static final Set EMPTY_SET = new HashSet();
- protected final String signName;
+ protected transient final String signName;
public EssentialsSign(final String signName)
{
@@ -212,9 +212,8 @@ public class EssentialsSign
{
return true;
}
- final BlockFace[] directions = new BlockFace[]
- {
- BlockFace.NORTH, BlockFace.EAST, BlockFace.SOUTH, BlockFace.WEST
+ final BlockFace[] directions = new BlockFace[]{
+ BlockFace.NORTH, BlockFace.EAST, BlockFace.SOUTH, BlockFace.WEST
};
for (BlockFace blockFace : directions)
{
@@ -255,7 +254,7 @@ public class EssentialsSign
{
return EMPTY_SET;
}
-
+
protected final void validateTrade(final ISign sign, final int index, final IEssentials ess) throws SignException
{
final String line = sign.getLine(index).trim();
@@ -431,8 +430,8 @@ public class EssentialsSign
static class EventSign implements ISign
{
- private final SignChangeEvent event;
- private final Block block;
+ private final transient SignChangeEvent event;
+ private final transient Block block;
public EventSign(final SignChangeEvent event)
{
@@ -467,8 +466,8 @@ public class EssentialsSign
public static class BlockSign implements ISign
{
- private final Sign sign;
- private final Block block;
+ private final transient Sign sign;
+ private final transient Block block;
public BlockSign(final Block block)
{
diff --git a/EssentialsSigns/src/net/ess3/signs/EssentialsSignsPlugin.java b/EssentialsSigns/src/net/ess3/signs/EssentialsSignsPlugin.java
index 29e2edd59..cdd4494ea 100644
--- a/EssentialsSigns/src/net/ess3/signs/EssentialsSignsPlugin.java
+++ b/EssentialsSigns/src/net/ess3/signs/EssentialsSignsPlugin.java
@@ -15,8 +15,8 @@ import org.bukkit.plugin.java.JavaPlugin;
public class EssentialsSignsPlugin extends JavaPlugin implements ISignsPlugin
{
- private static final Logger LOGGER = Bukkit.getLogger();
- private SignsConfigHolder config;
+ private static final transient Logger LOGGER = Bukkit.getLogger();
+ private transient SignsConfigHolder config;
@Override
public void onEnable()
diff --git a/EssentialsSigns/src/net/ess3/signs/SignConfig.java b/EssentialsSigns/src/net/ess3/signs/SignConfig.java
index 34516dbc4..1b8bfddc3 100644
--- a/EssentialsSigns/src/net/ess3/signs/SignConfig.java
+++ b/EssentialsSigns/src/net/ess3/signs/SignConfig.java
@@ -23,12 +23,13 @@ public class SignConfig implements StorageObject
{
this.signs = signs;
}
+
@Comment(
- {
- "How many times per second can Essentials signs be interacted with.",
- "Values should be between 1-20, 20 being virtually no lag protection.",
- "Lower numbers will reduce the possiblity of lag, but may annoy players."
- })
+ {
+ "How many times per second can Essentials signs be interacted with.",
+ "Values should be between 1-20, 20 being virtually no lag protection.",
+ "Lower numbers will reduce the possiblity of lag, but may annoy players."
+ })
private int signUsesPerSecond = 4;
public int getSignUsePerSecond()
diff --git a/EssentialsSigns/src/net/ess3/signs/SignsConfigHolder.java b/EssentialsSigns/src/net/ess3/signs/SignsConfigHolder.java
index 613c2edee..9c62337c4 100644
--- a/EssentialsSigns/src/net/ess3/signs/SignsConfigHolder.java
+++ b/EssentialsSigns/src/net/ess3/signs/SignsConfigHolder.java
@@ -9,7 +9,7 @@ import org.bukkit.plugin.Plugin;
public class SignsConfigHolder extends AsyncStorageObjectHolder
{
- private final Plugin plugin;
+ private final transient Plugin plugin;
private Set enabledSigns = new HashSet();
private boolean signsEnabled = false;
diff --git a/EssentialsSigns/src/net/ess3/signs/listeners/SignBlockListener.java b/EssentialsSigns/src/net/ess3/signs/listeners/SignBlockListener.java
index 69ca1b4c2..4aa8182b5 100644
--- a/EssentialsSigns/src/net/ess3/signs/listeners/SignBlockListener.java
+++ b/EssentialsSigns/src/net/ess3/signs/listeners/SignBlockListener.java
@@ -21,8 +21,8 @@ import org.bukkit.event.block.*;
public class SignBlockListener implements Listener
{
- private final IEssentials ess;
- private final ISignsPlugin plugin;
+ private final transient IEssentials ess;
+ private final transient ISignsPlugin plugin;
private final static Logger LOGGER = Logger.getLogger("Minecraft");
private final static int WALL_SIGN = Material.WALL_SIGN.getId();
private final static int SIGN_POST = Material.SIGN_POST.getId();
@@ -150,7 +150,7 @@ public class SignBlockListener implements Listener
final Block block = event.getBlock();
if (((block.getTypeId() == WALL_SIGN || block.getTypeId() == SIGN_POST) && EssentialsSign.isValidSign(
- new EssentialsSign.BlockSign(block))) || EssentialsSign.checkIfBlockBreaksSigns(block))
+ new EssentialsSign.BlockSign(block))) || EssentialsSign.checkIfBlockBreaksSigns(block))
{
event.setCancelled(true);
return;
@@ -175,7 +175,7 @@ public class SignBlockListener implements Listener
final Block block = event.getBlock();
if (((block.getTypeId() == WALL_SIGN || block.getTypeId() == SIGN_POST) && EssentialsSign.isValidSign(
- new EssentialsSign.BlockSign(block))) || EssentialsSign.checkIfBlockBreaksSigns(block))
+ new EssentialsSign.BlockSign(block))) || EssentialsSign.checkIfBlockBreaksSigns(block))
{
event.setCancelled(true);
return;
@@ -201,7 +201,7 @@ public class SignBlockListener implements Listener
for (Block block : event.getBlocks())
{
if (((block.getTypeId() == WALL_SIGN || block.getTypeId() == SIGN_POST) && EssentialsSign.isValidSign(
- new EssentialsSign.BlockSign(block))) || EssentialsSign.checkIfBlockBreaksSigns(block))
+ new EssentialsSign.BlockSign(block))) || EssentialsSign.checkIfBlockBreaksSigns(block))
{
event.setCancelled(true);
return;
@@ -229,7 +229,7 @@ public class SignBlockListener implements Listener
{
final Block block = event.getBlock();
if (((block.getTypeId() == WALL_SIGN || block.getTypeId() == SIGN_POST) && EssentialsSign.isValidSign(
- new EssentialsSign.BlockSign(block))) || EssentialsSign.checkIfBlockBreaksSigns(block))
+ new EssentialsSign.BlockSign(block))) || EssentialsSign.checkIfBlockBreaksSigns(block))
{
event.setCancelled(true);
return;
diff --git a/EssentialsSigns/src/net/ess3/signs/listeners/SignEntityListener.java b/EssentialsSigns/src/net/ess3/signs/listeners/SignEntityListener.java
index be1e5398e..3c9d63977 100644
--- a/EssentialsSigns/src/net/ess3/signs/listeners/SignEntityListener.java
+++ b/EssentialsSigns/src/net/ess3/signs/listeners/SignEntityListener.java
@@ -14,8 +14,8 @@ import org.bukkit.event.entity.EntityExplodeEvent;
public class SignEntityListener implements Listener
{
- private final IEssentials ess;
- private final ISignsPlugin plugin;
+ private final transient IEssentials ess;
+ private final transient ISignsPlugin plugin;
public SignEntityListener(final IEssentials ess, final ISignsPlugin plugin)
{
@@ -34,7 +34,7 @@ public class SignEntityListener implements Listener
for (Block block : event.blockList())
{
if (((block.getTypeId() == Material.WALL_SIGN.getId() || block.getTypeId() == Material.SIGN_POST.getId()) && EssentialsSign.isValidSign(
- new EssentialsSign.BlockSign(block))) || EssentialsSign.checkIfBlockBreaksSigns(block))
+ new EssentialsSign.BlockSign(block))) || EssentialsSign.checkIfBlockBreaksSigns(block))
{
event.setCancelled(true);
return;
@@ -60,7 +60,7 @@ public class SignEntityListener implements Listener
final Block block = event.getBlock();
if (((block.getTypeId() == Material.WALL_SIGN.getId() || block.getTypeId() == Material.SIGN_POST.getId()) && EssentialsSign.isValidSign(
- new EssentialsSign.BlockSign(block))) || EssentialsSign.checkIfBlockBreaksSigns(block))
+ new EssentialsSign.BlockSign(block))) || EssentialsSign.checkIfBlockBreaksSigns(block))
{
event.setCancelled(true);
return;
diff --git a/EssentialsSigns/src/net/ess3/signs/listeners/SignPlayerListener.java b/EssentialsSigns/src/net/ess3/signs/listeners/SignPlayerListener.java
index d6c6e3ece..6d6f14b93 100644
--- a/EssentialsSigns/src/net/ess3/signs/listeners/SignPlayerListener.java
+++ b/EssentialsSigns/src/net/ess3/signs/listeners/SignPlayerListener.java
@@ -15,8 +15,8 @@ import org.bukkit.event.player.PlayerInteractEvent;
public class SignPlayerListener implements Listener
{
- private final IEssentials ess;
- private final ISignsPlugin plugin;
+ private final transient IEssentials ess;
+ private final transient ISignsPlugin plugin;
public SignPlayerListener(final IEssentials ess, final ISignsPlugin plugin)
{
diff --git a/EssentialsSigns/src/net/ess3/signs/signs/SignEnchant.java b/EssentialsSigns/src/net/ess3/signs/signs/SignEnchant.java
index b05bc10f2..50e99a8d7 100644
--- a/EssentialsSigns/src/net/ess3/signs/signs/SignEnchant.java
+++ b/EssentialsSigns/src/net/ess3/signs/signs/SignEnchant.java
@@ -90,7 +90,7 @@ public class SignEnchant extends EssentialsSign
final ItemStack playerHand = player.getPlayer().getItemInHand();
if (playerHand == null || playerHand.getAmount() != 1 || (playerHand.containsEnchantment(enchantment) && playerHand.getEnchantmentLevel(
- enchantment) == level))
+ enchantment) == level))
{
throw new SignException(_("missingItems", 1, sign.getLine(1)));
}
diff --git a/EssentialsSigns/src/net/ess3/signs/signs/SignKit.java b/EssentialsSigns/src/net/ess3/signs/signs/SignKit.java
index c962eae85..fc95f09d6 100644
--- a/EssentialsSigns/src/net/ess3/signs/signs/SignKit.java
+++ b/EssentialsSigns/src/net/ess3/signs/signs/SignKit.java
@@ -55,7 +55,7 @@ public class SignKit extends EssentialsSign
final String kitName = sign.getLine(1).toLowerCase(Locale.ENGLISH);
final String group = sign.getLine(2);
if ((!group.isEmpty() && ("§2Everyone".equals(group) || ess.getRanks().inGroup(player, group))) || (group.isEmpty() && Permissions.KITS.isAuthorized(
- player, kitName)))
+ player, kitName)))
{
final Trade charge = getTrade(sign, 3, ess);
charge.isAffordableFor(player);
diff --git a/EssentialsSigns/src/net/ess3/signs/signs/SignRepair.java b/EssentialsSigns/src/net/ess3/signs/signs/SignRepair.java
index 5b60c348c..cd3d9dc93 100644
--- a/EssentialsSigns/src/net/ess3/signs/signs/SignRepair.java
+++ b/EssentialsSigns/src/net/ess3/signs/signs/SignRepair.java
@@ -40,9 +40,8 @@ public class SignRepair extends EssentialsSign
Commandrepair command = new Commandrepair();
command.init(ess, "repair");
- String[] args = new String[]
- {
- sign.getLine(1)
+ String[] args = new String[]{
+ sign.getLine(1)
};
try
{
diff --git a/EssentialsSigns/src/net/ess3/signs/signs/SignWarp.java b/EssentialsSigns/src/net/ess3/signs/signs/SignWarp.java
index 750e71ee7..43e4792aa 100644
--- a/EssentialsSigns/src/net/ess3/signs/signs/SignWarp.java
+++ b/EssentialsSigns/src/net/ess3/signs/signs/SignWarp.java
@@ -53,7 +53,7 @@ public class SignWarp extends EssentialsSign
final String group = sign.getLine(2);
if ((!group.isEmpty() && ("§2Everyone".equals(group) || ess.getRanks().inGroup(player, group))) || (group.isEmpty() && Permissions.WARPS.isAuthorized(
- player, warpName)))
+ player, warpName)))
{
final Trade charge = getTrade(sign, 3, ess);
try
diff --git a/EssentialsUpdate/src/net/ess3/update/AbstractWorkListener.java b/EssentialsUpdate/src/net/ess3/update/AbstractWorkListener.java
index 6b39beb1a..e63508464 100644
--- a/EssentialsUpdate/src/net/ess3/update/AbstractWorkListener.java
+++ b/EssentialsUpdate/src/net/ess3/update/AbstractWorkListener.java
@@ -10,8 +10,9 @@ public abstract class AbstractWorkListener
this.plugin = plugin;
this.newVersionInfo = newVersionInfo;
}
- private final Plugin plugin;
- private final VersionInfo newVersionInfo;
+
+ private final transient Plugin plugin;
+ private final transient VersionInfo newVersionInfo;
public final void onWorkAbort()
{
diff --git a/EssentialsUpdate/src/net/ess3/update/EssentialsHelp.java b/EssentialsUpdate/src/net/ess3/update/EssentialsHelp.java
index 03d9bb937..a4629ce14 100644
--- a/EssentialsUpdate/src/net/ess3/update/EssentialsHelp.java
+++ b/EssentialsUpdate/src/net/ess3/update/EssentialsHelp.java
@@ -17,11 +17,11 @@ import org.bukkit.plugin.PluginManager;
public class EssentialsHelp implements Listener
{
- private Player chatUser;
- private final Server server;
- private final Plugin plugin;
- private IrcBot ircBot;
- private final Map commands = new HashMap();
+ private transient Player chatUser;
+ private final transient Server server;
+ private final transient Plugin plugin;
+ private transient IrcBot ircBot;
+ private final transient Map commands = new HashMap();
public EssentialsHelp(final Plugin plugin)
{
diff --git a/EssentialsUpdate/src/net/ess3/update/EssentialsUpdate.java b/EssentialsUpdate/src/net/ess3/update/EssentialsUpdate.java
index 13aec2c00..33875423a 100644
--- a/EssentialsUpdate/src/net/ess3/update/EssentialsUpdate.java
+++ b/EssentialsUpdate/src/net/ess3/update/EssentialsUpdate.java
@@ -9,8 +9,8 @@ import org.bukkit.plugin.java.JavaPlugin;
public class EssentialsUpdate extends JavaPlugin
{
- private EssentialsHelp essentialsHelp;
- private UpdateProcess updateProcess;
+ private transient EssentialsHelp essentialsHelp;
+ private transient UpdateProcess updateProcess;
@Override
public void onEnable()
diff --git a/EssentialsUpdate/src/net/ess3/update/GetFile.java b/EssentialsUpdate/src/net/ess3/update/GetFile.java
index 4b8d67562..9636e3bd1 100644
--- a/EssentialsUpdate/src/net/ess3/update/GetFile.java
+++ b/EssentialsUpdate/src/net/ess3/update/GetFile.java
@@ -14,8 +14,8 @@ import org.bukkit.Bukkit;
public class GetFile
{
- private URLConnection connection;
- private MessageDigest digest;
+ private transient URLConnection connection;
+ private transient MessageDigest digest;
public GetFile(final String urlString) throws MalformedURLException, IOException
{
diff --git a/EssentialsUpdate/src/net/ess3/update/ModuleInfo.java b/EssentialsUpdate/src/net/ess3/update/ModuleInfo.java
index e0380cf14..993575cbf 100644
--- a/EssentialsUpdate/src/net/ess3/update/ModuleInfo.java
+++ b/EssentialsUpdate/src/net/ess3/update/ModuleInfo.java
@@ -7,9 +7,9 @@ import org.bukkit.configuration.Configuration;
public class ModuleInfo
{
- private final String url;
- private final String version;
- private final String hash;
+ private final transient String url;
+ private final transient String version;
+ private final transient String hash;
public ModuleInfo(final Configuration updateConfig, final String path)
{
diff --git a/EssentialsUpdate/src/net/ess3/update/PastieUpload.java b/EssentialsUpdate/src/net/ess3/update/PastieUpload.java
index 0880960ea..fba475b70 100644
--- a/EssentialsUpdate/src/net/ess3/update/PastieUpload.java
+++ b/EssentialsUpdate/src/net/ess3/update/PastieUpload.java
@@ -11,7 +11,7 @@ import java.util.regex.Pattern;
public class PastieUpload
{
- private final PostToUrl connection;
+ private final transient PostToUrl connection;
private final Pattern pattern = Pattern.compile("(?s).*\\?key=([a-z0-9]+).*");
public PastieUpload() throws MalformedURLException
diff --git a/EssentialsUpdate/src/net/ess3/update/PostToUrl.java b/EssentialsUpdate/src/net/ess3/update/PostToUrl.java
index 5a1bddff9..28fc13c55 100644
--- a/EssentialsUpdate/src/net/ess3/update/PostToUrl.java
+++ b/EssentialsUpdate/src/net/ess3/update/PostToUrl.java
@@ -14,9 +14,9 @@ import java.util.Random;
public class PostToUrl
{
- private final URL url;
- private final String boundary;
- private final Random random = new Random();
+ private final transient URL url;
+ private final transient String boundary;
+ private final transient Random random = new Random();
private final static String CRLF = "\r\n";
private final static Charset UTF8 = Charset.forName("utf-8");
diff --git a/EssentialsUpdate/src/net/ess3/update/UpdateCheck.java b/EssentialsUpdate/src/net/ess3/update/UpdateCheck.java
index bd3e6300e..8e8b3e7ed 100644
--- a/EssentialsUpdate/src/net/ess3/update/UpdateCheck.java
+++ b/EssentialsUpdate/src/net/ess3/update/UpdateCheck.java
@@ -12,14 +12,14 @@ import org.bukkit.plugin.PluginManager;
public class UpdateCheck
{
- private CheckResult result = CheckResult.UNKNOWN;
- private Version currentVersion;
- private Version newVersion = null;
- private int bukkitResult = 0;
- private UpdateFile updateFile;
+ private transient CheckResult result = CheckResult.UNKNOWN;
+ private transient Version currentVersion;
+ private transient Version newVersion = null;
+ private transient int bukkitResult = 0;
+ private transient UpdateFile updateFile;
private final static int CHECK_INTERVAL = 20 * 60 * 60 * 6;
- private final Plugin plugin;
- private boolean essentialsInstalled;
+ private final transient Plugin plugin;
+ private transient boolean essentialsInstalled;
private final Pattern bukkitVersionPattern = Pattern.compile("git-Bukkit-(?:(?:[0-9]+)\\.)+[0-9]+-R[\\.0-9]+-(?:[0-9]+-g[0-9a-f]+-)?b([0-9]+)jnks.*");
public UpdateCheck(final Plugin plugin)
diff --git a/EssentialsUpdate/src/net/ess3/update/UpdateFile.java b/EssentialsUpdate/src/net/ess3/update/UpdateFile.java
index 117daab8c..a369ad44e 100644
--- a/EssentialsUpdate/src/net/ess3/update/UpdateFile.java
+++ b/EssentialsUpdate/src/net/ess3/update/UpdateFile.java
@@ -24,9 +24,9 @@ public class UpdateFile
private final static BigInteger PUBLIC_KEY = new BigInteger(
"5ha6a2d4qdy17ttkg8evh74sl5a87djojwenu12k1lvy8ui6003e6l06rntczpoh99mhc3txj8mqlxw111oyy9yl7s7qpyluyzix3j1odxrxx4u52gxvyu6qiteapczkzvi7rxgeqsozz7b19rdx73a7quo9ybwpz1cr82r7x5k0pg2a73pjjsv2j1awr13azo7klrcxp9y5xxwf5qv1s3tw4zqftli18u0ek5qkbzfbgk1v5n2f11pkwwk6p0mibrn26wnjbv11vyiqgu95o7busmt6vf5q7grpcenl637w83mbin56s3asj1131b2mscj9xep3cbj7la9tgsxl5bj87vzy8sk2d34kzwqdqgh9nry43nqqus12l1stmiv184r8r3jcy8w43e8h1u1mzklldb5eytkuhayqik8l3ns04hwt8sgacvw534be8sx26qrn5s1",
36);
- private final File file;
- private final Plugin plugin;
- private final TreeMap versions = new TreeMap();
+ private final transient File file;
+ private final transient Plugin plugin;
+ private final transient TreeMap versions = new TreeMap();
public UpdateFile(final Plugin plugin)
{
diff --git a/EssentialsUpdate/src/net/ess3/update/UpdateProcess.java b/EssentialsUpdate/src/net/ess3/update/UpdateProcess.java
index 9d09264e3..0e9f59283 100644
--- a/EssentialsUpdate/src/net/ess3/update/UpdateProcess.java
+++ b/EssentialsUpdate/src/net/ess3/update/UpdateProcess.java
@@ -18,10 +18,10 @@ import org.bukkit.plugin.Plugin;
// TODO: This whole thing should make use of the conversations api
public class UpdateProcess implements Listener
{
- private Player currentPlayer;
- private final Plugin plugin;
- private final UpdateCheck updateCheck;
- private StateMachine stateMachine;
+ private transient Player currentPlayer;
+ private final transient Plugin plugin;
+ private final transient UpdateCheck updateCheck;
+ private transient StateMachine stateMachine;
public UpdateProcess(final Plugin plugin, final UpdateCheck updateCheck)
{
@@ -96,8 +96,7 @@ public class UpdateProcess implements Listener
{
UpdateProcess.this.currentPlayer = null;
}
- //TODO: make sure this is threadsafe
-
+ //TODO: make sure this is threadsafe
@EventHandler(priority = EventPriority.LOWEST)
public void onPlayerChat(final AsyncPlayerChatEvent event)
{
diff --git a/EssentialsUpdate/src/net/ess3/update/Version.java b/EssentialsUpdate/src/net/ess3/update/Version.java
index 9910882c8..ee449186f 100644
--- a/EssentialsUpdate/src/net/ess3/update/Version.java
+++ b/EssentialsUpdate/src/net/ess3/update/Version.java
@@ -30,10 +30,11 @@ public class Version implements Comparable
{
return type;
}
- private final int major;
- private final int minor;
- private final int build;
- private final Type type;
+
+ private final transient int major;
+ private final transient int minor;
+ private final transient int build;
+ private final transient Type type;
public Version(final String versionString)
{
diff --git a/EssentialsUpdate/src/net/ess3/update/VersionInfo.java b/EssentialsUpdate/src/net/ess3/update/VersionInfo.java
index c9e0eb7ec..afbe87de8 100644
--- a/EssentialsUpdate/src/net/ess3/update/VersionInfo.java
+++ b/EssentialsUpdate/src/net/ess3/update/VersionInfo.java
@@ -9,10 +9,10 @@ import org.bukkit.configuration.Configuration;
public class VersionInfo
{
- private final List changelog;
- private final int minBukkit;
- private final int maxBukkit;
- private final Map modules;
+ private final transient List changelog;
+ private final transient int minBukkit;
+ private final transient int maxBukkit;
+ private final transient Map modules;
public VersionInfo(final Configuration updateConfig, final String path)
{
diff --git a/EssentialsUpdate/src/net/ess3/update/chat/AbstractFileCommand.java b/EssentialsUpdate/src/net/ess3/update/chat/AbstractFileCommand.java
index b6b83b0bb..fff363835 100644
--- a/EssentialsUpdate/src/net/ess3/update/chat/AbstractFileCommand.java
+++ b/EssentialsUpdate/src/net/ess3/update/chat/AbstractFileCommand.java
@@ -8,7 +8,7 @@ import org.bukkit.plugin.Plugin;
public abstract class AbstractFileCommand implements Command
{
- private final Plugin plugin;
+ private final transient Plugin plugin;
private final static Charset UTF8 = Charset.forName("utf-8");
public AbstractFileCommand(final Plugin plugin)
diff --git a/EssentialsUpdate/src/net/ess3/update/chat/ErrorsCommand.java b/EssentialsUpdate/src/net/ess3/update/chat/ErrorsCommand.java
index 04832dbc0..6e3c29924 100644
--- a/EssentialsUpdate/src/net/ess3/update/chat/ErrorsCommand.java
+++ b/EssentialsUpdate/src/net/ess3/update/chat/ErrorsCommand.java
@@ -11,7 +11,7 @@ import org.bukkit.plugin.Plugin;
public class ErrorsCommand extends AbstractFileCommand implements Command
{
- private final Pattern pattern = Pattern.compile("^[0-9 :-]+\\[INFO\\].*");
+ private final transient Pattern pattern = Pattern.compile("^[0-9 :-]+\\[INFO\\].*");
public ErrorsCommand(final Plugin plugin)
{
diff --git a/EssentialsUpdate/src/net/ess3/update/chat/IrcBot.java b/EssentialsUpdate/src/net/ess3/update/chat/IrcBot.java
index b33ff9dd7..348a9ae44 100644
--- a/EssentialsUpdate/src/net/ess3/update/chat/IrcBot.java
+++ b/EssentialsUpdate/src/net/ess3/update/chat/IrcBot.java
@@ -15,9 +15,9 @@ public class IrcBot extends PircBot
private static final String CHANNEL = "#essentials";
private static final int PORT = 6667;
private static final String SERVER = "irc.esper.net";
- private boolean reconnect = true;
- private final Player player;
- private boolean kicked = false;
+ private transient boolean reconnect = true;
+ private final transient Player player;
+ private transient boolean kicked = false;
public IrcBot(final Player player, final String nickName, final String versionString)
{
diff --git a/EssentialsUpdate/src/net/ess3/update/chat/StartupCommand.java b/EssentialsUpdate/src/net/ess3/update/chat/StartupCommand.java
index 1ac171e42..978da60c2 100644
--- a/EssentialsUpdate/src/net/ess3/update/chat/StartupCommand.java
+++ b/EssentialsUpdate/src/net/ess3/update/chat/StartupCommand.java
@@ -11,8 +11,8 @@ import org.bukkit.plugin.Plugin;
public class StartupCommand extends AbstractFileCommand implements Command
{
- private final Pattern patternStart = Pattern.compile("^[0-9 :-]+\\[INFO\\] Starting minecraft server version.*");
- private final Pattern patternEnd = Pattern.compile("^[0-9 :-]+\\[INFO\\] Done \\([0-9.,]+s\\)! For help, type \"help\".*");
+ private final transient Pattern patternStart = Pattern.compile("^[0-9 :-]+\\[INFO\\] Starting minecraft server version.*");
+ private final transient Pattern patternEnd = Pattern.compile("^[0-9 :-]+\\[INFO\\] Done \\([0-9.,]+s\\)! For help, type \"help\".*");
public StartupCommand(final Plugin plugin)
{
diff --git a/EssentialsUpdate/src/net/ess3/update/states/AbstractState.java b/EssentialsUpdate/src/net/ess3/update/states/AbstractState.java
index ddcba9250..783ba19a1 100644
--- a/EssentialsUpdate/src/net/ess3/update/states/AbstractState.java
+++ b/EssentialsUpdate/src/net/ess3/update/states/AbstractState.java
@@ -6,8 +6,8 @@ import org.bukkit.entity.Player;
public abstract class AbstractState
{
- private boolean abortion = false;
- private final StateMap stateMap;
+ private transient boolean abortion = false;
+ private final transient StateMap stateMap;
public AbstractState(final StateMap stateMap)
{
diff --git a/EssentialsUpdate/src/net/ess3/update/states/AbstractYesNoState.java b/EssentialsUpdate/src/net/ess3/update/states/AbstractYesNoState.java
index 0747c188b..e84046224 100644
--- a/EssentialsUpdate/src/net/ess3/update/states/AbstractYesNoState.java
+++ b/EssentialsUpdate/src/net/ess3/update/states/AbstractYesNoState.java
@@ -4,8 +4,8 @@ package net.ess3.update.states;
public abstract class AbstractYesNoState extends AbstractState
{
private boolean answer = false;
- private final Class extends AbstractState> yesState;
- private final Class extends AbstractState> noState;
+ private final transient Class extends AbstractState> yesState;
+ private final transient Class extends AbstractState> noState;
public AbstractYesNoState(final StateMap states, final Class extends AbstractState> nextState)
{
diff --git a/EssentialsUpdate/src/net/ess3/update/states/Changelog.java b/EssentialsUpdate/src/net/ess3/update/states/Changelog.java
index 9f6fc1a46..eccc4548a 100644
--- a/EssentialsUpdate/src/net/ess3/update/states/Changelog.java
+++ b/EssentialsUpdate/src/net/ess3/update/states/Changelog.java
@@ -9,10 +9,10 @@ import org.bukkit.entity.Player;
public class Changelog extends AbstractState
{
private static final int CHANGES_PER_PAGE = 5;
- private int page = 0;
- private boolean confirmed = false;
- private final List changes;
- private final int pages;
+ private transient int page = 0;
+ private transient boolean confirmed = false;
+ private transient final List changes;
+ private transient final int pages;
public Changelog(final StateMap stateMap)
{
diff --git a/EssentialsUpdate/src/net/ess3/update/states/StateMachine.java b/EssentialsUpdate/src/net/ess3/update/states/StateMachine.java
index ae947e687..c9dbb1f6a 100644
--- a/EssentialsUpdate/src/net/ess3/update/states/StateMachine.java
+++ b/EssentialsUpdate/src/net/ess3/update/states/StateMachine.java
@@ -14,10 +14,12 @@ public class StateMachine extends AbstractWorkListener implements Runnable
{
ABORT, WAIT, DONE, NONE
}
- private final StateMap states = new StateMap();
- private AbstractState current;
- private Player player;
- private MachineResult result = MachineResult.NONE;
+
+
+ private final transient StateMap states = new StateMap();
+ private transient AbstractState current;
+ private transient Player player;
+ private transient MachineResult result = MachineResult.NONE;
public StateMachine(final Plugin plugin, final Player player, final UpdateCheck updateCheck)
{
@@ -82,7 +84,8 @@ public class StateMachine extends AbstractWorkListener implements Runnable
}
return result;
}
- private Iterator iterator;
+
+ private transient Iterator iterator;
public void startWork()
{
diff --git a/EssentialsUpdate/src/net/ess3/update/states/UpdateOrInstallation.java b/EssentialsUpdate/src/net/ess3/update/states/UpdateOrInstallation.java
index e8495fe2c..bc043c6de 100644
--- a/EssentialsUpdate/src/net/ess3/update/states/UpdateOrInstallation.java
+++ b/EssentialsUpdate/src/net/ess3/update/states/UpdateOrInstallation.java
@@ -6,8 +6,8 @@ import org.bukkit.entity.Player;
public class UpdateOrInstallation extends AbstractState
{
- private final UpdateCheck updateCheck;
- private boolean update = false;
+ private final transient UpdateCheck updateCheck;
+ private transient boolean update = false;
public UpdateOrInstallation(final StateMap stateMap, final UpdateCheck updateCheck)
{
diff --git a/EssentialsUpdate/src/net/ess3/update/tasks/InstallModule.java b/EssentialsUpdate/src/net/ess3/update/tasks/InstallModule.java
index e24a69f2a..82e906d90 100644
--- a/EssentialsUpdate/src/net/ess3/update/tasks/InstallModule.java
+++ b/EssentialsUpdate/src/net/ess3/update/tasks/InstallModule.java
@@ -12,9 +12,9 @@ import org.bukkit.Bukkit;
public class InstallModule implements Runnable, Task
{
- protected final AbstractWorkListener listener;
- private final String moduleName;
- private final String fileName;
+ protected final transient AbstractWorkListener listener;
+ private final transient String moduleName;
+ private final transient String fileName;
public InstallModule(final AbstractWorkListener listener, final String moduleName)
{
diff --git a/EssentialsUpdate/src/net/ess3/update/tasks/SelfUpdate.java b/EssentialsUpdate/src/net/ess3/update/tasks/SelfUpdate.java
index d4bc7b066..31d45e741 100644
--- a/EssentialsUpdate/src/net/ess3/update/tasks/SelfUpdate.java
+++ b/EssentialsUpdate/src/net/ess3/update/tasks/SelfUpdate.java
@@ -6,7 +6,7 @@ import org.bukkit.Bukkit;
public class SelfUpdate extends AbstractWorkListener implements Task, Runnable
{
- private final AbstractWorkListener listener;
+ private final transient AbstractWorkListener listener;
public SelfUpdate(final AbstractWorkListener listener)
{
diff --git a/EssentialsXMPP/src/net/ess3/xmpp/EssentialsXMPP.java b/EssentialsXMPP/src/net/ess3/xmpp/EssentialsXMPP.java
index baafb27f0..fbfbbf56a 100644
--- a/EssentialsXMPP/src/net/ess3/xmpp/EssentialsXMPP.java
+++ b/EssentialsXMPP/src/net/ess3/xmpp/EssentialsXMPP.java
@@ -20,10 +20,10 @@ public class EssentialsXMPP extends JavaPlugin implements IEssentialsXMPP
{
private static final Logger LOGGER = Logger.getLogger("Minecraft");
private static EssentialsXMPP instance = null;
- private UserManager users;
- private XMPPManager xmpp;
- private IEssentials ess;
- private TabExecutor commandHandler;
+ private transient UserManager users;
+ private transient XMPPManager xmpp;
+ private transient IEssentials ess;
+ private transient TabExecutor commandHandler;
public static IEssentialsXMPP getInstance()
{
diff --git a/EssentialsXMPP/src/net/ess3/xmpp/EssentialsXMPPPlayerListener.java b/EssentialsXMPP/src/net/ess3/xmpp/EssentialsXMPPPlayerListener.java
index 0f27c05c9..85676198c 100644
--- a/EssentialsXMPP/src/net/ess3/xmpp/EssentialsXMPPPlayerListener.java
+++ b/EssentialsXMPP/src/net/ess3/xmpp/EssentialsXMPPPlayerListener.java
@@ -11,7 +11,7 @@ import org.bukkit.event.player.PlayerQuitEvent;
//TODO: port 2.9 changes and verify thread safety.
class EssentialsXMPPPlayerListener implements Listener
{
- private final IEssentials ess;
+ private final transient IEssentials ess;
EssentialsXMPPPlayerListener(final IEssentials ess)
{
diff --git a/EssentialsXMPP/src/net/ess3/xmpp/UserManager.java b/EssentialsXMPP/src/net/ess3/xmpp/UserManager.java
index 0e0c48b4e..c80680445 100644
--- a/EssentialsXMPP/src/net/ess3/xmpp/UserManager.java
+++ b/EssentialsXMPP/src/net/ess3/xmpp/UserManager.java
@@ -11,9 +11,9 @@ import org.bukkit.configuration.file.YamlConfiguration;
public class UserManager implements IReload
{
- private YamlConfiguration users;
- private final File folder;
- private final List spyusers = new ArrayList();
+ private transient YamlConfiguration users;
+ private final transient File folder;
+ private final transient List spyusers = new ArrayList();
private final static String ADDRESS = "address";
private final static String SPY = "spy";
diff --git a/EssentialsXMPP/src/net/ess3/xmpp/XMPPManager.java b/EssentialsXMPP/src/net/ess3/xmpp/XMPPManager.java
index 34d98cb11..a04ab25d9 100644
--- a/EssentialsXMPP/src/net/ess3/xmpp/XMPPManager.java
+++ b/EssentialsXMPP/src/net/ess3/xmpp/XMPPManager.java
@@ -19,17 +19,17 @@ public final class XMPPManager extends Handler implements MessageListener, ChatM
{
private static final Logger LOGGER = Logger.getLogger("Minecraft");
private static final SimpleFormatter formatter = new SimpleFormatter();
- private YamlConfiguration config = null;
- private XMPPConnection connection;
- private ChatManager chatManager;
- private final Map chats = Collections.synchronizedMap(new HashMap());
- private final Set logrecords = Collections.synchronizedSet(new HashSet());
- private final IEssentialsXMPP parent;
- private List logUsers;
- private Level logLevel;
- private boolean ignoreLagMessages = true;
- private Thread loggerThread;
- private boolean threadrunning = true;
+ private transient YamlConfiguration config = null;
+ private transient XMPPConnection connection;
+ private transient ChatManager chatManager;
+ private final transient Map chats = Collections.synchronizedMap(new HashMap());
+ private final transient Set logrecords = Collections.synchronizedSet(new HashSet());
+ private final transient IEssentialsXMPP parent;
+ private transient List logUsers;
+ private transient Level logLevel;
+ private transient boolean ignoreLagMessages = true;
+ private transient Thread loggerThread;
+ private transient boolean threadrunning = true;
public XMPPManager(final IEssentialsXMPP parent)
{