/
Belyash5
/
Flu
Обзор
Документация
Войти
/
Belyash5
/
Flu
Код
Запросы
0
Задачи
Вики
Пакеты
0
Релизы
0
Аналитика
Безопасность
master
src/main/java/api/hbm/block/IDrillInteraction.java
42 строки
1 KB
Boblet
more API stuff, ore cluster functionality with auto miners
25 авг 2021, 10:36
25 авг 2021, 10:36
35e6d6b
Код
Авторство
О чём код?
package api.hbm.block; import net.minecraft.item.ItemStack; import net.minecraft.world.World; public interface IDrillInteraction { /** * Whether the breaking of the block should be successful. Will destroy the block and not drop anything from clusters. * Should use a random function, otherwise the clusters will stay there indefinitely printing free ore. * @param world * @param x * @param y * @param z * @param drill Might be a tool, tile entity or anything that breaks blocks * @return */ public boolean canBreak(World world, int x, int y, int z, int meta, IMiningDrill drill); /** * Returns an itemstack, usually when the block is not destroyed. Laser drills may drop this and mechanical drills will add it to their inventories. * @param world * @param x * @param y * @param z * @param drill Might be a tool, tile entity or anything that breaks blocks * @return */ public ItemStack extractResource(World world, int x, int y, int z, int meta, IMiningDrill drill); /** * The hardness that should be considered instead of the hardness value of the block itself * @param world * @param x * @param y * @param z * @param meta * @param drill * @return */ public float getRelativeHardness(World world, int x, int y, int z, int meta, IMiningDrill drill); }