Fix block stack duplicating in the database

This commit is contained in:
ceze88 2023-11-13 21:13:05 +01:00
parent cc66c46bc3
commit 85a7995420
1 changed files with 7 additions and 6 deletions

View File

@ -27,15 +27,16 @@ public class BlockStackImpl implements BlockStack {
private XMaterial material;
private Location location;
/**
* Required for deserialization
*/
public BlockStackImpl() {
}
public BlockStackImpl(XMaterial material, Location location) {
this.material = material;
this.location = location;
}
public BlockStackImpl(XMaterial material, Location location, int amount) {
this.amount = amount;
this.material = material;
this.location = location;
this.id = UltimateStacker.getInstance().getDataManager().getNextId("blocks");
}
@Override