Package com.nexomc.nexo.utils.drops
Class Drop
-
- All Implemented Interfaces:
public final class Drop
-
-
Field Summary
Fields Modifier and Type Field Description private final Boolean
isEmpty
private final Drop
explosionDrops
private final List<String>
hierarchy
private final List<Loot>
loots
private final Boolean
isSilktouch
private final Boolean
isFortune
private final String
sourceID
private final String
minimalType
private final String
bestTool
-
Method Summary
Modifier and Type Method Description final Boolean
isEmpty()
final Drop
getExplosionDrops()
final List<String>
getHierarchy()
final List<Loot>
getLoots()
final Boolean
isSilktouch()
final Boolean
isFortune()
final String
getSourceID()
final String
getMinimalType()
final String
getBestTool()
final String
getItemType(ItemStack itemInHand)
final Boolean
canDrop(ItemStack itemInHand)
final Boolean
isTypeEnough(ItemStack itemInHand)
final Boolean
isToolEnough(ItemStack itemInHand)
final Integer
getDiff(ItemStack item)
final List<DroppedLoot>
spawns(Location location, ItemStack itemInHand)
final Unit
furnitureSpawns(ItemDisplay baseEntity, ItemStack itemInHand)
final Integer
fortuneMultiplier(ItemStack itemInHand)
final List<DroppedLoot>
dropLoot(List<Loot> loots, Location location, Integer fortuneMultiplier)
final List<Loot>
lootToDrop(Player player)
Get the loots that will drop based on a given Player final static Drop
createDrop(List<String> toolTypes, ConfigurationSection dropSection, String sourceID)
final static Drop
emptyDrop()
final static Drop
emptyDrop(List<Loot> loots)
-
-
Method Detail
-
getExplosionDrops
final Drop getExplosionDrops()
-
getHierarchy
final List<String> getHierarchy()
-
isSilktouch
final Boolean isSilktouch()
-
getSourceID
final String getSourceID()
-
getMinimalType
final String getMinimalType()
-
getBestTool
final String getBestTool()
-
getItemType
final String getItemType(ItemStack itemInHand)
-
isTypeEnough
final Boolean isTypeEnough(ItemStack itemInHand)
-
isToolEnough
final Boolean isToolEnough(ItemStack itemInHand)
-
spawns
final List<DroppedLoot> spawns(Location location, ItemStack itemInHand)
-
furnitureSpawns
final Unit furnitureSpawns(ItemDisplay baseEntity, ItemStack itemInHand)
-
fortuneMultiplier
final Integer fortuneMultiplier(ItemStack itemInHand)
-
dropLoot
final List<DroppedLoot> dropLoot(List<Loot> loots, Location location, Integer fortuneMultiplier)
-
lootToDrop
final List<Loot> lootToDrop(Player player)
Get the loots that will drop based on a given Player
- Parameters:
player
- the player that triggered this drop- Returns:
the loots that will drop
-
createDrop
final static Drop createDrop(List<String> toolTypes, ConfigurationSection dropSection, String sourceID)
-
-
-
-