From f8a9bf44c341061bb259aa189b775bb02d60ee3c Mon Sep 17 00:00:00 2001 From: mezz Date: Sun, 30 Nov 2014 18:31:42 -0800 Subject: [PATCH] Suppress unhandled exception warnings --- .../apiculture/VillageHandlerApiculture.java | 28 +++++++++---------- .../utils/ForestryModEnvWarningCallable.java | 2 +- .../forestry/pipes/PipeItemsPropolis.java | 2 +- 3 files changed, 16 insertions(+), 16 deletions(-) diff --git a/src/main/java/forestry/apiculture/VillageHandlerApiculture.java b/src/main/java/forestry/apiculture/VillageHandlerApiculture.java index c592a3229..55e0a0640 100755 --- a/src/main/java/forestry/apiculture/VillageHandlerApiculture.java +++ b/src/main/java/forestry/apiculture/VillageHandlerApiculture.java @@ -10,9 +10,17 @@ ******************************************************************************/ package forestry.apiculture; -import java.util.List; -import java.util.Random; - +import cpw.mods.fml.common.registry.VillagerRegistry.IVillageCreationHandler; +import cpw.mods.fml.common.registry.VillagerRegistry.IVillageTradeHandler; +import forestry.api.apiculture.EnumBeeType; +import forestry.apiculture.genetics.BeeTemplates; +import forestry.apiculture.items.ItemHoneycomb; +import forestry.apiculture.worldgen.ComponentVillageBeeHouse; +import forestry.core.config.Defaults; +import forestry.core.config.ForestryBlock; +import forestry.core.config.ForestryItem; +import forestry.core.proxy.Proxies; +import forestry.plugins.PluginApiculture; import net.minecraft.entity.passive.EntityVillager; import net.minecraft.init.Blocks; import net.minecraft.init.Items; @@ -23,17 +31,8 @@ import net.minecraft.village.MerchantRecipeList; import net.minecraft.world.gen.structure.MapGenStructureIO; import net.minecraft.world.gen.structure.StructureVillagePieces; -import cpw.mods.fml.common.registry.VillagerRegistry.IVillageCreationHandler; -import cpw.mods.fml.common.registry.VillagerRegistry.IVillageTradeHandler; - -import forestry.api.apiculture.EnumBeeType; -import forestry.apiculture.genetics.BeeTemplates; -import forestry.apiculture.items.ItemHoneycomb; -import forestry.apiculture.worldgen.ComponentVillageBeeHouse; -import forestry.core.config.Defaults; -import forestry.core.config.ForestryBlock; -import forestry.core.config.ForestryItem; -import forestry.plugins.PluginApiculture; +import java.util.List; +import java.util.Random; public class VillageHandlerApiculture implements IVillageCreationHandler, IVillageTradeHandler { @@ -41,6 +40,7 @@ public class VillageHandlerApiculture implements IVillageCreationHandler, IVilla try { MapGenStructureIO.func_143031_a(ComponentVillageBeeHouse.class, "Forestry:BeeHouse"); } catch (Throwable e) { + Proxies.log.severe("Failed to register village beehouse."); } } diff --git a/src/main/java/forestry/core/utils/ForestryModEnvWarningCallable.java b/src/main/java/forestry/core/utils/ForestryModEnvWarningCallable.java index 10aeaffaf..f6ad50df2 100755 --- a/src/main/java/forestry/core/utils/ForestryModEnvWarningCallable.java +++ b/src/main/java/forestry/core/utils/ForestryModEnvWarningCallable.java @@ -41,7 +41,7 @@ public class ForestryModEnvWarningCallable implements ICrashCallable { Class c = Class.forName("org.bukkit.Bukkit"); modIDs.add("Bukkit, Cauldron, or other Bukkit replacement"); } - catch (Throwable t) {} // No need to do anything. + catch (Throwable ignored) {} // No need to do anything. // Add other bad mods here. diff --git a/src/main/java/forestry/pipes/PipeItemsPropolis.java b/src/main/java/forestry/pipes/PipeItemsPropolis.java index b223e3b94..6f4f7a1b9 100755 --- a/src/main/java/forestry/pipes/PipeItemsPropolis.java +++ b/src/main/java/forestry/pipes/PipeItemsPropolis.java @@ -147,7 +147,7 @@ public class PipeItemsPropolis extends Pipe { // A bit of speed to perhaps prevent bees from popping out of the pipe. try { event.item.setSpeed(TransportConstants.PIPE_NORMAL_SPEED * 20F); - } catch (Throwable error) { + } catch (Throwable ignored) { } }