diff options
| author | Unknown <shekwancheung0528@gmail.com> | 2018-12-31 13:12:25 +0800 |
|---|---|---|
| committer | Unknown <shekwancheung0528@gmail.com> | 2018-12-31 13:12:25 +0800 |
| commit | fee12aa0885da204ec874cd5ada371c42501c873 (patch) | |
| tree | 880596f5f463e08762a56b1cb1d7008aaed1899d /src/main/java/me/shedaniel/mixins/MixinBrewingRecipeRegistry.java | |
| parent | 1b14c5142bb49db9af078b5c753bc22ce35a40cc (diff) | |
| download | RoughlyEnoughItems-fee12aa0885da204ec874cd5ada371c42501c873.tar.gz RoughlyEnoughItems-fee12aa0885da204ec874cd5ada371c42501c873.tar.bz2 RoughlyEnoughItems-fee12aa0885da204ec874cd5ada371c42501c873.zip | |
packetadder wip
Diffstat (limited to 'src/main/java/me/shedaniel/mixins/MixinBrewingRecipeRegistry.java')
| -rw-r--r-- | src/main/java/me/shedaniel/mixins/MixinBrewingRecipeRegistry.java | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/src/main/java/me/shedaniel/mixins/MixinBrewingRecipeRegistry.java b/src/main/java/me/shedaniel/mixins/MixinBrewingRecipeRegistry.java new file mode 100644 index 000000000..606634ebb --- /dev/null +++ b/src/main/java/me/shedaniel/mixins/MixinBrewingRecipeRegistry.java @@ -0,0 +1,22 @@ +package me.shedaniel.mixins; + +import me.shedaniel.Core; +import me.shedaniel.listenerdefinitions.PotionCraftingAdder; +import net.minecraft.item.Item; +import net.minecraft.potion.Potion; +import net.minecraft.recipe.BrewingRecipeRegistry; +import org.spongepowered.asm.mixin.Mixin; +import org.spongepowered.asm.mixin.injection.At; +import org.spongepowered.asm.mixin.injection.Inject; +import org.spongepowered.asm.mixin.injection.callback.CallbackInfo; + +@Mixin(BrewingRecipeRegistry.class) +public class MixinBrewingRecipeRegistry { + + @Inject(method = "registerPotionRecipe", at = @At("RETURN")) + private static void registerPotionRecipe(Potion potion_1, Item item_1, Potion potion_2, CallbackInfo info) { + System.out.println("a"); + Core.getListeners(PotionCraftingAdder.class).forEach(potionCraftingAdder -> potionCraftingAdder.addPotionRecipe(potion_1, item_1, potion_2)); + } + +} |
