Fix inventory not being stored in chests of a cell
This commit is contained in:
parent
e77cda996e
commit
45a0c79bdd
@ -201,7 +201,9 @@ public class Cell implements ICell {
|
|||||||
|
|
||||||
public Chest getChest() {
|
public Chest getChest() {
|
||||||
if(this.chest == null) return null;
|
if(this.chest == null) return null;
|
||||||
if(this.chest.getLocation().getBlock() == null || this.chest.getLocation().getBlock().getType() != Material.CHEST) return null;
|
if(this.chest.getLocation().getBlock() == null
|
||||||
|
|| (this.chest.getLocation().getBlock().getType() != Material.CHEST
|
||||||
|
&& this.chest.getLocation().getBlock().getType() != Material.TRAPPED_CHEST)) return null;
|
||||||
|
|
||||||
return (Chest) this.chest.getLocation().getBlock().getState();
|
return (Chest) this.chest.getLocation().getBlock().getState();
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user