Mirror von
https://github.com/PaperMC/Paper.git
synchronisiert 2024-12-18 04:20:08 +01:00
Fix donkey/mule dupe exploit.
Dieser Commit ist enthalten in:
Ursprung
7b71fc23be
Commit
29fa46a4b2
@ -60,7 +60,7 @@ public class ContainerHorse extends Container {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public boolean a(EntityHuman entityhuman) {
|
public boolean a(EntityHuman entityhuman) {
|
||||||
return this.a.a(entityhuman) && this.f.d(entityhuman) < 8.0F;
|
return this.a.a(entityhuman) && this.f.isAlive() && this.f.d(entityhuman) < 8.0F; // CraftBukkit - add isAlive as a validator
|
||||||
}
|
}
|
||||||
|
|
||||||
public ItemStack b(EntityHuman entityhuman, int i) {
|
public ItemStack b(EntityHuman entityhuman, int i) {
|
||||||
|
@ -791,11 +791,13 @@ public class EntityHorse extends EntityAnimal implements IInventoryListener {
|
|||||||
return this.passenger == null && this.vehicle == null && this.bS() && this.bR() && !this.cv() && this.getHealth() >= this.getMaxHealth();
|
return this.passenger == null && this.vehicle == null && this.bS() && this.bR() && !this.cv() && this.getHealth() >= this.getMaxHealth();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* CraftBukkit start - don't treat horses differently
|
||||||
public void die() {
|
public void die() {
|
||||||
if (this.world.isStatic || !this.bS() && !this.ce() || this.getHealth() <= 0.0F) {
|
if (this.world.isStatic || !this.bS() && !this.ce() || this.getHealth() <= 0.0F) {
|
||||||
super.die();
|
super.die();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// CraftBukkit end */
|
||||||
|
|
||||||
public void e(boolean flag) {
|
public void e(boolean flag) {
|
||||||
this.b(32, flag);
|
this.b(32, flag);
|
||||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren