Fix a bunch of small formatting issues

This commit is contained in:
TfT_02 2014-05-11 15:14:46 +02:00
parent 99248caba3
commit 8fec1af257
23 changed files with 29 additions and 29 deletions

View File

@ -157,7 +157,7 @@ public class ExperienceConfig extends AutoUpdateConfigLoader {
/* Curve values */
public double getMultiplier(FormulaType type) { return config.getDouble("Experience_Formula." + StringUtils.getCapitalized(type.toString()) + "_Values.multiplier"); }
public int getBase(FormulaType type) { return config.getInt("Experience_Formula." + StringUtils.getCapitalized(type.toString()) + "_Values.base"); }
public double getExponent(FormulaType type) { return config.getDouble("Experience_Formula." + StringUtils.getCapitalized(type.toString()) +"_Values.exponent"); }
public double getExponent(FormulaType type) { return config.getDouble("Experience_Formula." + StringUtils.getCapitalized(type.toString()) + "_Values.exponent"); }
/* Global modifier */
public double getExperienceGainsGlobalMultiplier() { return config.getDouble("Experience_Formula.Multiplier.Global", 1.0); }

View File

@ -185,7 +185,7 @@ public class Party {
public String getXpToLevelPercentage() {
DecimalFormat percent = new DecimalFormat("##0.00%");
return percent.format( this.getXp() / getXpToLevel());
return percent.format(this.getXp() / getXpToLevel());
}
/**

View File

@ -13,7 +13,6 @@ import org.bukkit.inventory.ItemStack;
import org.bukkit.metadata.FixedMetadataValue;
import org.bukkit.scheduler.BukkitRunnable;
import com.gmail.nossr50.datatypes.skills.XPGainReason;
import com.gmail.nossr50.mcMMO;
import com.gmail.nossr50.config.AdvancedConfig;
import com.gmail.nossr50.config.Config;
@ -25,6 +24,7 @@ import com.gmail.nossr50.datatypes.party.PartyTeleportRecord;
import com.gmail.nossr50.datatypes.skills.AbilityType;
import com.gmail.nossr50.datatypes.skills.SkillType;
import com.gmail.nossr50.datatypes.skills.ToolType;
import com.gmail.nossr50.datatypes.skills.XPGainReason;
import com.gmail.nossr50.locale.LocaleLoader;
import com.gmail.nossr50.party.PartyManager;
import com.gmail.nossr50.party.ShareHandler;

View File

@ -5,8 +5,8 @@ import org.bukkit.event.Cancellable;
import org.bukkit.event.HandlerList;
import org.bukkit.event.player.PlayerEvent;
import com.gmail.nossr50.datatypes.skills.XPGainReason;
import com.gmail.nossr50.datatypes.skills.SkillType;
import com.gmail.nossr50.datatypes.skills.XPGainReason;
import com.gmail.nossr50.util.player.UserManager;
/**

View File

@ -2,8 +2,8 @@ package com.gmail.nossr50.events.experience;
import org.bukkit.entity.Player;
import com.gmail.nossr50.datatypes.skills.XPGainReason;
import com.gmail.nossr50.datatypes.skills.SkillType;
import com.gmail.nossr50.datatypes.skills.XPGainReason;
/**
* Called when a user levels change

View File

@ -2,8 +2,8 @@ package com.gmail.nossr50.events.experience;
import org.bukkit.entity.Player;
import com.gmail.nossr50.datatypes.skills.XPGainReason;
import com.gmail.nossr50.datatypes.skills.SkillType;
import com.gmail.nossr50.datatypes.skills.XPGainReason;
/**
* Called when a user loses levels in a skill

View File

@ -2,8 +2,8 @@ package com.gmail.nossr50.events.experience;
import org.bukkit.entity.Player;
import com.gmail.nossr50.datatypes.skills.XPGainReason;
import com.gmail.nossr50.datatypes.skills.SkillType;
import com.gmail.nossr50.datatypes.skills.XPGainReason;
/**
* Called when a user levels up in a skill

View File

@ -2,8 +2,8 @@ package com.gmail.nossr50.events.experience;
import org.bukkit.entity.Player;
import com.gmail.nossr50.datatypes.skills.XPGainReason;
import com.gmail.nossr50.datatypes.skills.SkillType;
import com.gmail.nossr50.datatypes.skills.XPGainReason;
/**
* Called when a player gains XP in a skill

View File

@ -9,6 +9,6 @@ import org.bukkit.event.entity.EntityTameEvent;
*/
public class FakeEntityTameEvent extends EntityTameEvent {
public FakeEntityTameEvent(LivingEntity entity, AnimalTamer owner) {
super (entity, owner);
super(entity, owner);
}
}

View File

@ -34,7 +34,7 @@ public class McrankCommandDisplayTask extends BukkitRunnable {
displayBoard();
}
if (useChat){
if (useChat) {
displayChat();
}
}

View File

@ -19,7 +19,7 @@ public class BleedTimerTask extends BukkitRunnable {
@Override
public void run() {
for (Iterator<Entry<LivingEntity, Integer>> bleedIterator = bleedList.entrySet().iterator(); bleedIterator.hasNext();) {
for (Iterator<Entry<LivingEntity, Integer>> bleedIterator = bleedList.entrySet().iterator(); bleedIterator.hasNext(); ) {
Entry<LivingEntity, Integer> entry = bleedIterator.next();
LivingEntity entity = entry.getKey();

View File

@ -34,7 +34,6 @@ import org.bukkit.potion.Potion;
import org.bukkit.potion.PotionType;
import org.bukkit.util.Vector;
import com.gmail.nossr50.datatypes.skills.XPGainReason;
import com.gmail.nossr50.mcMMO;
import com.gmail.nossr50.config.AdvancedConfig;
import com.gmail.nossr50.config.Config;
@ -43,6 +42,7 @@ import com.gmail.nossr50.config.treasure.TreasureConfig;
import com.gmail.nossr50.datatypes.player.McMMOPlayer;
import com.gmail.nossr50.datatypes.skills.SecondaryAbility;
import com.gmail.nossr50.datatypes.skills.SkillType;
import com.gmail.nossr50.datatypes.skills.XPGainReason;
import com.gmail.nossr50.datatypes.treasure.EnchantmentTreasure;
import com.gmail.nossr50.datatypes.treasure.FishingTreasure;
import com.gmail.nossr50.datatypes.treasure.Rarity;
@ -70,6 +70,7 @@ public class FishingManager extends SkillManager {
private Location fishingTarget;
private Item fishingCatch;
private Location hookLocation;
public FishingManager(McMMOPlayer mcMMOPlayer) {
super(mcMMOPlayer, SkillType.FISHING);
}

View File

@ -16,7 +16,6 @@ import org.bukkit.material.Crops;
import org.bukkit.material.NetherWarts;
import org.bukkit.metadata.FixedMetadataValue;
import com.gmail.nossr50.datatypes.skills.XPGainReason;
import com.gmail.nossr50.mcMMO;
import com.gmail.nossr50.config.Config;
import com.gmail.nossr50.config.experience.ExperienceConfig;
@ -27,6 +26,7 @@ import com.gmail.nossr50.datatypes.skills.AbilityType;
import com.gmail.nossr50.datatypes.skills.SecondaryAbility;
import com.gmail.nossr50.datatypes.skills.SkillType;
import com.gmail.nossr50.datatypes.skills.ToolType;
import com.gmail.nossr50.datatypes.skills.XPGainReason;
import com.gmail.nossr50.datatypes.treasure.HylianTreasure;
import com.gmail.nossr50.locale.LocaleLoader;
import com.gmail.nossr50.runnables.skills.HerbalismBlockUpdaterTask;
@ -115,8 +115,6 @@ public class HerbalismManager extends SkillManager {
}
/**
*
*
* @param blockState The {@link BlockState} to check ability activation for
*/
public void herbalismBlockCheck(BlockState blockState) {

View File

@ -12,13 +12,13 @@ import org.bukkit.inventory.ItemStack;
import org.bukkit.inventory.PlayerInventory;
import org.bukkit.material.MaterialData;
import com.gmail.nossr50.datatypes.skills.XPGainReason;
import com.gmail.nossr50.mcMMO;
import com.gmail.nossr50.config.Config;
import com.gmail.nossr50.config.experience.ExperienceConfig;
import com.gmail.nossr50.datatypes.player.McMMOPlayer;
import com.gmail.nossr50.datatypes.skills.SecondaryAbility;
import com.gmail.nossr50.datatypes.skills.SkillType;
import com.gmail.nossr50.datatypes.skills.XPGainReason;
import com.gmail.nossr50.locale.LocaleLoader;
import com.gmail.nossr50.skills.SkillManager;
import com.gmail.nossr50.skills.repair.ArcaneForging.Tier;

View File

@ -6,11 +6,11 @@ import org.bukkit.entity.Player;
import org.bukkit.event.inventory.FurnaceBurnEvent;
import org.bukkit.inventory.ItemStack;
import com.gmail.nossr50.datatypes.skills.XPGainReason;
import com.gmail.nossr50.mcMMO;
import com.gmail.nossr50.datatypes.player.McMMOPlayer;
import com.gmail.nossr50.datatypes.skills.SecondaryAbility;
import com.gmail.nossr50.datatypes.skills.SkillType;
import com.gmail.nossr50.datatypes.skills.XPGainReason;
import com.gmail.nossr50.events.skills.secondaryabilities.SecondaryAbilityWeightedActivationCheckEvent;
import com.gmail.nossr50.locale.LocaleLoader;
import com.gmail.nossr50.skills.SkillManager;

View File

@ -26,7 +26,7 @@ public class Unarmed {
if (inventory.containsAtLeast(dropStack, 1)) {
int nextSlot = 0;
for (ItemStack itemstack: inventory) {
for (ItemStack itemstack : inventory) {
if (dropStack.isSimilar(itemstack)) {
int itemAmount = itemstack.getAmount();
int itemMax = itemstack.getMaxStackSize();
@ -57,7 +57,7 @@ public class Unarmed {
if (firstEmpty == inventory.getHeldItemSlot()) {
int nextSlot = firstEmpty + 1;
for (Iterator<ItemStack> iterator = inventory.iterator(nextSlot); iterator.hasNext();) {
for (Iterator<ItemStack> iterator = inventory.iterator(nextSlot); iterator.hasNext(); ) {
ItemStack itemstack = iterator.next();
if (itemstack == null) {

View File

@ -11,13 +11,13 @@ import org.bukkit.entity.Player;
import org.bukkit.inventory.ItemStack;
import org.bukkit.material.Tree;
import com.gmail.nossr50.datatypes.skills.XPGainReason;
import com.gmail.nossr50.mcMMO;
import com.gmail.nossr50.datatypes.mods.CustomBlock;
import com.gmail.nossr50.datatypes.player.McMMOPlayer;
import com.gmail.nossr50.datatypes.skills.AbilityType;
import com.gmail.nossr50.datatypes.skills.SecondaryAbility;
import com.gmail.nossr50.datatypes.skills.SkillType;
import com.gmail.nossr50.datatypes.skills.XPGainReason;
import com.gmail.nossr50.locale.LocaleLoader;
import com.gmail.nossr50.skills.SkillManager;
import com.gmail.nossr50.skills.woodcutting.Woodcutting.ExperienceGainMethod;

View File

@ -66,7 +66,7 @@ public final class ChimaeraWing {
long lastTeleport = mcMMOPlayer.getChimeraWingLastUse();
int cooldown = Config.getInstance().getChimaeraCooldown();
if (cooldown > 0 ) {
if (cooldown > 0) {
int timeRemaining = SkillUtils.calculateTimeLeft(lastTeleport * Misc.TIME_CONVERSION_FACTOR, cooldown, player);
if (timeRemaining > 0) {

View File

@ -342,7 +342,8 @@ public final class HolidayManager {
return mcMMO.getHolidayManager().getDateRange(day.getTime(), start.getTime(), end.getTime());
}
public void handleStatisticEvent(PlayerStatisticIncrementEvent event) {Player player = event.getPlayer();
public void handleStatisticEvent(PlayerStatisticIncrementEvent event) {
Player player = event.getPlayer();
Statistic statistic = event.getStatistic();
int newValue = event.getNewValue();

View File

@ -29,7 +29,7 @@ public class HashChunkManager implements ChunkManager {
public synchronized void closeAll() {
for (UUID uid : regionFiles.keySet()) {
HashMap<Long, McMMOSimpleRegionFile> worldRegions = regionFiles.get(uid);
for (Iterator<McMMOSimpleRegionFile> worldRegionIterator = worldRegions.values().iterator(); worldRegionIterator.hasNext();) {
for (Iterator<McMMOSimpleRegionFile> worldRegionIterator = worldRegions.values().iterator(); worldRegionIterator.hasNext(); ) {
McMMOSimpleRegionFile rf = worldRegionIterator.next();
if (rf != null) {
rf.close();

View File

@ -90,7 +90,7 @@ public class FormulaManager {
experience -= experienceToNextLevel;
}
return new int[]{newLevel, remainder};
return new int[]{ newLevel, remainder };
}
/**