added tools

This commit is contained in:
Jottyfan
2024-11-23 19:31:37 +01:00
parent 7993693d9c
commit 6d2c1967fa
54 changed files with 1482 additions and 43 deletions

View File

@@ -0,0 +1,46 @@
package de.jottyfan.quickiemod.item;
import java.util.List;
import net.minecraft.block.Block;
import net.minecraft.block.BlockState;
import net.minecraft.item.ItemStack;
import net.minecraft.text.Text;
/**
*
* @author jotty
*
*/
public interface ToolRangeable {
/**
* dummy to have a getName method that comes with the item
*
* @return the name
*/
public Text getName();
/**
* @param stack the item stack that keeps the range
* @return range of blocks to be harvested
*/
public HarvestRange getRange(ItemStack stack);
/**
* check if this block state is one that affects the neighbor blocks to break
* also if they are from the same type
*
* @param blockState the block state of the current block
* @return true or false
*/
public boolean canBreakNeighbors(BlockState blockState);
/**
* get list of blocks that belong together (could be useful for stripped logs)
*
* @param block of the set
* @return the list of blocks or null if not found
*/
public List<Block> getBlockList(Block block);
}