Hello everybody!
I'm trying to create a new EnumFlowerType in the FlowerPot block.
The goal: to plant your own flower in a standard flower pot (version 1.8).
But I'm doing something wrong. My flower is not visible.
Attempts:
Main class:
public static EnumFlowerType SALTWORT = EnumHelper.addEnum(BlockFlowerPot.EnumFlowerType.class, SaltMod.MODID + ":" + "SALTWORT", new Class<?>[] { String.class }, new Object[] { "saltwort" }); //Create a new EnumFlowerType name
MyItem class (onItemUse method):
if (world.getTileEntity(pos) != null && world.getTileEntity(pos) instanceof TileEntityFlowerPot) {
TileEntityFlowerPot te = (TileEntityFlowerPot) world.getTileEntity(pos); //TileEntityFlowerPot
if (te.getFlowerPotItem() == null)
{
if (!world.isRemote)
{
IBlockState state = world.getBlockState(pos).withProperty(BlockFlowerPot.CONTENTS, ModBlocks.SALTWORT).withProperty(BlockFlowerPot.LEGACY_DATA, Integer.valueOf(0)); //Create BlockState with new properties
world.setBlockState(pos, state, 3);
te.setFlowerPotData(Item.getItemFromBlock(ModBlocks.saltWort), 0);
te.markDirty();
world.markBlockForUpdate(pos);
}
--stack.stackSize;
return true;
}
Thank you )
At the expense of salt extractor ... Well ...
Takes in hand a bucket of water (or milk) and pour it into a extractor )))
However, in version 1.7.10 have a bug the emptying of water buckets. While I do not know how to fix it.
0
Would you say that it is easier to create your own flower pot?
Do I need in this case to use a standard TileEntityFlowerPot?
0
Do renders only those types that are associated with Metadata?
It's like, in a pot can be planted a lot of things (saplings, flowers, mushrooms). They were more than 16.
Sorry, I'm not good at Enum Types.
But, how can I do better?
Create a new flower pot? But this is silly. In version 1.7.10, I just pointed the right flower in TileEntityFlowerPot.
And that means "very hackish ASM"?
0
Hello everybody!
I'm trying to create a new EnumFlowerType in the FlowerPot block.
The goal: to plant your own flower in a standard flower pot (version 1.8).
But I'm doing something wrong. My flower is not visible.
Attempts:
Main class:
MyItem class (onItemUse method):
Does anyone know how to make it work?
Thank you )
0
I'm afraid that I can't cope with the Chinese language )
So that, perhaps, I forget it.
Let's just say that I attach great importance to
0
Thank you )
At the expense of salt extractor ... Well ...
Takes in hand a bucket of water (or milk) and pour it into a extractor )))
However, in version 1.7.10 have a bug the emptying of water buckets. While I do not know how to fix it.
And what do you mean speaking about the account?
0
Hello IcyCrystal!
Could you throw a link to the new version of the mod on the MCBBS? I can't find it.
Thank you.
0
Fixed a annoying bug in version 1.8+
Fizzy drink now works correctly.
SaltyMod_1.7.e for MC 1.8+ release!
0
You're welcome!
Good night )
0
Update! )))
0
Thank you )
Honestly, I can not say anything about optifine.
I'm not optimized modification to work with it.
Perhaps I'll do it later.
0
In version 1.7.10, there are some things out of the Twilight Forest mod.
Look at them, please.
0
Yes! I will be very happy if you do this.
I too upset when I saw on the MCBBS the old version.
Thank you )
0
SaltyMod_1.7.a for MC 1.7.10 & 1.8 release!
0
SaltyMod_1.6.a for MC 1.7.10 & 1.8 release!
0
SaltyMod_1.5.a for MC 1.7.10 & 1.8 release!