Jump to content
Search In
  • More options...
Find results that contain...
Find results in...


  • Posts

  • Joined

  • Last visited


  • Gender
  • 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

Tree Puncher (2/8)



  1. 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.
  2. I tried also extending the SignTileEntity instead of extending TileEntity but not work.
  3. 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
  4. This is the Git repo https://github.com/michele-grifa/MoreStuffMod.git The branch is the 1.16.1
  5. 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?
  6. 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
  7. I tried checking for logical client, but by calling it directly, Minecraft stuck after i place the sign. I will try with DistExecutor.
  8. 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?
  9. 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))
  10. 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.
  11. 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.
  12. Hi, i created added a custom biome in minecraft 1.16.1 and works perfectly, but now updating to 1.16.3, all of the biome code is not working, like BiomeDictionary that is not present anymore. I know of the change made by Mojang in 1.16.3 for the data driven biomes, but how i can convert this biome to the new version?
  13. You have to add sprite in TextureStitchEvent.Pre Event
  • Create New...

Important Information

By using this site, you agree to our Privacy Policy.