Enhancement to vein mining animation
@@ -61,15 +61,16 @@ public class ModuleVeinMiningUnit extends ModuleMekaTool {
if (!found.contains(pos) && (maxRange == -1 || MekanismUtils.distanceBetween(location, pos) <= maxRange)) {
if (world.isBlockPresent(pos) && startBlock == world.getBlockState(pos).getBlock()) {
//Make sure to add it as immutable
- //not checking if we've already added found pos before adding
+ if (!openSet.contains(pos)) {
openSet.add(pos.toImmutable());
BoltEffect bolt = new BoltEffect(BoltRenderInfo.ELECTRICITY, new Vec3d(blockPos).add(0.5, 0.5, 0.5), new Vec3d(pos).add(0.5, 0.5, 0.5), 10)
- .size(0.04F).lifespan(20).spawn(SpawnFunction.NO_DELAY);
+ .size(0.015F).lifespan(12).spawn(SpawnFunction.NO_DELAY);
Mekanism.proxy.renderBolt(Objects.hash(blockPos, pos), bolt);
}
}
}
}
+ }
return found;
}
