Make blockstate model loader more resilient

This commit is contained in:
embeddedt 2024-06-08 16:41:45 -04:00
parent a0f391e258
commit 9d584d13d2
No known key found for this signature in database
GPG Key ID: A69433EC199B5613

View File

@ -56,8 +56,11 @@ public abstract class BlockStateModelLoaderMixin implements IBlockStateModelLoad
ModernFix.LOGGER.error("Exception filtering states on {}", location, e);
filteredStates = null;
}
this.loadBlockStateDefinitions(location.id(), optionalBlock.get().getStateDefinition());
filteredStates = null;
try {
this.loadBlockStateDefinitions(location.id(), optionalBlock.get().getStateDefinition());
} finally {
filteredStates = null;
}
}
}