I tried to use this code:
@SubscribeEvent
public void onBlockHarvested(BlockEvent.BreakEvent event)
{ IWorld world=event.getWorld();
world.setBlockState(event.getPos(),new BlockState(new Stump(),new ImmutableMap<String,String>()));
}
But I cannot instantiate the ImmutableMap class and I do not know how it uses
Henlo!
I do not know how to place a block. This trouble seems really stupid.
I tried to place a block using IWorld.setBlockState(BlockPos pos,BlockState state), but using of this method have caused a misunderstandings with ImmutableMap<K,V> (it needs for instantiating BlockState class)
How to place a block?
1.12.2 is outdated version now.
Error messages says you that some packages does not exists. It may be caused by a lack of some mods. Try to repair files.
I have continued exploring code of this mod, but there is nothing sensible for me. I wanna understand, how way can I store in a block his origin? (e.g. make birch stump "know" that it should render as a birch?)
Ugh! Code of this mod (Horse Power) is ugly! No comments! But through reading this code I had understood that I should use the tile entity renderer. Thank you!
Thank you for your answers. But I asked another aspect. I asked how to render stumps for various types of trees.
I found answer on my question. Just explore HorsePower mod: https://github.com/GoryMoon/HorsePower . In this mod you have a chopping block made from any type of logs, e.g. modded.
Henlo!
I wounld like to create a mod that adds tree stumps in minecraft. When you felling a tree, there creates a stump block instead a dirt block under the tree. Stump should have textures of tree that was logged. I should create stumps for each tree type manually, or I have an ability to automate this process? (I wounld like to create stumps also for trees from other mods).
Thamk you!