The information from xndir worked for me. Alsp in my case, similar errors appear for fluid blocks in the new version, indicating that adjustments are also necessary. Without these changes, an error message stating “block id not set” will appear.
The following code example demonstrates how to correctly configure the fluid block:
public static final RegistryObject<LiquidBlock> EXAMPLE_FLUID_BLOCK =
BlocksRegister.BLOCKS.register(
"example_fluid_block",
() ->
new ExampleFluidBlock(
EXAMPLE_FLUID,
Block.Properties.ofFullCopy(Blocks.WATER)
.noCollission()
.strength(1000.0F)
.noOcclusion()
.setId(
ResourceKey.create(
ForgeRegistries.BLOCKS.getRegistryKey(),
ResourceLocation.parse(
String.format("%s:%s", ExampleMod.MOD_ID, "example_fluid_block")
)
)
)
)
);