🎁Loots
Loots can be used to specify when to drop a particular item. You can decide to create different loot types:
blocks
mobs
fishing
For example this is the loots category of a .yml file I created.
This example has two loots in blocks category.
First one is called ruby_ore (you can call them as you prefer), this will drop a itemsadder:ruby item when you break a custom block of type itemsadder:ruby_ore with a minimum amount of 1 and maximum amount of 2 with 100% chance.
The second one is a loot from a vanilla block. As you imagine it will drop a crystal or a knowledge_fragment when the player breaks a NETHER_QUARTZ_ORE. These drops are decided by ItemsAdder based on chance you set.
Special property: drop_only_first This allows you to stop the plugin from dropping each of the items that succeed into extracting a correct chance to be dropped. WARNING: this would make your items harder to be dropped.
Drop only in specific biomes
Ignore fortune enchant
You can make a loot ignore fortune enchant by adding the ignore_fortune property.
Other types of loots
As I said before there are other types of loots: mobs and fishing. These are some examples:
Fishing
Mobs
Custom mobs loots (old entities method)
In order to let ItemsAdder drop an item based on when you kill a custom mob (created with ItemsAdder) you have to use the ItemsAdderMob
metadata attribute. Example:
As you can see I set ItemsAdderMob
attribute and specified my custom mob namespace:id (in this example I used the creaturesplus:soul mob)
In order to let ItemsAdder drop an item based on when you kill a custom entity (created with ItemsAdder) you have to use the ItemsAdderEntity
metadata attribute. Example:
As you can see I set ItemsAdderEntity
attribute and specified my custom mob namespace:id (in this example I used the custom:ninja_skeleton mob)
As you can see I set profession attribute and specified the NBT attribute path, which in this case is VillagerData.profession. Then I set value to minecraft:farmer, this tells ItemsAdder to match only villagers with attribute VillagerData.profession set to minecraft:farmer.
The type attribute of nbt and metadata are really important, don't forget them or matches could not occur.
You have to enable this setting if you want to be able to get items from spawners by using an enchanted item with silktouch.
Last updated