All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.parzivail.util.block.mutating.DryingBlock Maven / Gradle / Ivy

There is a newer version: 0.0.114+1.20.2
Show newest version
package com.parzivail.util.block.mutating;

import com.parzivail.util.world.WorldUtil;
import net.minecraft.class_1297;
import net.minecraft.class_1937;
import net.minecraft.class_2248;
import net.minecraft.class_2338;
import net.minecraft.class_243;
import net.minecraft.class_2680;
import net.minecraft.class_3218;
import net.minecraft.class_5819;

public class DryingBlock extends FallingMutatingBlock
{
	public DryingBlock(class_2248 target, int meanTransitionTime, class_2251 settings, int dustColor)
	{
		super(target, meanTransitionTime, settings, dustColor);
	}

	@Override
	protected boolean canTransition(class_2680 state, class_3218 world, class_2338 pos, class_5819 random)
	{
		return WorldUtil.isSunLit(world, pos);
	}

	@Override
	public void method_9548(class_2680 state, class_1937 world, class_2338 pos, class_1297 entity)
	{
		entity.method_5844(state, new class_243(0.25, 1.5, 0.25));
		super.method_9548(state, world, pos, entity);
	}
}





© 2015 - 2025 Weber Informatics LLC | Privacy Policy