public class BoneMealTask extends Task<VillagerEntity>
Task.Status
Modifier and Type | Field and Description |
---|---|
private int |
duration |
private long |
lastEndEntityAge |
private Optional<BlockPos> |
pos |
private long |
startTime |
requiredMemoryStates
Constructor and Description |
---|
BoneMealTask() |
Modifier and Type | Method and Description |
---|---|
private void |
addLookWalkTargets(VillagerEntity villager) |
private boolean |
canBoneMeal(BlockPos pos,
ServerWorld world) |
private Optional<BlockPos> |
findBoneMealPos(ServerWorld world,
VillagerEntity entity) |
protected void |
finishRunning(ServerWorld serverWorld,
VillagerEntity villagerEntity,
long long2) |
protected void |
keepRunning(ServerWorld serverWorld,
VillagerEntity villagerEntity,
long long2) |
protected void |
run(ServerWorld serverWorld,
VillagerEntity villagerEntity,
long long2) |
protected boolean |
shouldKeepRunning(ServerWorld serverWorld,
VillagerEntity villagerEntity,
long long2) |
protected boolean |
shouldRun(ServerWorld serverWorld,
VillagerEntity villagerEntity) |
getStatus, isTimeLimitExceeded, stop, tick, toString, tryStarting
private long startTime
private long lastEndEntityAge
private int duration
protected boolean shouldRun(ServerWorld serverWorld, VillagerEntity villagerEntity)
shouldRun
in class Task<VillagerEntity>
protected boolean shouldKeepRunning(ServerWorld serverWorld, VillagerEntity villagerEntity, long long2)
shouldKeepRunning
in class Task<VillagerEntity>
private Optional<BlockPos> findBoneMealPos(ServerWorld world, VillagerEntity entity)
private boolean canBoneMeal(BlockPos pos, ServerWorld world)
protected void run(ServerWorld serverWorld, VillagerEntity villagerEntity, long long2)
run
in class Task<VillagerEntity>
private void addLookWalkTargets(VillagerEntity villager)
protected void finishRunning(ServerWorld serverWorld, VillagerEntity villagerEntity, long long2)
finishRunning
in class Task<VillagerEntity>
protected void keepRunning(ServerWorld serverWorld, VillagerEntity villagerEntity, long long2)
keepRunning
in class Task<VillagerEntity>