Minor fix for loots

This commit is contained in:
ceze88 2023-02-17 16:33:28 +01:00
parent d610f41d00
commit 9f77b48974
2 changed files with 5 additions and 1 deletions

View File

@ -133,8 +133,8 @@ public class EntityStack extends StackedEntity {
return;
}
}
handleSingleStackDeath(killed, drops, droppedExp, event);
}
handleSingleStackDeath(killed, drops, droppedExp, event);
}
public synchronized LivingEntity takeOneAndSpawnEntity(Location location) {

View File

@ -109,6 +109,10 @@ public class EntityStackManager {
if (stack == null) return null;
int amount = stack.getAmount()-1;
stack.destroy();
if (amount == 0 && newEntity != null) {
newEntity.remove();
return null;
}
return createStack(newEntity, amount);
}