Started by
scorpion981
on
Topic category: Help with Minecraft modding (Java Edition)
Hello, im trying to make a local itemstack value be a fire resistance potion but in mcreator you can only select one potion item (water bottle/any potions). I want to make this through code snippets so it is simpler to organize my procedure. I tried to set my local variable to this:
new ItemStack(Items.POTIONITEM), PotionTypes.STRONG_HEALING
but everytime (gradle):
Executing Gradle task: build
Build info: MCreator 2021.2.36710, forge-1.16.5, 64-bit, 3725 MB, Windows 10, JVM 11.0.11, JAVA_HOME: C:\Program Files\Pylo\MCreator\jdk
> Task :compileJava
C:\Users\enlai\MCreatorWorkspaces\minecraft_second_era\src\main\java\net\mcreator\minecraftsecondera\procedures\DrinkFireRestistancePotionProcedure.java:65: error: cannot find symbol new Potion.addPotionToItemStack(new ItemStack(Items.POTIONITEM), PotionTypes.STRONG_HEALING);
^
symbol: class addPotionToItemStack
location: class net.minecraft.potion.Potion
C:\Users\enlai\MCreatorWorkspaces\minecraft_second_era\src\main\java\net\mcreator\minecraftsecondera\procedures\DrinkFireRestistancePotionProcedure.java:65: error: cannot find symbol new Potion.addPotionToItemStack(new ItemStack(Items.POTIONITEM), PotionTypes.STRONG_HEALING);
^
symbol: variable POTIONITEM
location: class net.minecraft.item.Items
C:\Users\enlai\MCreatorWorkspaces\minecraft_second_era\src\main\java\net\mcreator\minecraftsecondera\procedures\DrinkFireRestistancePotionProcedure.java:65: error: cannot find symbol new Potion.addPotionToItemStack(new ItemStack(Items.POTIONITEM), PotionTypes.STRONG_HEALING);
^
symbol: variable PotionTypes
location: class net.mcreator.minecraftsecondera.procedures.DrinkFireRestistancePotionProcedure
3 errors
...
commands
potions are water bottles with NBTs
I know that but can I really use a command in a procedure to make a itemstack variable
Solved