today in "stupid reasons for null pointer exceptions"

Closes #44
This commit is contained in:
Ellpeck 2019-04-06 17:16:42 +02:00
parent fb86501fcc
commit e3d6b488bb

View file

@ -51,8 +51,8 @@ public class BlockProjectileGenerator extends BlockContainerImpl implements ITES
if (generator.nextSide != ray.sideHit) if (generator.nextSide != ray.sideHit)
return; return;
ResourceLocation name = EntityList.getKey(entity); ResourceLocation name = EntityList.getKey(entity);
int amount = NaturesAuraAPI.PROJECTILE_GENERATIONS.get(name); Integer amount = NaturesAuraAPI.PROJECTILE_GENERATIONS.get(name);
if (amount <= 0) if (amount == null || amount <= 0)
return; return;
BlockPos spot = IAuraChunk.getLowestSpot(entity.world, pos, 35, pos); BlockPos spot = IAuraChunk.getLowestSpot(entity.world, pos, 35, pos);