Fix error due to cross thread shenanigans

This commit is contained in:
Sollace 2018-07-26 17:00:56 +02:00
parent 26a7d87e10
commit 892553838b

View file

@ -56,7 +56,12 @@ public class PreviewTextureManager {
PreviewTexture skinTexture = new PreviewTexture(texture, def, buffer); PreviewTexture skinTexture = new PreviewTexture(texture, def, buffer);
Minecraft.getMinecraft().getTextureManager().loadTexture(location, skinTexture); Minecraft mc = Minecraft.getMinecraft();
mc.addScheduledTask(() -> {
mc.getTextureManager().loadTexture(location, skinTexture);
});
return skinTexture; return skinTexture;
} }