Search in sources :

Example 36 with ZenMethod

use of stanhebben.zenscript.annotations.ZenMethod in project BetterWithAddons by DaedalusGame.

the class LureTree method add.

@ZenMethod
public static void add(@NotNull IItemStack input, int food) {
    ItemStack stack = InputHelper.toStack(input);
    TreeFood r = new TreeFood(stack, food);
    MineTweakerAPI.apply(new Add(r));
}
Also used : IItemStack(minetweaker.api.item.IItemStack) ItemStack(net.minecraft.item.ItemStack) TreeFood(betterwithaddons.tileentity.TileEntityLureTree.TreeFood) ZenMethod(stanhebben.zenscript.annotations.ZenMethod)

Example 37 with ZenMethod

use of stanhebben.zenscript.annotations.ZenMethod in project BetterWithAddons by DaedalusGame.

the class LureTree method remove.

@ZenMethod
public static void remove(@NotNull IItemStack input) {
    ItemStack stack = InputHelper.toStack(input);
    MineTweakerAPI.apply(new Remove(stack));
}
Also used : IItemStack(minetweaker.api.item.IItemStack) ItemStack(net.minecraft.item.ItemStack) ZenMethod(stanhebben.zenscript.annotations.ZenMethod)

Example 38 with ZenMethod

use of stanhebben.zenscript.annotations.ZenMethod in project BetterWithAddons by DaedalusGame.

the class SoftWoods method add.

@ZenMethod
public static void add(@NotNull IItemStack input, float hardness) {
    if (!InputHelper.isABlock(input)) {
        MineTweakerAPI.logError("Could not add soft wood " + input.toString() + "; not recognized as a block.");
        return;
    }
    ItemStack stack = InputHelper.toStack(input);
    WoodHardness r = new WoodHardness(Block.getBlockFromItem(stack.getItem()), stack.getMetadata(), hardness);
    MineTweakerAPI.apply(new Add(r));
}
Also used : WoodHardness(betterwithaddons.handler.StumpingHandler.WoodHardness) IItemStack(minetweaker.api.item.IItemStack) ItemStack(net.minecraft.item.ItemStack) ZenMethod(stanhebben.zenscript.annotations.ZenMethod)

Example 39 with ZenMethod

use of stanhebben.zenscript.annotations.ZenMethod in project BetterWithAddons by DaedalusGame.

the class FireNet method add.

@ZenMethod
public static void add(IItemStack[] outputs, @NotNull IIngredient input) {
    NetRecipe r = new NetRecipe(BlockNettedScreen.SifterType.FIRE, InputHelper.toObject(input), 0, InputHelper.toStacks(outputs));
    MineTweakerAPI.apply(new Add("FireNet", FireNetRecipeCategory.UID, CraftingManagerFireNet.getInstance(), r));
}
Also used : NetRecipe(betterwithaddons.crafting.recipes.NetRecipe) ZenMethod(stanhebben.zenscript.annotations.ZenMethod)

Example 40 with ZenMethod

use of stanhebben.zenscript.annotations.ZenMethod in project BetterWithAddons by DaedalusGame.

the class WaterNet method add.

@ZenMethod
public static void add(IItemStack[] outputs, @NotNull IIngredient input) {
    NetRecipe r = new NetRecipe(BlockNettedScreen.SifterType.WATER, InputHelper.toObject(input), 0, InputHelper.toStacks(outputs));
    MineTweakerAPI.apply(new Add("WaterNet", WaterNetRecipeCategory.UID, CraftingManagerWaterNet.getInstance(), r));
}
Also used : NetRecipe(betterwithaddons.crafting.recipes.NetRecipe) ZenMethod(stanhebben.zenscript.annotations.ZenMethod)

Aggregations

ZenMethod (stanhebben.zenscript.annotations.ZenMethod)67 ItemStack (net.minecraft.item.ItemStack)23 IItemStack (crafttweaker.api.item.IItemStack)14 FluidStack (net.minecraftforge.fluids.FluidStack)7 PharmacologyEffect (minechem.potion.PharmacologyEffect)6 IItemStack (minetweaker.api.item.IItemStack)6 PotionChemical (minechem.potion.PotionChemical)4 NetRecipe (betterwithaddons.crafting.recipes.NetRecipe)3 CherryBoxRecipe (betterwithaddons.crafting.recipes.CherryBoxRecipe)2 GristSet (com.mraof.minestuck.util.GristSet)2 IAction (crafttweaker.IAction)2 ChemicalRoomStateEnum (minechem.item.ChemicalRoomStateEnum)2 PackingRecipe (betterwithaddons.crafting.recipes.PackingRecipe)1 SmeltingRecipe (betterwithaddons.crafting.recipes.SmeltingRecipe)1 SpindleRecipe (betterwithaddons.crafting.recipes.SpindleRecipe)1 WoodHardness (betterwithaddons.handler.StumpingHandler.WoodHardness)1 ItemMaterial (betterwithaddons.item.ItemMaterial)1 TreeFood (betterwithaddons.tileentity.TileEntityLureTree.TreeFood)1 IngredientCraftTweaker (betterwithaddons.util.IngredientCraftTweaker)1 BrewedGrainRecipe (binnie.extratrees.machines.brewery.recipes.BrewedGrainRecipe)1