-
Notifications
You must be signed in to change notification settings - Fork 95
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
34 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
package mantle.blocks.iface; | ||
|
||
|
||
import java.util.Collections; | ||
import java.util.List; | ||
|
||
import net.minecraft.item.ItemStack; | ||
import net.minecraft.util.BlockPos; | ||
import net.minecraft.world.IBlockAccess; | ||
|
||
public interface ICrop | ||
{ | ||
public enum HarvestType | ||
{ | ||
BREAK, USE, MACHINE | ||
} | ||
|
||
public static final List<ItemStack> NO_YIELD = Collections.emptyList(); | ||
|
||
/** | ||
* | ||
* @param world | ||
* @param pos | ||
* @param type | ||
* @return A list of items harvested. If no items are returned, NO_YIELD should be passed. | ||
*/ | ||
public List<ItemStack> harvestCrop (IBlockAccess world, BlockPos pos, HarvestType type); | ||
|
||
public boolean isFullyGrown (IBlockAccess world, BlockPos pos); | ||
|
||
public boolean hasYield (IBlockAccess world, BlockPos pos); | ||
|
||
public void growthTick (IBlockAccess world, BlockPos pos); | ||
} |