From 0711454e3160e0aff311d52a97f7eea0f26fe7ab Mon Sep 17 00:00:00 2001 From: GJ Date: Mon, 21 Jan 2013 17:22:54 -0500 Subject: [PATCH] General cleanup to satisfy my OCD a little while longer. --- .../nossr50/commands/mc/McrankCommand.java | 18 +-- .../nossr50/commands/mc/MctopCommand.java | 4 +- .../commands/skills/AcrobaticsCommand.java | 6 +- .../commands/skills/ArcheryCommand.java | 14 +- .../nossr50/commands/spout/MchudCommand.java | 2 +- .../java/com/gmail/nossr50/config/Config.java | 14 +- .../gmail/nossr50/datatypes/AbilityType.java | 128 +++++++++--------- .../nossr50/datatypes/DatabaseUpdate.java | 2 +- .../nossr50/datatypes/PlayerProfile.java | 2 +- .../gmail/nossr50/datatypes/SkillType.java | 4 +- .../nossr50/listeners/BlockListener.java | 2 +- .../nossr50/listeners/EntityListener.java | 2 +- .../nossr50/listeners/SpoutListener.java | 2 +- .../nossr50/listeners/WorldListener.java | 2 +- src/main/java/com/gmail/nossr50/mcMMO.java | 5 +- .../nossr50/runnables/GreenThumbTimer.java | 2 +- .../nossr50/runnables/MobStoreCleaner.java | 3 +- .../nossr50/runnables/UserPurgeTask.java | 2 +- .../BlockStoreConversionMain.java | 3 +- .../BlockStoreConversionXDirectory.java | 3 +- .../BlockStoreConversionZDirectory.java | 6 +- .../nossr50/skills/gathering/Herbalism.java | 14 +- .../nossr50/skills/gathering/WoodCutting.java | 4 +- .../mining/BiggerBombsEventHandler.java | 2 +- .../gmail/nossr50/skills/mining/Mining.java | 2 +- .../mining/SuperBreakerEventHandler.java | 4 +- .../gmail/nossr50/skills/repair/Repair.java | 4 +- .../gmail/nossr50/skills/unarmed/Unarmed.java | 2 +- .../com/gmail/nossr50/util/Anniversary.java | 2 +- .../java/com/gmail/nossr50/util/Database.java | 8 +- .../com/gmail/nossr50/util/ItemChecks.java | 6 +- .../com/gmail/nossr50/util/Leaderboard.java | 30 ++-- .../com/gmail/nossr50/util/Permissions.java | 2 +- .../blockmeta/chunkmeta/HashChunkManager.java | 14 +- .../blockmeta/chunkmeta/NullChunkManager.java | 7 + .../chunkmeta/PrimitiveChunkStore.java | 14 +- .../PrimitiveExChunkletStoreTest.java | 2 +- 37 files changed, 180 insertions(+), 163 deletions(-) diff --git a/src/main/java/com/gmail/nossr50/commands/mc/McrankCommand.java b/src/main/java/com/gmail/nossr50/commands/mc/McrankCommand.java index 790938669..5022af756 100644 --- a/src/main/java/com/gmail/nossr50/commands/mc/McrankCommand.java +++ b/src/main/java/com/gmail/nossr50/commands/mc/McrankCommand.java @@ -31,16 +31,16 @@ public class McrankCommand implements CommandExecutor { Player player = (Player) sender; String playerName; switch (args.length) { - case 0: - playerName = player.getName(); - break; + case 0: + playerName = player.getName(); + break; - case 1: - playerName = args[0]; - break; + case 1: + playerName = args[0]; + break; - default: - return false; + default: + return false; } if (Config.getInstance().getUseMySQL()) { @@ -73,7 +73,7 @@ public class McrankCommand implements CommandExecutor { //Show the powerlevel ranking int[] rankInts = Leaderboard.getPlayerRank(playerName, SkillType.ALL); - + if (rankInts[1] == 0) { sender.sendMessage(LocaleLoader.getString("Commands.mcrank.Overalll", new Object[] {LocaleLoader.getString("Commands.mcrank.Unranked")} )); //Don't bother showing ranking for players without skills } diff --git a/src/main/java/com/gmail/nossr50/commands/mc/MctopCommand.java b/src/main/java/com/gmail/nossr50/commands/mc/MctopCommand.java index c32457b85..aa59e7896 100644 --- a/src/main/java/com/gmail/nossr50/commands/mc/MctopCommand.java +++ b/src/main/java/com/gmail/nossr50/commands/mc/MctopCommand.java @@ -118,8 +118,8 @@ public class MctopCommand implements CommandExecutor { } private void flatfileDisplay(int page, String skill, CommandSender sender) { - Leaderboard.updateLeaderboards(); //Make sure we have the latest information - SkillType skillType = SkillType.getSkill(skill); + Leaderboard.updateLeaderboards(); //Make sure we have the latest information + SkillType skillType = SkillType.getSkill(skill); String[] info = Leaderboard.retrieveInfo(skillType, page); if (skill.equalsIgnoreCase("ALL")) { diff --git a/src/main/java/com/gmail/nossr50/commands/skills/AcrobaticsCommand.java b/src/main/java/com/gmail/nossr50/commands/skills/AcrobaticsCommand.java index 6f2735e4e..d152a4a95 100644 --- a/src/main/java/com/gmail/nossr50/commands/skills/AcrobaticsCommand.java +++ b/src/main/java/com/gmail/nossr50/commands/skills/AcrobaticsCommand.java @@ -95,21 +95,21 @@ public class AcrobaticsCommand extends SkillCommand { if (canRoll) { if (lucky) player.sendMessage(LocaleLoader.getString("Acrobatics.Roll.Chance", new Object[] { rollChance }) + LocaleLoader.getString("Perks.lucky.bonus", new Object[] { rollChanceLucky })); - else + else player.sendMessage(LocaleLoader.getString("Acrobatics.Roll.Chance", new Object[] { rollChance })); } if (canGracefulRoll) { if (lucky) player.sendMessage(LocaleLoader.getString("Acrobatics.Roll.GraceChance", new Object[] { gracefulRollChance }) + LocaleLoader.getString("Perks.lucky.bonus", new Object[] { gracefulRollChanceLucky })); - else + else player.sendMessage(LocaleLoader.getString("Acrobatics.Roll.GraceChance", new Object[] { gracefulRollChance })); } if (canDodge) { if (lucky) player.sendMessage(LocaleLoader.getString("Acrobatics.DodgeChance", new Object[] { dodgeChance }) + LocaleLoader.getString("Perks.lucky.bonus", new Object[] { dodgeChanceLucky })); - else + else player.sendMessage(LocaleLoader.getString("Acrobatics.DodgeChance", new Object[] { dodgeChance })); } } diff --git a/src/main/java/com/gmail/nossr50/commands/skills/ArcheryCommand.java b/src/main/java/com/gmail/nossr50/commands/skills/ArcheryCommand.java index c2ab95d58..1fc9d9500 100644 --- a/src/main/java/com/gmail/nossr50/commands/skills/ArcheryCommand.java +++ b/src/main/java/com/gmail/nossr50/commands/skills/ArcheryCommand.java @@ -89,21 +89,21 @@ public class ArcheryCommand extends SkillCommand { @Override protected void statsDisplay() { if (canSkillShot) { - player.sendMessage(LocaleLoader.getString("Archery.Combat.SkillshotBonus", new Object[] { skillShotBonus })); + player.sendMessage(LocaleLoader.getString("Archery.Combat.SkillshotBonus", new Object[] { skillShotBonus })); } if (canDaze) { if (lucky) - player.sendMessage(LocaleLoader.getString("Archery.Combat.DazeChance", new Object[] { dazeChance }) + LocaleLoader.getString("Perks.lucky.bonus", new Object[] { dazeChanceLucky })); - else - player.sendMessage(LocaleLoader.getString("Archery.Combat.DazeChance", new Object[] { dazeChance })); + player.sendMessage(LocaleLoader.getString("Archery.Combat.DazeChance", new Object[] { dazeChance }) + LocaleLoader.getString("Perks.lucky.bonus", new Object[] { dazeChanceLucky })); + else + player.sendMessage(LocaleLoader.getString("Archery.Combat.DazeChance", new Object[] { dazeChance })); } if (canRetrieve) { if (lucky) - player.sendMessage(LocaleLoader.getString("Archery.Combat.RetrieveChance", new Object[] { retrieveChance }) + LocaleLoader.getString("Perks.lucky.bonus", new Object[] { retrieveChanceLucky })); - else - player.sendMessage(LocaleLoader.getString("Archery.Combat.RetrieveChance", new Object[] { retrieveChance })); + player.sendMessage(LocaleLoader.getString("Archery.Combat.RetrieveChance", new Object[] { retrieveChance }) + LocaleLoader.getString("Perks.lucky.bonus", new Object[] { retrieveChanceLucky })); + else + player.sendMessage(LocaleLoader.getString("Archery.Combat.RetrieveChance", new Object[] { retrieveChance })); } } } diff --git a/src/main/java/com/gmail/nossr50/commands/spout/MchudCommand.java b/src/main/java/com/gmail/nossr50/commands/spout/MchudCommand.java index ca7dcee63..29bb9afd8 100644 --- a/src/main/java/com/gmail/nossr50/commands/spout/MchudCommand.java +++ b/src/main/java/com/gmail/nossr50/commands/spout/MchudCommand.java @@ -9,8 +9,8 @@ import com.gmail.nossr50.mcMMO; import com.gmail.nossr50.commands.CommandHelper; import com.gmail.nossr50.config.SpoutConfig; import com.gmail.nossr50.datatypes.HudType; -import com.gmail.nossr50.datatypes.SpoutHud; import com.gmail.nossr50.datatypes.PlayerProfile; +import com.gmail.nossr50.datatypes.SpoutHud; import com.gmail.nossr50.locale.LocaleLoader; import com.gmail.nossr50.util.Users; diff --git a/src/main/java/com/gmail/nossr50/config/Config.java b/src/main/java/com/gmail/nossr50/config/Config.java index cf92c4e30..6de1d6445 100644 --- a/src/main/java/com/gmail/nossr50/config/Config.java +++ b/src/main/java/com/gmail/nossr50/config/Config.java @@ -57,13 +57,13 @@ public class Config extends ConfigLoader { } private static String getStringIncludingInts(ConfigurationSection cfg, String key) { - String str = cfg.getString(key); - if (str == null) - str = String.valueOf(cfg.getInt(key)); - if (str == null) - str = "No value set for '" + key + "'"; - return str; - } + String str = cfg.getString(key); + if (str == null) + str = String.valueOf(cfg.getInt(key)); + if (str == null) + str = "No value set for '" + key + "'"; + return str; + } /* Hardcore Mode */ public boolean getHardcoreEnabled() { return config.getBoolean("Hardcore.Enabled", false); } diff --git a/src/main/java/com/gmail/nossr50/datatypes/AbilityType.java b/src/main/java/com/gmail/nossr50/datatypes/AbilityType.java index 79209bd11..63fd96844 100644 --- a/src/main/java/com/gmail/nossr50/datatypes/AbilityType.java +++ b/src/main/java/com/gmail/nossr50/datatypes/AbilityType.java @@ -19,77 +19,77 @@ public enum AbilityType { "Unarmed.Skills.Berserk.Refresh", "Unarmed.Skills.Berserk.Other.Off"), - SUPER_BREAKER( - Config.getInstance().getAbilityCooldownSuperBreaker(), - Config.getInstance().getAbilityMaxTicksSuperBreaker(), - "Mining.Skills.SuperBreaker.On", - "Mining.Skills.SuperBreaker.Off", - "Mining.Skills.SuperBreaker.Other.On", - "Mining.Skills.SuperBreaker.Refresh", - "Mining.Skills.SuperBreaker.Other.Off"), + SUPER_BREAKER( + Config.getInstance().getAbilityCooldownSuperBreaker(), + Config.getInstance().getAbilityMaxTicksSuperBreaker(), + "Mining.Skills.SuperBreaker.On", + "Mining.Skills.SuperBreaker.Off", + "Mining.Skills.SuperBreaker.Other.On", + "Mining.Skills.SuperBreaker.Refresh", + "Mining.Skills.SuperBreaker.Other.Off"), - GIGA_DRILL_BREAKER( - Config.getInstance().getAbilityCooldownGigaDrillBreaker(), - Config.getInstance().getAbilityMaxTicksGigaDrillBreaker(), - "Excavation.Skills.GigaDrillBreaker.On", - "Excavation.Skills.GigaDrillBreaker.Off", - "Excavation.Skills.GigaDrillBreaker.Other.On", - "Excavation.Skills.GigaDrillBreaker.Refresh", - "Excavation.Skills.GigaDrillBreaker.Other.Off"), + GIGA_DRILL_BREAKER( + Config.getInstance().getAbilityCooldownGigaDrillBreaker(), + Config.getInstance().getAbilityMaxTicksGigaDrillBreaker(), + "Excavation.Skills.GigaDrillBreaker.On", + "Excavation.Skills.GigaDrillBreaker.Off", + "Excavation.Skills.GigaDrillBreaker.Other.On", + "Excavation.Skills.GigaDrillBreaker.Refresh", + "Excavation.Skills.GigaDrillBreaker.Other.Off"), - GREEN_TERRA( - Config.getInstance().getAbilityCooldownGreenTerra(), - Config.getInstance().getAbilityMaxTicksGreenTerra(), - "Herbalism.Skills.GTe.On", - "Herbalism.Skills.GTe.Off", - "Herbalism.Skills.GTe.Other.On", - "Herbalism.Skills.GTe.Refresh", - "Herbalism.Skills.GTe.Other.Off"), + GREEN_TERRA( + Config.getInstance().getAbilityCooldownGreenTerra(), + Config.getInstance().getAbilityMaxTicksGreenTerra(), + "Herbalism.Skills.GTe.On", + "Herbalism.Skills.GTe.Off", + "Herbalism.Skills.GTe.Other.On", + "Herbalism.Skills.GTe.Refresh", + "Herbalism.Skills.GTe.Other.Off"), - SKULL_SPLIITER( - Config.getInstance().getAbilityCooldownSkullSplitter(), - Config.getInstance().getAbilityMaxTicksSkullSplitter(), - "Axes.Skills.SS.On", - "Axes.Skills.SS.Off", - "Axes.Skills.SS.Other.On", - "Axes.Skills.SS.Refresh", - "Axes.Skills.SS.Other.Off"), + SKULL_SPLIITER( + Config.getInstance().getAbilityCooldownSkullSplitter(), + Config.getInstance().getAbilityMaxTicksSkullSplitter(), + "Axes.Skills.SS.On", + "Axes.Skills.SS.Off", + "Axes.Skills.SS.Other.On", + "Axes.Skills.SS.Refresh", + "Axes.Skills.SS.Other.Off"), - TREE_FELLER( - Config.getInstance().getAbilityCooldownTreeFeller(), - Config.getInstance().getAbilityMaxTicksTreeFeller(), - "Woodcutting.Skills.TreeFeller.On", - "Woodcutting.Skills.TreeFeller.Off", - "Woodcutting.Skills.TreeFeller.Other.On", - "Woodcutting.Skills.TreeFeller.Refresh", - "Woodcutting.Skills.TreeFeller.Other.Off"), + TREE_FELLER( + Config.getInstance().getAbilityCooldownTreeFeller(), + Config.getInstance().getAbilityMaxTicksTreeFeller(), + "Woodcutting.Skills.TreeFeller.On", + "Woodcutting.Skills.TreeFeller.Off", + "Woodcutting.Skills.TreeFeller.Other.On", + "Woodcutting.Skills.TreeFeller.Refresh", + "Woodcutting.Skills.TreeFeller.Other.Off"), - SERRATED_STRIKES( - Config.getInstance().getAbilityCooldownSerratedStrikes(), - Config.getInstance().getAbilityMaxTicksSerratedStrikes(), - "Swords.Skills.SS.On", - "Swords.Skills.SS.Off", - "Swords.Skills.SS.Other.On", - "Swords.Skills.SS.Refresh", - "Swords.Skills.SS.Other.Off"), + SERRATED_STRIKES( + Config.getInstance().getAbilityCooldownSerratedStrikes(), + Config.getInstance().getAbilityMaxTicksSerratedStrikes(), + "Swords.Skills.SS.On", + "Swords.Skills.SS.Off", + "Swords.Skills.SS.Other.On", + "Swords.Skills.SS.Refresh", + "Swords.Skills.SS.Other.Off"), - BLAST_MINING( - Config.getInstance().getAbilityCooldownBlastMining(), - Config.getInstance().getAbilityMaxTicksBlastMining(), - null, - null, - "Mining.Blast.Other.On", - "Mining.Blast.Refresh", - null), + BLAST_MINING( + Config.getInstance().getAbilityCooldownBlastMining(), + Config.getInstance().getAbilityMaxTicksBlastMining(), + null, + null, + "Mining.Blast.Other.On", + "Mining.Blast.Refresh", + null), - LEAF_BLOWER( - 0, - 0, - null, - null, - null, - null, - null); + LEAF_BLOWER( + 0, + 0, + null, + null, + null, + null, + null); private int cooldown; private int maxTicks; diff --git a/src/main/java/com/gmail/nossr50/datatypes/DatabaseUpdate.java b/src/main/java/com/gmail/nossr50/datatypes/DatabaseUpdate.java index 0c75faf87..04689303e 100644 --- a/src/main/java/com/gmail/nossr50/datatypes/DatabaseUpdate.java +++ b/src/main/java/com/gmail/nossr50/datatypes/DatabaseUpdate.java @@ -3,6 +3,6 @@ package com.gmail.nossr50.datatypes; public enum DatabaseUpdate { FISHING, BLAST_MINING, - CASCADE_DELETE, + CASCADE_DELETE, INDEX; } \ No newline at end of file diff --git a/src/main/java/com/gmail/nossr50/datatypes/PlayerProfile.java b/src/main/java/com/gmail/nossr50/datatypes/PlayerProfile.java index aad5ad144..032d13d45 100644 --- a/src/main/java/com/gmail/nossr50/datatypes/PlayerProfile.java +++ b/src/main/java/com/gmail/nossr50/datatypes/PlayerProfile.java @@ -417,7 +417,7 @@ public class PlayerProfile { e.printStackTrace(); } } - lastSave = timestamp; + lastSave = timestamp; } public void addPlayer() { diff --git a/src/main/java/com/gmail/nossr50/datatypes/SkillType.java b/src/main/java/com/gmail/nossr50/datatypes/SkillType.java index ccfea7dea..b0216160d 100644 --- a/src/main/java/com/gmail/nossr50/datatypes/SkillType.java +++ b/src/main/java/com/gmail/nossr50/datatypes/SkillType.java @@ -117,12 +117,12 @@ public enum SkillType { public double getXpModifier() { return xpModifier; } - + public static SkillType getSkill(String skillName) { if (skillName.equalsIgnoreCase("powerlevel") || skillName.equalsIgnoreCase("all")) { return SkillType.ALL; } - + for (SkillType type : SkillType.values()) { if (type.name().equalsIgnoreCase(skillName)) { return type; diff --git a/src/main/java/com/gmail/nossr50/listeners/BlockListener.java b/src/main/java/com/gmail/nossr50/listeners/BlockListener.java index 74d3c1727..55dee4b61 100644 --- a/src/main/java/com/gmail/nossr50/listeners/BlockListener.java +++ b/src/main/java/com/gmail/nossr50/listeners/BlockListener.java @@ -30,8 +30,8 @@ import com.gmail.nossr50.events.fake.FakePlayerAnimationEvent; import com.gmail.nossr50.runnables.StickyPistonTracker; import com.gmail.nossr50.skills.gathering.Excavation; import com.gmail.nossr50.skills.gathering.Herbalism; -import com.gmail.nossr50.skills.mining.MiningManager; import com.gmail.nossr50.skills.gathering.WoodCutting; +import com.gmail.nossr50.skills.mining.MiningManager; import com.gmail.nossr50.skills.repair.Repair; import com.gmail.nossr50.skills.repair.Salvage; import com.gmail.nossr50.spout.SpoutSounds; diff --git a/src/main/java/com/gmail/nossr50/listeners/EntityListener.java b/src/main/java/com/gmail/nossr50/listeners/EntityListener.java index 8d9ea9cd8..8301d8b4b 100644 --- a/src/main/java/com/gmail/nossr50/listeners/EntityListener.java +++ b/src/main/java/com/gmail/nossr50/listeners/EntityListener.java @@ -172,7 +172,7 @@ public class EntityListener implements Listener { acroManager.rollCheck(event); } else if (cause == DamageCause.BLOCK_EXPLOSION && Permissions.demolitionsExpertise(player)) { - MiningManager miningManager = new MiningManager(player); + MiningManager miningManager = new MiningManager(player); miningManager.demolitionsExpertise(event); } diff --git a/src/main/java/com/gmail/nossr50/listeners/SpoutListener.java b/src/main/java/com/gmail/nossr50/listeners/SpoutListener.java index 3765240a0..edfedddd9 100644 --- a/src/main/java/com/gmail/nossr50/listeners/SpoutListener.java +++ b/src/main/java/com/gmail/nossr50/listeners/SpoutListener.java @@ -12,8 +12,8 @@ import org.getspout.spoutapi.player.SpoutPlayer; import com.gmail.nossr50.config.SpoutConfig; import com.gmail.nossr50.datatypes.McMMOPlayer; -import com.gmail.nossr50.datatypes.SpoutHud; import com.gmail.nossr50.datatypes.PlayerProfile; +import com.gmail.nossr50.datatypes.SpoutHud; import com.gmail.nossr50.datatypes.buttons.McmmoButton; import com.gmail.nossr50.datatypes.popups.Menu; import com.gmail.nossr50.locale.LocaleLoader; diff --git a/src/main/java/com/gmail/nossr50/listeners/WorldListener.java b/src/main/java/com/gmail/nossr50/listeners/WorldListener.java index 0f0fdcb8c..eb60ff737 100644 --- a/src/main/java/com/gmail/nossr50/listeners/WorldListener.java +++ b/src/main/java/com/gmail/nossr50/listeners/WorldListener.java @@ -36,7 +36,7 @@ public class WorldListener implements Listener { if (mcMMO.placeStore.isTrue(event.getLocation().getBlock())) { for (BlockState block : event.getBlocks()) { mcMMO.placeStore.setFalse(block.getBlock()); - } + } } } diff --git a/src/main/java/com/gmail/nossr50/mcMMO.java b/src/main/java/com/gmail/nossr50/mcMMO.java index a7df6d25f..074ebbeb9 100644 --- a/src/main/java/com/gmail/nossr50/mcMMO.java +++ b/src/main/java/com/gmail/nossr50/mcMMO.java @@ -14,6 +14,7 @@ import org.bukkit.plugin.PluginDescriptionFile; import org.bukkit.plugin.PluginManager; import org.bukkit.plugin.java.JavaPlugin; import org.bukkit.scheduler.BukkitScheduler; + import com.gmail.nossr50.commands.general.AddlevelsCommand; import com.gmail.nossr50.commands.general.AddxpCommand; import com.gmail.nossr50.commands.general.InspectCommand; @@ -388,9 +389,9 @@ public class mcMMO extends JavaPlugin { if (configInstance.getCommandMCTopEnabled()) { getCommand("mctop").setExecutor(new MctopCommand()); } - + if(configInstance.getCommandMCRankEnabled()) { - getCommand("mcrank").setExecutor(new McrankCommand()); + getCommand("mcrank").setExecutor(new McrankCommand()); } if (configInstance.getCommandMCStatsEnabled()) { diff --git a/src/main/java/com/gmail/nossr50/runnables/GreenThumbTimer.java b/src/main/java/com/gmail/nossr50/runnables/GreenThumbTimer.java index 66253dd75..d247df008 100644 --- a/src/main/java/com/gmail/nossr50/runnables/GreenThumbTimer.java +++ b/src/main/java/com/gmail/nossr50/runnables/GreenThumbTimer.java @@ -28,7 +28,7 @@ public class GreenThumbTimer implements Runnable { int skillLevel = this.profile.getSkillLevel(SkillType.HERBALISM); - final int STAGE_CHANGE = advancedConfig.getGreenThumbStageChange(); + final int STAGE_CHANGE = advancedConfig.getGreenThumbStageChange(); int greenThumbStage = (int) ((double) skillLevel / (double) STAGE_CHANGE); if (greenThumbStage > 4) greenThumbStage = 4; diff --git a/src/main/java/com/gmail/nossr50/runnables/MobStoreCleaner.java b/src/main/java/com/gmail/nossr50/runnables/MobStoreCleaner.java index e2ca9ae1b..7696864c2 100755 --- a/src/main/java/com/gmail/nossr50/runnables/MobStoreCleaner.java +++ b/src/main/java/com/gmail/nossr50/runnables/MobStoreCleaner.java @@ -1,7 +1,5 @@ package com.gmail.nossr50.runnables; -import java.lang.Runnable; - import org.bukkit.Bukkit; import org.bukkit.scheduler.BukkitScheduler; @@ -35,6 +33,7 @@ public class MobStoreCleaner implements Runnable taskID = -1; } + @Override public void run() { mcMMO.placeStore.cleanMobLists(); diff --git a/src/main/java/com/gmail/nossr50/runnables/UserPurgeTask.java b/src/main/java/com/gmail/nossr50/runnables/UserPurgeTask.java index 960a07e5c..c829f2a79 100644 --- a/src/main/java/com/gmail/nossr50/runnables/UserPurgeTask.java +++ b/src/main/java/com/gmail/nossr50/runnables/UserPurgeTask.java @@ -8,7 +8,7 @@ public class UserPurgeTask implements Runnable { private Database database = mcMMO.getPlayerDatabase(); public UserPurgeTask() { - + } @Override diff --git a/src/main/java/com/gmail/nossr50/runnables/blockstoreconversion/BlockStoreConversionMain.java b/src/main/java/com/gmail/nossr50/runnables/blockstoreconversion/BlockStoreConversionMain.java index 00ee437e0..d00b2ca4c 100755 --- a/src/main/java/com/gmail/nossr50/runnables/blockstoreconversion/BlockStoreConversionMain.java +++ b/src/main/java/com/gmail/nossr50/runnables/blockstoreconversion/BlockStoreConversionMain.java @@ -1,12 +1,11 @@ package com.gmail.nossr50.runnables.blockstoreconversion; import java.io.File; -import java.lang.Runnable; import org.bukkit.scheduler.BukkitScheduler; -import com.gmail.nossr50.config.HiddenConfig; import com.gmail.nossr50.mcMMO; +import com.gmail.nossr50.config.HiddenConfig; public class BlockStoreConversionMain implements Runnable { private int taskID, i; diff --git a/src/main/java/com/gmail/nossr50/runnables/blockstoreconversion/BlockStoreConversionXDirectory.java b/src/main/java/com/gmail/nossr50/runnables/blockstoreconversion/BlockStoreConversionXDirectory.java index edbea1ffd..d3e21603d 100755 --- a/src/main/java/com/gmail/nossr50/runnables/blockstoreconversion/BlockStoreConversionXDirectory.java +++ b/src/main/java/com/gmail/nossr50/runnables/blockstoreconversion/BlockStoreConversionXDirectory.java @@ -1,12 +1,11 @@ package com.gmail.nossr50.runnables.blockstoreconversion; import java.io.File; -import java.lang.Runnable; import org.bukkit.scheduler.BukkitScheduler; -import com.gmail.nossr50.config.HiddenConfig; import com.gmail.nossr50.mcMMO; +import com.gmail.nossr50.config.HiddenConfig; public class BlockStoreConversionXDirectory implements Runnable { private int taskID, i; diff --git a/src/main/java/com/gmail/nossr50/runnables/blockstoreconversion/BlockStoreConversionZDirectory.java b/src/main/java/com/gmail/nossr50/runnables/blockstoreconversion/BlockStoreConversionZDirectory.java index 42b021e15..706522621 100755 --- a/src/main/java/com/gmail/nossr50/runnables/blockstoreconversion/BlockStoreConversionZDirectory.java +++ b/src/main/java/com/gmail/nossr50/runnables/blockstoreconversion/BlockStoreConversionZDirectory.java @@ -1,18 +1,16 @@ package com.gmail.nossr50.runnables.blockstoreconversion; import java.io.File; -import java.lang.Runnable; -import java.lang.String; import org.bukkit.scheduler.BukkitScheduler; import com.gmail.nossr50.mcMMO; import com.gmail.nossr50.util.blockmeta.ChunkletStore; +import com.gmail.nossr50.util.blockmeta.HashChunkletManager; import com.gmail.nossr50.util.blockmeta.PrimitiveChunkletStore; import com.gmail.nossr50.util.blockmeta.PrimitiveExChunkletStore; -import com.gmail.nossr50.util.blockmeta.chunkmeta.PrimitiveChunkStore; -import com.gmail.nossr50.util.blockmeta.HashChunkletManager; import com.gmail.nossr50.util.blockmeta.chunkmeta.HashChunkManager; +import com.gmail.nossr50.util.blockmeta.chunkmeta.PrimitiveChunkStore; public class BlockStoreConversionZDirectory implements Runnable { public int taskID, cx, cz, x, y, z, y2, xPos, zPos, cxPos, czPos; diff --git a/src/main/java/com/gmail/nossr50/skills/gathering/Herbalism.java b/src/main/java/com/gmail/nossr50/skills/gathering/Herbalism.java index 98d045ee1..6b107ab83 100644 --- a/src/main/java/com/gmail/nossr50/skills/gathering/Herbalism.java +++ b/src/main/java/com/gmail/nossr50/skills/gathering/Herbalism.java @@ -107,7 +107,7 @@ public class Herbalism { randomChance = 75; } - float chance = (float) (((double) MAX_CHANCE / (double) MAX_BONUS_LEVEL) * herbLevel); + float chance = (float) ((MAX_CHANCE / MAX_BONUS_LEVEL) * herbLevel); if (chance > MAX_CHANCE) chance = (float) MAX_CHANCE; switch (type) { @@ -125,7 +125,7 @@ public class Herbalism { if (b.getType().equals(Material.CACTUS)) { mat = Material.CACTUS; if (!mcMMO.placeStore.isTrue(b)) { - if (chance > Misc.getRandom().nextInt(randomChance)) { + if (chance > Misc.getRandom().nextInt(randomChance)) { catciDrops++; } xp += Config.getInstance().getHerbalismXPCactus(); @@ -185,7 +185,7 @@ public class Herbalism { if (b.getType().equals(Material.SUGAR_CANE_BLOCK)) { mat = Material.SUGAR_CANE; if (!mcMMO.placeStore.isTrue(b)) { - if (chance > Misc.getRandom().nextInt(randomChance)) { + if (chance > Misc.getRandom().nextInt(randomChance)) { caneDrops++; } xp += Config.getInstance().getHerbalismXPSugarCane(); @@ -410,8 +410,8 @@ public class Herbalism { * @param plugin mcMMO plugin instance */ private static void greenThumbWheat(Block block, Player player, BlockBreakEvent event, mcMMO plugin) { - final int MAX_CHANCE = advancedConfig.getGreenThumbChanceMax(); - final int MAX_BONUS_LEVEL = advancedConfig.getGreenThumbMaxLevel(); + final int MAX_CHANCE = advancedConfig.getGreenThumbChanceMax(); + final int MAX_BONUS_LEVEL = advancedConfig.getGreenThumbMaxLevel(); PlayerProfile profile = Users.getProfile(player); int herbLevel = profile.getSkillLevel(SkillType.HERBALISM); @@ -455,7 +455,7 @@ public class Herbalism { } float chance = (float) (((double) MAX_CHANCE / (double) MAX_BONUS_LEVEL) * herbLevel); - if (chance > MAX_CHANCE) chance = (float) MAX_CHANCE; + if (chance > MAX_CHANCE) chance = MAX_CHANCE; if (hasSeeds && profile.getAbilityMode(AbilityType.GREEN_TERRA) || hasSeeds && (chance > Misc.getRandom().nextInt(randomChance))) { event.setCancelled(true); @@ -529,7 +529,7 @@ public class Herbalism { } float chance = (float) (((double) MAX_CHANCE / (double) MAX_BONUS_LEVEL) * skillLevel); - if (chance > MAX_CHANCE) chance = (float) MAX_CHANCE; + if (chance > MAX_CHANCE) chance = MAX_CHANCE; if (chance > Misc.getRandom().nextInt(randomChance)) { greenTerraConvert(player, block); diff --git a/src/main/java/com/gmail/nossr50/skills/gathering/WoodCutting.java b/src/main/java/com/gmail/nossr50/skills/gathering/WoodCutting.java index 3de5fc63b..b6078cf93 100644 --- a/src/main/java/com/gmail/nossr50/skills/gathering/WoodCutting.java +++ b/src/main/java/com/gmail/nossr50/skills/gathering/WoodCutting.java @@ -210,8 +210,8 @@ public class WoodCutting { else if (x.getType() == Material.LEAVES) { final int SAPLING_DROP_CHANCE = 10; - //Drop the right type of sapling - item = (new MaterialData(Material.SAPLING, (byte) (x.getData() & 3))).toItemStack(1); + //Drop the right type of sapling + item = (new MaterialData(Material.SAPLING, (byte) (x.getData() & 3))).toItemStack(1); Misc.randomDropItem(x.getLocation(), item, SAPLING_DROP_CHANCE); diff --git a/src/main/java/com/gmail/nossr50/skills/mining/BiggerBombsEventHandler.java b/src/main/java/com/gmail/nossr50/skills/mining/BiggerBombsEventHandler.java index bbc2ca1dd..ffce11f7b 100644 --- a/src/main/java/com/gmail/nossr50/skills/mining/BiggerBombsEventHandler.java +++ b/src/main/java/com/gmail/nossr50/skills/mining/BiggerBombsEventHandler.java @@ -7,7 +7,7 @@ public class BiggerBombsEventHandler { private ExplosionPrimeEvent event; private float radius; - private float radiusModifier; + private float radiusModifier; protected BiggerBombsEventHandler(MiningManager manager, ExplosionPrimeEvent event) { this.skillLevel = manager.getSkillLevel(); diff --git a/src/main/java/com/gmail/nossr50/skills/mining/Mining.java b/src/main/java/com/gmail/nossr50/skills/mining/Mining.java index 848ac1409..82dd8dfed 100644 --- a/src/main/java/com/gmail/nossr50/skills/mining/Mining.java +++ b/src/main/java/com/gmail/nossr50/skills/mining/Mining.java @@ -35,7 +35,7 @@ public class Mining { * @param player The player to award XP to * @param block The block to award XP for */ - protected static void miningXP(Player player, PlayerProfile profile, Block block, Material type) { + protected static void miningXP(Player player, PlayerProfile profile, Block block, Material type) { int xp = 0; switch (type) { diff --git a/src/main/java/com/gmail/nossr50/skills/mining/SuperBreakerEventHandler.java b/src/main/java/com/gmail/nossr50/skills/mining/SuperBreakerEventHandler.java index 88e878d51..4e98c9d32 100644 --- a/src/main/java/com/gmail/nossr50/skills/mining/SuperBreakerEventHandler.java +++ b/src/main/java/com/gmail/nossr50/skills/mining/SuperBreakerEventHandler.java @@ -74,7 +74,7 @@ public class SuperBreakerEventHandler { return true; } - + switch (blockType) { case OBSIDIAN: if (tier < Mining.DIAMOND_TOOL_TIER) { @@ -99,7 +99,7 @@ public class SuperBreakerEventHandler { } /* FALL THROUGH */ - case COAL_ORE: + case COAL_ORE: case ENDER_STONE: case GLOWSTONE: case MOSSY_COBBLESTONE: diff --git a/src/main/java/com/gmail/nossr50/skills/repair/Repair.java b/src/main/java/com/gmail/nossr50/skills/repair/Repair.java index 81805e13d..9b0d8ade4 100644 --- a/src/main/java/com/gmail/nossr50/skills/repair/Repair.java +++ b/src/main/java/com/gmail/nossr50/skills/repair/Repair.java @@ -205,8 +205,8 @@ public class Repair { */ protected static short repairCalculate(Player player, int skillLevel, short durability, int repairAmount) { float bonus; - if (skillLevel >= REPAIR_MASTERY_MAX_BONUS_LEVEL) bonus = ((float) REPAIR_MASTERY_CHANCE_MAX / 100F); - else bonus = (((float) skillLevel) / ((float) REPAIR_MASTERY_MAX_BONUS_LEVEL)) * (((float) REPAIR_MASTERY_CHANCE_MAX) / 100F); + if (skillLevel >= REPAIR_MASTERY_MAX_BONUS_LEVEL) bonus = (REPAIR_MASTERY_CHANCE_MAX / 100F); + else bonus = (((float) skillLevel) / ((float) REPAIR_MASTERY_MAX_BONUS_LEVEL)) * ((REPAIR_MASTERY_CHANCE_MAX) / 100F); if (Permissions.repairMastery(player)) { bonus = repairAmount * bonus; diff --git a/src/main/java/com/gmail/nossr50/skills/unarmed/Unarmed.java b/src/main/java/com/gmail/nossr50/skills/unarmed/Unarmed.java index f4775801f..8530bdc04 100644 --- a/src/main/java/com/gmail/nossr50/skills/unarmed/Unarmed.java +++ b/src/main/java/com/gmail/nossr50/skills/unarmed/Unarmed.java @@ -15,5 +15,5 @@ public class Unarmed { public static final int DISARM_MAX_BONUS_LEVEL = advancedConfig.getDeflectMaxBonusLevel(); public static final int IRON_GRIP_MAX_CHANCE = advancedConfig.getIronGripChanceMax(); - public static final int IRON_GRIP_MAX_BONUS_LEVEL = advancedConfig.getIronGripMaxBonusLevel(); + public static final int IRON_GRIP_MAX_BONUS_LEVEL = advancedConfig.getIronGripMaxBonusLevel(); } \ No newline at end of file diff --git a/src/main/java/com/gmail/nossr50/util/Anniversary.java b/src/main/java/com/gmail/nossr50/util/Anniversary.java index fa218372e..0bf019366 100644 --- a/src/main/java/com/gmail/nossr50/util/Anniversary.java +++ b/src/main/java/com/gmail/nossr50/util/Anniversary.java @@ -84,7 +84,7 @@ public class Anniversary { GregorianCalendar day = new GregorianCalendar(); if (hasCelebrated.contains(sender.getName())) { - return; + return; } if (getDateRange(day.getTime(), anniversaryStart.getTime(), anniversaryEnd.getTime())) { diff --git a/src/main/java/com/gmail/nossr50/util/Database.java b/src/main/java/com/gmail/nossr50/util/Database.java index bde70d8d9..717c72873 100644 --- a/src/main/java/com/gmail/nossr50/util/Database.java +++ b/src/main/java/com/gmail/nossr50/util/Database.java @@ -156,7 +156,7 @@ public class Database { /** * Check database structure for missing values. * - * @param update Type of data to check updates for + * @param update Type of data to check updates for */ public void checkDatabaseStructure(DatabaseUpdate update) { String sql = null; @@ -195,7 +195,7 @@ public class Database { + "ADD INDEX `idx_fishing` (`fishing`) USING BTREE;"); } break; - + default: break; } @@ -469,7 +469,7 @@ public class Database { return rows; } - + public Map readSQLRank(String playerName) { ResultSet resultSet; Map skills = new HashMap(); @@ -502,7 +502,7 @@ public class Database { statement.close(); } - + } catch (SQLException ex) { printErrors(ex); diff --git a/src/main/java/com/gmail/nossr50/util/ItemChecks.java b/src/main/java/com/gmail/nossr50/util/ItemChecks.java index 99670cef1..6478fc006 100644 --- a/src/main/java/com/gmail/nossr50/util/ItemChecks.java +++ b/src/main/java/com/gmail/nossr50/util/ItemChecks.java @@ -1,7 +1,7 @@ package com.gmail.nossr50.util; -import org.bukkit.inventory.ItemStack; import org.bukkit.Material; +import org.bukkit.inventory.ItemStack; import com.gmail.nossr50.mcMMO; import com.gmail.nossr50.api.SpoutToolsAPI; @@ -470,7 +470,7 @@ public class ItemChecks { public static boolean isEnchantable(ItemStack is) { Material type = is.getType(); return isArmor(is) || isSword(is) || isAxe(is) || isShovel(is) || isPickaxe(is) || - type == Material.SHEARS || type == Material.FISHING_ROD || type == Material.CARROT_STICK || - type == Material.FLINT_AND_STEEL || type == Material.BOW; + type == Material.SHEARS || type == Material.FISHING_ROD || type == Material.CARROT_STICK || + type == Material.FLINT_AND_STEEL || type == Material.BOW; } } diff --git a/src/main/java/com/gmail/nossr50/util/Leaderboard.java b/src/main/java/com/gmail/nossr50/util/Leaderboard.java index e200db2f8..04d7633f5 100644 --- a/src/main/java/com/gmail/nossr50/util/Leaderboard.java +++ b/src/main/java/com/gmail/nossr50/util/Leaderboard.java @@ -17,7 +17,7 @@ public class Leaderboard { private final static String location = mcMMO.getUsersFile(); private static HashMap> playerStatHash = new HashMap>(); private static long lastUpdate = 0; - + /** * Update the leader boards. */ @@ -25,9 +25,9 @@ public class Leaderboard { if(System.currentTimeMillis() < lastUpdate + 600000) { return; //Only update FFS leaderboards every 10 minutes.. this puts a lot of strain on the server (depending on the size of the database) and should not be done frequently } - + lastUpdate = System.currentTimeMillis(); //Log when the last update was run - + //Initialize lists List mining, woodcutting, herbalism, excavation, acrobatics, repair, swords, axes, archery, unarmed, taming, fishing, powerlevel; @@ -147,7 +147,7 @@ public class Leaderboard { Collections.sort(taming, c); Collections.sort(fishing, c); Collections.sort(powerlevel, c); - + playerStatHash.put(SkillType.MINING, mining); playerStatHash.put(SkillType.WOODCUTTING, woodcutting); playerStatHash.put(SkillType.REPAIR, repair); @@ -174,10 +174,10 @@ public class Leaderboard { String[] info = new String[10]; List statsList = playerStatHash.get(skillType); - + if(statsList != null) { int destination; - + //How many lines to skip through if (pagenumber == 1) { destination = 0; @@ -185,9 +185,9 @@ public class Leaderboard { else { destination = (pagenumber * 10) - 9; } - + int currentPos = 0; - + for(PlayerStat ps : statsList) { if(currentPos == 10) break; @@ -195,28 +195,28 @@ public class Leaderboard { destination--; continue; } - + info[currentPos] = ps.name+":"+ps.statVal; currentPos++; } - + } else { info[0] = "DummyPlayer:0"; //Coming up with a better solution soon... } - + return info; } - + public static int[] getPlayerRank(String playerName, SkillType skillType) { int currentPos = 1; List statsList = playerStatHash.get(skillType); - + if (statsList != null) { for (PlayerStat stat : statsList) { if (stat.name.equalsIgnoreCase(playerName)) { return new int[] {currentPos, stat.statVal}; } - + currentPos++; continue; } @@ -225,7 +225,7 @@ public class Leaderboard { return new int[] {0}; } - + private static class SkillComparator implements Comparator { @Override public int compare(PlayerStat o1, PlayerStat o2) { diff --git a/src/main/java/com/gmail/nossr50/util/Permissions.java b/src/main/java/com/gmail/nossr50/util/Permissions.java index 6185ce131..8ace4726e 100644 --- a/src/main/java/com/gmail/nossr50/util/Permissions.java +++ b/src/main/java/com/gmail/nossr50/util/Permissions.java @@ -13,7 +13,7 @@ public class Permissions { } public static boolean hasPermission(Player sender, String perm) - { + { if (sender.hasPermission(perm)) return true; diff --git a/src/main/java/com/gmail/nossr50/util/blockmeta/chunkmeta/HashChunkManager.java b/src/main/java/com/gmail/nossr50/util/blockmeta/chunkmeta/HashChunkManager.java index 1ce8d8c2a..1b20512fd 100755 --- a/src/main/java/com/gmail/nossr50/util/blockmeta/chunkmeta/HashChunkManager.java +++ b/src/main/java/com/gmail/nossr50/util/blockmeta/chunkmeta/HashChunkManager.java @@ -1,12 +1,10 @@ package com.gmail.nossr50.util.blockmeta.chunkmeta; import java.io.File; -import java.io.InputStream; import java.io.IOException; +import java.io.InputStream; import java.io.ObjectInputStream; import java.io.ObjectOutputStream; -import java.lang.Boolean; -import java.lang.Integer; import java.util.ArrayList; import java.util.HashMap; import java.util.Iterator; @@ -18,11 +16,10 @@ import org.bukkit.Chunk; import org.bukkit.World; import org.bukkit.block.Block; import org.bukkit.entity.Entity; +import org.getspout.spoutapi.chunkstore.mcMMOSimpleRegionFile; import com.gmail.nossr50.runnables.blockstoreconversion.BlockStoreConversionZDirectory; -import org.getspout.spoutapi.chunkstore.mcMMOSimpleRegionFile; - public class HashChunkManager implements ChunkManager { private HashMap> regionFiles = new HashMap>(); public HashMap store = new HashMap(); @@ -577,34 +574,41 @@ public class HashChunkManager implements ChunkManager { return true; } + @Override public boolean isSpawnedMob(Entity entity) { return spawnedMobs.contains(entity); } + @Override public boolean isSpawnedPet(Entity entity) { return spawnedMobs.contains(entity); } + @Override public void addSpawnedMob(Entity entity) { if (!isSpawnedMob(entity)) spawnedMobs.add(entity); } + @Override public void addSpawnedPet(Entity entity) { if (!isSpawnedMob(entity)) spawnedMobs.add(entity); } + @Override public void removeSpawnedMob(Entity entity) { if (isSpawnedMob(entity)) spawnedMobs.remove(entity); } + @Override public void removeSpawnedPet(Entity entity) { if (isSpawnedMob(entity)) spawnedMobs.remove(entity); } + @Override public synchronized void cleanMobLists() { if (!safeToRemoveMobs || iteratingMobs) return; diff --git a/src/main/java/com/gmail/nossr50/util/blockmeta/chunkmeta/NullChunkManager.java b/src/main/java/com/gmail/nossr50/util/blockmeta/chunkmeta/NullChunkManager.java index a7daec5e6..e3e3b776e 100755 --- a/src/main/java/com/gmail/nossr50/util/blockmeta/chunkmeta/NullChunkManager.java +++ b/src/main/java/com/gmail/nossr50/util/blockmeta/chunkmeta/NullChunkManager.java @@ -88,11 +88,18 @@ public class NullChunkManager implements ChunkManager { @Override public void cleanUp() {} + @Override public boolean isSpawnedMob(Entity entity) {return false;} + @Override public boolean isSpawnedPet(Entity entity) {return false;} + @Override public void addSpawnedMob(Entity entity) {} + @Override public void addSpawnedPet(Entity entity) {} + @Override public void removeSpawnedMob(Entity entity) {} + @Override public void removeSpawnedPet(Entity entity) {} + @Override public synchronized void cleanMobLists() {} } \ No newline at end of file diff --git a/src/main/java/com/gmail/nossr50/util/blockmeta/chunkmeta/PrimitiveChunkStore.java b/src/main/java/com/gmail/nossr50/util/blockmeta/chunkmeta/PrimitiveChunkStore.java index f09341796..fe1f7d173 100755 --- a/src/main/java/com/gmail/nossr50/util/blockmeta/chunkmeta/PrimitiveChunkStore.java +++ b/src/main/java/com/gmail/nossr50/util/blockmeta/chunkmeta/PrimitiveChunkStore.java @@ -24,9 +24,9 @@ public class PrimitiveChunkStore implements ChunkStore { private UUID worldUid; private List spawnedMobs = new ArrayList(); transient private int worldHeight; - + transient private int xBitShifts; - transient private int zBitShifts; + transient private int zBitShifts; transient private boolean conversionNeeded; public PrimitiveChunkStore(World world, int cx, int cz) { @@ -104,14 +104,17 @@ public class PrimitiveChunkStore implements ChunkStore { dirty = true; } + @Override public boolean isSpawnedMob(UUID id) { return spawnedMobs.contains(id); } + @Override public boolean isSpawnedPet(UUID id) { return spawnedMobs.contains(id); } + @Override public void addSpawnedMob(UUID id) { if (!isSpawnedMob(id)) { spawnedMobs.add(id); @@ -119,6 +122,7 @@ public class PrimitiveChunkStore implements ChunkStore { } } + @Override public void addSpawnedPet(UUID id) { if (!isSpawnedPet(id)) { spawnedMobs.add(id); @@ -126,6 +130,7 @@ public class PrimitiveChunkStore implements ChunkStore { } } + @Override public void removeSpawnedMob(UUID id) { if (isSpawnedMob(id)) { spawnedMobs.remove(id); @@ -133,6 +138,7 @@ public class PrimitiveChunkStore implements ChunkStore { } } + @Override public void removeSpawnedPet(UUID id) { if (isSpawnedPet(id)) { spawnedMobs.remove(id); @@ -140,6 +146,7 @@ public class PrimitiveChunkStore implements ChunkStore { } } + @Override public void clearSpawnedMobs() { if (!spawnedMobs.isEmpty()) { spawnedMobs.clear(); @@ -147,6 +154,7 @@ public class PrimitiveChunkStore implements ChunkStore { } } + @Override public void clearSpawnedPets() { if (!spawnedMobs.isEmpty()) { spawnedMobs.clear(); @@ -154,10 +162,12 @@ public class PrimitiveChunkStore implements ChunkStore { } } + @Override public List getSpawnedMobs() { return spawnedMobs; } + @Override public List getSpawnedPets() { return spawnedMobs; } diff --git a/src/test/java/com/gmail/nossr50/util/blockmeta/PrimitiveExChunkletStoreTest.java b/src/test/java/com/gmail/nossr50/util/blockmeta/PrimitiveExChunkletStoreTest.java index ea47ead79..512a7a253 100644 --- a/src/test/java/com/gmail/nossr50/util/blockmeta/PrimitiveExChunkletStoreTest.java +++ b/src/test/java/com/gmail/nossr50/util/blockmeta/PrimitiveExChunkletStoreTest.java @@ -6,7 +6,7 @@ import org.junit.Before; import org.junit.Test; public class PrimitiveExChunkletStoreTest { - byte addresses[][] = new byte[16][16]; + byte addresses[][] = new byte[16][16]; @Before public void populateAddresses() {