use of net.minecraft.client.renderer.block.model.ModelBlock in project GregTech by GregTechCE.
the class MetaTileEntityRenderer method postInit.
public static void postInit() {
try {
IResource resource = Minecraft.getMinecraft().getResourceManager().getResource(new ResourceLocation("models/block/block.json"));
try (InputStreamReader reader = new InputStreamReader(resource.getInputStream())) {
ModelBlock modelBlock = ModelBlock.deserialize(reader);
for (TransformType transformType : TransformType.values()) {
ItemTransformVec3f vec3f = modelBlock.getAllTransforms().getTransform(transformType);
BLOCK_TRANSFORMS.put(transformType, new TRSRTransformation(vec3f));
}
}
} catch (IOException exception) {
GTLog.logger.error("Failed to load default block transforms", exception);
}
}
Aggregations