[Bleeding] Added Potions API. Fixes BUKKIT-389

This commit is contained in:
fullwall
2012-01-09 15:51:32 +08:00
committed by EvilSeph
parent 63b9ed9ab4
commit f52665348e
8 changed files with 227 additions and 3 deletions

View File

@@ -63,7 +63,7 @@ public abstract class EntityLiving extends Entity {
protected EntityLiving lastDamager = null;
public int aJ = 0;
public int aK = 0;
protected HashMap effects = new HashMap();
public HashMap effects = new HashMap(); // CraftBukkit - protected -> public
private boolean b = true;
private int c;
private ControllerLook lookController;

View File

@@ -2,7 +2,9 @@ package net.minecraft.server;
// CraftBukkit start
import org.bukkit.Bukkit;
import org.bukkit.potion.PotionEffectType;
import org.bukkit.craftbukkit.event.CraftEventFactory;
import org.bukkit.craftbukkit.potion.CraftPotionEffectType;
import org.bukkit.event.entity.EntityDamageEvent;
import org.bukkit.event.entity.EntityDamageEvent.DamageCause;
import org.bukkit.event.entity.EntityRegainHealthEvent.RegainReason;
@@ -62,6 +64,8 @@ public class MobEffectList {
}
this.N = j;
PotionEffectType.registerPotionEffectType(new CraftPotionEffectType(this)); // CraftBukkit
}
protected MobEffectList a(int i, int j) {