Another attempt at the MCPC+ bug

This commit is contained in:
pahimar 2013-12-31 02:07:23 -05:00
parent fa283b24eb
commit 5dc0d1a973

View file

@ -72,10 +72,8 @@ public class RecipeMapping implements JsonSerializer<RecipeMapping>, JsonDeseria
@Override
public RecipeMapping deserialize(JsonElement jsonElement, Type type, JsonDeserializationContext context) throws JsonParseException
{
if (!jsonElement.isJsonPrimitive())
{
JsonObject jsonRecipeMapping = (JsonObject) jsonElement;
WrappedStack outputStack = null;
@ -83,7 +81,7 @@ public class RecipeMapping implements JsonSerializer<RecipeMapping>, JsonDeseria
if (jsonRecipeMapping.get("outputWrappedStack") != null)
{
outputStack = new WrappedStack().deserialize(jsonRecipeMapping.get("outputWrappedStack").getAsJsonObject(), type, context);
outputStack = new WrappedStack().deserialize(jsonRecipeMapping.get("outputWrappedStack").getAsJsonObject(), WrappedStack.class, context);
}
if (jsonRecipeMapping.get("inputWrappedStacks") != null)
@ -92,7 +90,7 @@ public class RecipeMapping implements JsonSerializer<RecipeMapping>, JsonDeseria
for (int i = 0; i < jsonInputStacks.size(); i++)
{
WrappedStack inputStack = new WrappedStack().deserialize(jsonInputStacks.get(i).getAsJsonObject(), type, context);
WrappedStack inputStack = new WrappedStack().deserialize(jsonInputStacks.get(i).getAsJsonObject(), WrappedStack.class, context);
inputStacks.add(inputStack);
}
}