Futurepack Mod - Now with flyable Spaceships!

Futurepack Mod - Now with flyable Spaceships!

1M Downloads

Non complainant capability provider implementations causing null dereferences

pau101 opened this issue ยท 3 comments

commented

The classes TileEntityModulT1, TileEntityModulT2, TileEntityIndustrialFurnace, and TileEntityBlockPlacer contain implementations of ICapabilityProvider#getCapability which erroneously return null, as opposed to the correct LazyOptional.empty(), resulting in null dereferences in mods querying capabilities of these blocks.

An instance which I have received of such a crash: pau101/Fairy-Lights#84

commented

Most likely more machines are affected:

if(facing==null)
			return null;

This code is used for all machines with configureable sides.

commented

When I checked most with the null facing check do actually return empty, but just some not, but do ensure I didn't miss any.

commented

I wanted to note that the Error is occuring in 1.14.4 as well. Im here because Fairy-Lights crashes because of this Futurepack Error(?) in a Futurepack Dungeon in 1.14.4 as well