forked from Upstream/VillagerTradeLimiter
Version 1.5.4:
* Fixed IgnoreHeldItems typo
This commit is contained in:
parent
72e2423741
commit
a3995b6adb
2
pom.xml
2
pom.xml
@ -3,7 +3,7 @@
|
|||||||
<modelVersion>4.0.0</modelVersion>
|
<modelVersion>4.0.0</modelVersion>
|
||||||
<groupId>com.pretzel.dev</groupId>
|
<groupId>com.pretzel.dev</groupId>
|
||||||
<artifactId>VillagerTradeLimiter</artifactId>
|
<artifactId>VillagerTradeLimiter</artifactId>
|
||||||
<version>1.5.3</version>
|
<version>1.5.4</version>
|
||||||
|
|
||||||
<properties>
|
<properties>
|
||||||
<java.version>1.8</java.version>
|
<java.version>1.8</java.version>
|
||||||
|
@ -13,7 +13,6 @@ import org.bukkit.entity.Villager;
|
|||||||
import org.bukkit.event.EventHandler;
|
import org.bukkit.event.EventHandler;
|
||||||
import org.bukkit.event.Listener;
|
import org.bukkit.event.Listener;
|
||||||
import org.bukkit.event.player.PlayerInteractEntityEvent;
|
import org.bukkit.event.player.PlayerInteractEntityEvent;
|
||||||
import org.bukkit.inventory.ItemStack;
|
|
||||||
import org.bukkit.potion.PotionEffect;
|
import org.bukkit.potion.PotionEffect;
|
||||||
import org.bukkit.potion.PotionEffectType;
|
import org.bukkit.potion.PotionEffectType;
|
||||||
|
|
||||||
@ -45,7 +44,7 @@ public class PlayerListener implements Listener {
|
|||||||
|
|
||||||
//Skips when player is holding an ignored item
|
//Skips when player is holding an ignored item
|
||||||
Material heldItemType = player.getInventory().getItem(event.getHand()).getType();
|
Material heldItemType = player.getInventory().getItem(event.getHand()).getType();
|
||||||
for(String ignoredType : instance.getCfg().getStringList("IgnoredHeldItems")) {
|
for(String ignoredType : instance.getCfg().getStringList("IgnoreHeldItems")) {
|
||||||
if(heldItemType.equals(Material.matchMaterial(ignoredType))) {
|
if(heldItemType.equals(Material.matchMaterial(ignoredType))) {
|
||||||
event.setCancelled(true);
|
event.setCancelled(true);
|
||||||
return;
|
return;
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
name: VillagerTradeLimiter
|
name: VillagerTradeLimiter
|
||||||
author: PretzelJohn
|
author: PretzelJohn
|
||||||
main: com.pretzel.dev.villagertradelimiter.VillagerTradeLimiter
|
main: com.pretzel.dev.villagertradelimiter.VillagerTradeLimiter
|
||||||
version: 1.5.3
|
version: 1.5.4
|
||||||
api-version: 1.14
|
api-version: 1.14
|
||||||
|
|
||||||
commands:
|
commands:
|
||||||
|
Loading…
Reference in New Issue
Block a user