From f003accc02b87f2acf349cb11c8ff210f2dd3632 Mon Sep 17 00:00:00 2001 From: Cheeserolls Date: Thu, 28 May 2015 13:54:27 +0100 Subject: [PATCH] Fix crash caused by use of de-obfuscated field name --- src/main/java/biomesoplenty/common/init/ModPotions.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/main/java/biomesoplenty/common/init/ModPotions.java b/src/main/java/biomesoplenty/common/init/ModPotions.java index 73ac2692f..640bf30f6 100644 --- a/src/main/java/biomesoplenty/common/init/ModPotions.java +++ b/src/main/java/biomesoplenty/common/init/ModPotions.java @@ -46,7 +46,8 @@ public class ModPotions System.arraycopy(Potion.potionTypes, 0, potionTypes, 0, oldNumOfPotions); // replace Potion.potionTypes with our new expanded array - BOPReflectionHelper.setPrivateFinalValue(Potion.class, null, potionTypes, "potionTypes" /* TODO: what's this? "field_76425_a" */); + // note - need to specify both the obfuscated and de-obfuscated field names so that it works in dev and in the normal game + BOPReflectionHelper.setPrivateFinalValue(Potion.class, null, potionTypes, "potionTypes", "field_76425_a"); } private static int getNextId()