jhonny97
Members-
Posts
32 -
Joined
-
Last visited
Converted
-
Gender
Undisclosed
-
Personal Text
I am new!
Recent Profile Visitors
The recent visitors block is disabled and is not being shown to other users.
jhonny97's Achievements
Tree Puncher (2/8)
0
Reputation
-
Ok, thanks for the hint. I will look into it.
-
So instead when I reach a specified age, I should place another crop block on top but with another texture?
-
jhonny97 started following [1.19] Create 3 or 4 block tall crop
-
Hi, I'm testing a mod idea and I want to create a 3 or 4 block tall crop. I'm able to create the crop with the collision box of the size that I want, but I didn't find a way to use a taller texture at some stage of growth. Thanks
-
[1.15.2] Custom Sign Edit Screen Missing Texture
jhonny97 replied to killerjdog51's topic in Modder Support
I don't know where to place that code, the only place that possibly can go is the DistExecutor, but not work. I updated the repo to reflect this change. -
[1.15.2] Custom Sign Edit Screen Missing Texture
jhonny97 replied to killerjdog51's topic in Modder Support
I updated it -
[1.15.2] Custom Sign Edit Screen Missing Texture
jhonny97 replied to killerjdog51's topic in Modder Support
I tried also extending the SignTileEntity instead of extending TileEntity but not work. -
[1.15.2] Custom Sign Edit Screen Missing Texture
jhonny97 replied to killerjdog51's topic in Modder Support
I was doing some testing and i accidentally pushed the changes. I replaced TileEntityType.SIGN with my custom type, but the result is the same -
[1.15.2] Custom Sign Edit Screen Missing Texture
jhonny97 replied to killerjdog51's topic in Modder Support
This is the Git repo https://github.com/michele-grifa/MoreStuffMod.git The branch is the 1.16.1 -
[1.15.2] Custom Sign Edit Screen Missing Texture
jhonny97 replied to killerjdog51's topic in Modder Support
My tile entity extend the SignTileEntity class CustomSignTileEntity : SignTileEntity() { override fun getType(): TileEntityType<*> { return TileEntityInit.signTileEntity } } val signTileEntity: TileEntityType<CustomSignTileEntity> by tileEntities.register("my_sign") { TileEntityType.Builder.create({ CustomSignTileEntity() }, BlockInit.mySign, BlockInit.myWallSign).build(null) } If i extend SignTileEntity, the TE sync shouldn't happen by itself? -
[1.15.2] Custom Sign Edit Screen Missing Texture
jhonny97 replied to killerjdog51's topic in Modder Support
I used the DistExecutor and the code is now the following val flag = super.onBlockPlaced(pos, worldIn, player, stack, state) if (worldIn.isRemote && !flag && player != null) { DistExecutor.safeRunWhenOn(Dist.CLIENT) { DistExecutor.SafeRunnable { Minecraft.getInstance().displayGuiScreen(CustomEditSignScreen(worldIn.getTileEntity(pos) as CustomSignTileEntity)) } } } return flag Now my custom sign screen is opened and i can edit it, but when i exit and re-enter the world, the sign is blank. If i use !worldIn.isRemote instead of worldIn.isRemote the game crash even if i use the DistExecutor -
[1.15.2] Custom Sign Edit Screen Missing Texture
jhonny97 replied to killerjdog51's topic in Modder Support
I tried checking for logical client, but by calling it directly, Minecraft stuck after i place the sign. I will try with DistExecutor. -
[1.15.2] Custom Sign Edit Screen Missing Texture
jhonny97 replied to killerjdog51's topic in Modder Support
I had the same problem a while ago, i created the custom sign screen but i don't know how to open the custom screen instead of the vanilla one. In the ClientPlayerEntity class, the EditSignScreen is hardcoded this.mc.displayGuiScreen(new EditSignScreen(signTile)); So in a custom SignItem, i cannot use: player.openSignEditor(worldIn.getTileEntity(pos) as CustomSignTileEntity) I also tried using this code, but the game crash after placing the sign. class CustomSignItem(propertiesIn: Properties?, floorBlockIn: Block?, wallBlockIn: Block?) : WallOrFloorItem(floorBlockIn, wallBlockIn, propertiesIn) { override fun onBlockPlaced( pos: BlockPos, worldIn: World, player: PlayerEntity?, stack: ItemStack, state: BlockState ): Boolean { val flag = super.onBlockPlaced(pos, worldIn, player, stack, state) if (!worldIn.isRemote && !flag && player != null) { Minecraft.getInstance().displayGuiScreen(CustomEditSignScreen(worldIn.getTileEntity(pos) as CustomSignTileEntity)) } return flag } } How i can override them? -
Your hint about the chaining placement was helpful, using this two placement i'm able to achieve the previous behavior .withPlacement(Features.Placements.HEIGHTMAP_PLACEMENT) .withPlacement(Placement.field_242902_f.configure(AtSurfaceWithExtraConfig(5, 0.1f, 1))
-
Thanks for the explanation. After a bit of testing, i managed to register and spawn the biome without using json, but now the problem is another. In this biome i spawn a custom tree that worked until now. Instead of randomly place tree, like vanilla ones, they are placed in a grid (i attached a screenshot). Nothing has changed in my code since 1.16.1. This is the code that i use to add the tree to my biome withFeature( GenerationStage.Decoration.VEGETAL_DECORATION, Feature.TREE.withConfiguration(MyTree.treeConfig) .withPlacement(Placement.field_242902_f.configure(AtSurfaceWithExtraConfig(9, 0.1f, 1))) ) And this is the tree code: val treeConfig: BaseTreeFeatureConfig = BaseTreeFeatureConfig.Builder( SimpleBlockStateProvider(MyBlocks.log.defaultState), SimpleBlockStateProvider(MyBlocks.leaves.defaultState), BlobFoliagePlacer(FeatureSpread.func_242252_a(2), FeatureSpread.func_242252_a(0), 3), StraightTrunkPlacer(4, 2, 0), TwoLayerFeature(1, 0, 1)) .setIgnoreVines() .build() This happen with Forge 34.1.17, if i update to the latest Forge version they don't spawn at all.
-
In 1.16.1 i used to add the biome using this code: BiomeManager.addBiome(BiomeManager.BiomeType.WARM, BiomeManager.BiomeEntry(biome, 10)) but now BiomeEntry require RegistryKey instead of biome itself and in 1.16.3 don't spawn anymore.