From 785de7c0f44776359fe0fa6bca833fb07ae8c930 Mon Sep 17 00:00:00 2001 From: asofold Date: Sat, 14 Jun 2014 20:39:32 +0200 Subject: [PATCH] Suppress deprecation warnings for BlockProperties. Access by id may or may not be changed internally, depending on what happens on the API side. For performance reasons we might like to do without passing on extra stuff like Material, or even do String-comparison. If ids will become more expensive to use than other ways, or if it will be possible/accepted that ids get reused during runtime, then we will have to change all internals. --- .../neatmonster/nocheatplus/utilities/BlockProperties.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/NCPCore/src/main/java/fr/neatmonster/nocheatplus/utilities/BlockProperties.java b/NCPCore/src/main/java/fr/neatmonster/nocheatplus/utilities/BlockProperties.java index 1822b018..35a12493 100644 --- a/NCPCore/src/main/java/fr/neatmonster/nocheatplus/utilities/BlockProperties.java +++ b/NCPCore/src/main/java/fr/neatmonster/nocheatplus/utilities/BlockProperties.java @@ -36,6 +36,7 @@ import fr.neatmonster.nocheatplus.logging.LogUtil; * - reading (all) the default properties from a file too. * */ +@SuppressWarnings("deprecation") public class BlockProperties { /** @@ -447,8 +448,8 @@ public class BlockProperties { tools.put(359, new ToolProps(ToolType.SHEARS, MaterialBase.NONE)); } - - private static void initBlocks(final MCAccess mcAccess, final WorldConfigProvider worldConfigProvider) { + + private static void initBlocks(final MCAccess mcAccess, final WorldConfigProvider worldConfigProvider) { Arrays.fill(blocks, null); // Initalize block flags // Generic initialization.