mirror of
https://github.com/barkeser2002/CatServer.git
synced 2026-09-25 06:40:05 +03:00
54 lines
1.5 KiB
Diff
54 lines
1.5 KiB
Diff
--- ../src-base/minecraft/net/minecraft/entity/passive/EntityAnimal.java
|
|
+++ ../src-work/minecraft/net/minecraft/entity/passive/EntityAnimal.java
|
|
@@ -10,7 +10,6 @@
|
|
import net.minecraft.init.Items;
|
|
import net.minecraft.item.ItemStack;
|
|
import net.minecraft.nbt.NBTTagCompound;
|
|
-import net.minecraft.util.DamageSource;
|
|
import net.minecraft.util.EnumHand;
|
|
import net.minecraft.util.EnumParticleTypes;
|
|
import net.minecraft.util.math.BlockPos;
|
|
@@ -25,6 +24,8 @@
|
|
private int inLove;
|
|
private UUID playerInLove;
|
|
|
|
+ public ItemStack breedItem; // CraftBukkit - Add breedItem variable
|
|
+
|
|
public EntityAnimal(World worldIn)
|
|
{
|
|
super(worldIn);
|
|
@@ -63,6 +64,8 @@
|
|
}
|
|
}
|
|
|
|
+ /* CraftBukkit start
|
|
+ // Function disabled as it has no special function anymore after setSitting is disabled.
|
|
public boolean attackEntityFrom(DamageSource source, float amount)
|
|
{
|
|
if (this.isEntityInvulnerable(source))
|
|
@@ -75,6 +78,7 @@
|
|
return super.attackEntityFrom(source, amount);
|
|
}
|
|
}
|
|
+ // CraftBukkit end */
|
|
|
|
public float getBlockPathWeight(BlockPos pos)
|
|
{
|
|
@@ -118,7 +122,7 @@
|
|
return 120;
|
|
}
|
|
|
|
- protected boolean canDespawn()
|
|
+ public boolean canDespawn()
|
|
{
|
|
return false;
|
|
}
|
|
@@ -172,6 +176,7 @@
|
|
if (player != null)
|
|
{
|
|
this.playerInLove = player.getUniqueID();
|
|
+ this.breedItem = player.inventory.getCurrentItem();
|
|
}
|
|
|
|
this.world.setEntityState(this, (byte)18);
|