Added Backup Rendering If A Size Is Not Present

This commit is contained in:
Rabbitminers 2023-04-30 21:01:19 +01:00
parent 2b76e8d7b3
commit 08c000b8ba

View file

@ -7,6 +7,7 @@ import com.jozufozu.flywheel.util.AnimationTickHolder;
import com.jozufozu.flywheel.util.transform.TransformStack; import com.jozufozu.flywheel.util.transform.TransformStack;
import com.mojang.blaze3d.vertex.PoseStack; import com.mojang.blaze3d.vertex.PoseStack;
import com.mojang.math.Vector3f; import com.mojang.math.Vector3f;
import com.simibubi.create.content.logistics.trains.BogeyRenderer;
import com.simibubi.create.foundation.utility.Couple; import com.simibubi.create.foundation.utility.Couple;
import com.simibubi.create.foundation.utility.Iterate; import com.simibubi.create.foundation.utility.Iterate;
@ -99,8 +100,10 @@ public class CarriageContraptionInstance extends EntityInstance<CarriageContrapt
return; return;
bogeys.forEach(instance -> { bogeys.forEach(instance -> {
if (instance != null) if (instance != null) {
instance.commonRenderer.ifPresent(BogeyRenderer::remove);
instance.renderer.remove(); instance.renderer.remove();
}
}); });
} }