Add a Thanksgiving check for eating cooked chicken.

master_event
sigonasr2 11 years ago
parent b242bfd49b
commit 191c2c183f
  1. 2
      BankEconomyMod/src/me/kaZep/Base/PlayerListener.java

@ -845,7 +845,7 @@ implements Listener
@EventHandler
public void onPlayerItemConsume(PlayerItemConsumeEvent e) {
Player p = e.getPlayer();
if (e.getItem().getType() == Material.COOKED_CHICKEN) {
if (e.getItem().getType() == Material.COOKED_CHICKEN && this.plugin.getConfig().getBoolean("thanksgiving-enabled")) {
p.addPotionEffect(new PotionEffect(PotionEffectType.SATURATION, 18000, 0), true);
p.addPotionEffect(new PotionEffect(PotionEffectType.HEALTH_BOOST, 18000, 4), true);
p.addPotionEffect(new PotionEffect(PotionEffectType.SPEED, 18000, 2), true);

Loading…
Cancel
Save