package net.minecraft.world.entity.ai.behavior;

import net.minecraft.world.entity.LivingEntity;
import net.minecraft.core.Vec3i;
import net.minecraft.world.phys.Vec3;
import net.minecraft.core.BlockPos;

public class BlockPosTracker implements PositionTracker {
    private final BlockPos blockPos;
    private final Vec3 centerPosition;
    
    public BlockPosTracker(final BlockPos fu) {
        this.blockPos = fu;
        this.centerPosition = Vec3.atCenterOf(fu);
    }
    
    @Override
    public Vec3 currentPosition() {
        return this.centerPosition;
    }
    
    @Override
    public BlockPos currentBlockPosition() {
        return this.blockPos;
    }
    
    @Override
    public boolean isVisibleBy(final LivingEntity aoy) {
        return true;
    }
    
    @Override
    public String toString() {
        return "BlockPosTracker{blockPos=" + this.blockPos + ", centerPosition=" + this.centerPosition + '}';
    }
}
