Fx nullable fallback being passed into nonnull context
@@ -104,8 +104,10 @@ public class MaterialRegistryImpl implements IMaterialRegistry {
@Override
public <T extends IMaterialStats> void registerStatType(T defaultStats, Class<T> clazz, Function<FriendlyByteBuf,T> decoder, @Nullable MaterialStatsId fallback) {
registerStatType(defaultStats, clazz, decoder);
+ if (fallback != null) {
materialTraitsManager.registerStatTypeFallback(defaultStats.getIdentifier(), fallback);
}
+ }
/* Traits */
