Copy neat fix for negative scaling of magic light on desync to black hole

This commit is contained in:
Electroblob77
2019-12-16 15:39:23 +00:00
parent 2b89a890d0
commit ffea49bc40
@@ -53,9 +53,8 @@ public class RenderBlackHole extends Render<EntityBlackHole> {
(float)blackhole.ticksExisted / 10);
}
if(blackhole.ticksExisted > blackhole.lifetime - 10){
GlStateManager.scale((float)(blackhole.lifetime - blackhole.ticksExisted) / 10,
(float)(blackhole.lifetime - blackhole.ticksExisted) / 10,
(float)(blackhole.lifetime - blackhole.ticksExisted) / 10);
float scale = Math.max(0, (float)(blackhole.lifetime - blackhole.ticksExisted) / 10);
GlStateManager.scale(scale, scale, scale);
}
this.bindTexture(texture);