I have a custom fluid, it have to flow slower than water, like lava but not to that level. I've read the docs on FluidAttributes.java and it say:
/**
* Viscosity ("thickness") of the fluid - completely arbitrary; negative values are not
* permissible.
*
* Default value is approximately the real-life density of water in m/s^2 (x10^-3).
*
* Higher viscosity means that a fluid flows more slowly, like molasses.
* Lower viscosity means that a fluid flows more quickly, like helium.
*
*/
I'm at 100000 now and still no difference with water. Here the initElements().
Also overlay not set correctly, maybe misplaced texture?
...
public void initElements() {
fluidproperties = new ForgeFlowingFluid.Properties(
() -> still,
() -> flowing,
FluidAttributes.builder(
new ResourceLocation("modid", "/fluids/still"),
new ResourceLocation("modid", "/fluids/flow")
)
.luminosity(0)
.density(1800)
.viscosity(100000)
.overlay(new ResourceLocation("modid", "/fluids/overlay"))
//.overlay(new ResourceLocation("modid", "/fluids/overlay.png"))
)
.bucket(() -> bucket)
.block(() -> block);
still = (FlowingFluid) new FluidSource(fluidproperties).setRegistryName("my_fluid");
flowing = (FlowingFluid) new ForgeFlowingFluid.Flowing(fluidproperties).setRegistryName("my_fluid_flowing");
elements.blocks.add(() -> new FlowingFluidBlock(still, Block.Properties.create(Material.WATER)) {
}.setRegistryName("my_fluid"));
elements.items.add(() -> new BucketItem(still, new Item.Properties().containerItem(Items.BUCKET).maxStackSize(1).group(ItemGroup.MISC))
.setRegistryName("my_fluid_bucket"));
}
...