Add EntityEquipment API. Adds BUKKIT-3103

Adds:
- Getting/Setting equipment
- getting/setting drop rates
- getting/setting ability to pick up items
-- As an added feature, players with this flag start off with a canceled PlayerPickupItemEvent
This commit is contained in:
feildmaster
2012-12-09 00:09:48 -06:00
parent 684ba31c39
commit 430d352a5a
7 changed files with 213 additions and 3 deletions

View File

@@ -82,11 +82,11 @@ public abstract class EntityLiving extends Entity {
private ChunkCoordinates bP = new ChunkCoordinates(0, 0, 0);
private float bQ = -1.0F;
private ItemStack[] equipment = new ItemStack[5];
protected float[] dropChances = new float[5];
public float[] dropChances = new float[5]; // CraftBukkit - protected -> public
private ItemStack[] bS = new ItemStack[5];
public boolean bp = false;
public int bq = 0;
protected boolean canPickUpLoot = false;
public boolean canPickUpLoot = false; // CraftBukkit - protected -> public
public boolean persistent = !this.bj(); // CraftBukkit - private -> public, change value
protected int bs;
protected double bt;