mirror of
https://github.com/songoda/EpicHoppers.git
synced 2025-01-25 00:51:26 +01:00
Null Checks
This commit is contained in:
parent
fe16c755e7
commit
e72e4939fa
@ -58,6 +58,8 @@ public class HopHandler {
|
||||
|
||||
List<Material> blockedMaterials = new ArrayList<>();
|
||||
|
||||
if (hopperState == null || hopperState.getInventory() == null) continue;
|
||||
|
||||
for (Module module : hopper.getLevel().getRegisteredModules()) {
|
||||
// Run Module
|
||||
module.run(hopper);
|
||||
|
@ -61,6 +61,7 @@ public class ModuleSuction implements Module {
|
||||
hopItem.setAmount(WildStackerAPI.getItemAmount((Item)entity));
|
||||
|
||||
ItemStack item = ((Item) entity).getItemStack();
|
||||
if (item == null) continue;
|
||||
if (!canMove(hopperBlock.getInventory(), item)) {
|
||||
continue;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user