forked from cafeberry/cafeberry
feat(TU20/21): Implement la's TU21 patch file
This adds the following: TU20: 1. Librarians now have a small chance to offer name tags for sale 2. Witches can now spawn at light level 7 or less in any biome or cave 3. Skeletons & Wither Skeletons now rarely spawn anywhere in the Nether TU21: 1. Minecart entity limit increased
This commit is contained in:
@@ -221,6 +221,12 @@ void Animal::readAdditionalSaveData(CompoundTag *tag)
|
||||
setDespawnProtected();
|
||||
}
|
||||
|
||||
void Animal::dropLeash(bool synch, bool createItemDrop)
|
||||
{
|
||||
setDespawnProtected();
|
||||
Mob::dropLeash(synch, createItemDrop);
|
||||
}
|
||||
|
||||
shared_ptr<Entity> Animal::findAttackTarget()
|
||||
{
|
||||
if (fleeTime > 0) return nullptr;
|
||||
@@ -294,7 +300,7 @@ int Animal::getAmbientSoundInterval()
|
||||
|
||||
bool Animal::removeWhenFarAway()
|
||||
{
|
||||
return !isDespawnProtected(); // 4J changed - was false
|
||||
return !hasCustomName() && !isLeashed() && !isDespawnProtected();
|
||||
}
|
||||
|
||||
int Animal::getExperienceReward(shared_ptr<Player> killedBy)
|
||||
|
||||
Reference in New Issue
Block a user