Skip to content

Commit

Permalink
Update to use latest Forge api (#452)
Browse files Browse the repository at this point in the history
  • Loading branch information
RusTit authored and mezz committed Mar 21, 2018
1 parent 1c2994a commit 5185650
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion core/src/main/java/binnie/core/BinnieCore.java
Expand Up @@ -61,7 +61,7 @@
name = "Binnie Core",
version = "@VERSION@",
acceptedMinecraftVersions = Constants.ACCEPTED_MINECRAFT_VERSIONS,
dependencies = "required-after:forge@[14.23.1.2555,);" +
dependencies = "required-after:forge@[14.23.1.2594,);" +
"required-after:forestry@[5.7.0.214,);" +
"after:jei@[4.7.8,);"
)
Expand Down
Expand Up @@ -40,7 +40,7 @@ public static ItemStack getPlankProduct(ItemStack logStack, World world) {
public static ItemStack getRecipeWithPlanksOutput(ItemStack logStack, @Nullable World world) {
FAKE_CRAFT_INV.clear();
FAKE_CRAFT_INV.setInventorySlotContents(0, logStack);
for (IRecipe recipe : ForgeRegistries.RECIPES.getValues()) {
for (IRecipe recipe : ForgeRegistries.RECIPES.getValuesCollection()) {
try {
//noinspection ConstantConditions
if (recipe.matches(FAKE_CRAFT_INV, world)) {
Expand Down
Expand Up @@ -36,7 +36,7 @@ public void getItems(ItemStack inputStack, NonNullList<ItemStack> outputItems) {
* Get all recipes that has inputStack as its only ingredient, and return their outputs.
*/
private static void getCrafting(ItemStack inputStack, NonNullList<ItemStack> outputItems) {
for (IRecipe recipe : ForgeRegistries.RECIPES.getValues()) {
for (IRecipe recipe : ForgeRegistries.RECIPES.getValuesCollection()) {
ItemStack recipeOutput = recipe.getRecipeOutput();
if (!recipeOutput.isEmpty() && matches(recipe, inputStack)) {
outputItems.add(recipeOutput);
Expand Down
Expand Up @@ -55,7 +55,7 @@ public AnalystPageClimate(IWidget parent, IArea area, T ind, IClimatePlugin<T> p
new ControlText(this, new Area(4, y, getWidth() - 8, 14), I18N.localise(AnalystConstants.CLIMATE_KEY + ".biomes"), TextJustification.MIDDLE_CENTER).setColor(getColor());
y += 12;
List<Biome> biomes = new ArrayList<>();
for (Biome biome : ForgeRegistries.BIOMES.getValues()) { //TODO check
for (Biome biome : ForgeRegistries.BIOMES.getValuesCollection()) { //TODO check
if (biome != null &&
biome != Biomes.FROZEN_OCEAN &&
Tolerance.canTolerate(temp, EnumTemperature.getFromBiome(biome), tempTol) &&
Expand Down

0 comments on commit 5185650

Please sign in to comment.