This commit is contained in:
Sollace 2018-07-19 22:50:41 +02:00
parent dfd3c6f2ea
commit ebb139431b
4 changed files with 4 additions and 9 deletions

View file

@ -88,10 +88,6 @@ public final class HDSkinManager implements IResourceManagerReloadListener, ISki
private Class<? extends GuiSkins> skinsClass = null; private Class<? extends GuiSkins> skinsClass = null;
public static void clearSkinCache() {
INSTANCE.clearSKinCache();
}
public static PreviewTextureManager getPreviewTextureManager(GameProfile profile) { public static PreviewTextureManager getPreviewTextureManager(GameProfile profile) {
return new PreviewTextureManager(INSTANCE.getGatewayServer().getPreviewTextures(profile)); return new PreviewTextureManager(INSTANCE.getGatewayServer().getPreviewTextures(profile));
} }
@ -270,7 +266,7 @@ public final class HDSkinManager implements IResourceManagerReloadListener, ISki
clearListeners.add(listener); clearListeners.add(listener);
} }
private void clearSKinCache() { public void clearSkinCache() {
LiteLoaderLogger.info("Clearing local player skin cache"); LiteLoaderLogger.info("Clearing local player skin cache");
try { try {

View file

@ -60,7 +60,7 @@ public class LiteModHDSkins implements InitCompleteListener, ViewportListener, C
@Override @Override
public void upgradeSettings(String version, File configPath, File oldConfigPath) { public void upgradeSettings(String version, File configPath, File oldConfigPath) {
HDSkinManager.clearSkinCache(); HDSkinManager.INSTANCE.clearSkinCache();
} }
@Override @Override

View file

@ -11,7 +11,6 @@ import com.mojang.authlib.minecraft.MinecraftProfileTexture;
import com.mojang.authlib.minecraft.MinecraftProfileTexture.Type; import com.mojang.authlib.minecraft.MinecraftProfileTexture.Type;
import com.mumfrey.liteloader.util.log.LiteLoaderLogger; import com.mumfrey.liteloader.util.log.LiteLoaderLogger;
import com.voxelmodpack.hdskins.HDSkinManager; import com.voxelmodpack.hdskins.HDSkinManager;
import com.voxelmodpack.hdskins.server.SkinServer;
import com.voxelmodpack.hdskins.upload.FileDropListener; import com.voxelmodpack.hdskins.upload.FileDropListener;
import com.voxelmodpack.hdskins.upload.ThreadOpenFilePNG; import com.voxelmodpack.hdskins.upload.ThreadOpenFilePNG;
@ -226,7 +225,7 @@ public class GuiSkins extends GuiScreen {
super.onGuiClosed(); super.onGuiClosed();
localPlayer.releaseTextures(); localPlayer.releaseTextures();
remotePlayer.releaseTextures(); remotePlayer.releaseTextures();
HDSkinManager.clearSkinCache(); HDSkinManager.INSTANCE.clearSkinCache();
GLWindow.current().clearDropTargetListener(); GLWindow.current().clearDropTargetListener();
} }

View file

@ -41,7 +41,7 @@ public class HDSkinsConfigPanel implements ConfigPanel {
Minecraft mc = Minecraft.getMinecraft(); Minecraft mc = Minecraft.getMinecraft();
if (button.mousePressed(mc, mouseX, mouseY)) { if (button.mousePressed(mc, mouseX, mouseY)) {
HDSkinManager.clearSkinCache(); HDSkinManager.INSTANCE.clearSkinCache();
} else if (checkbox.mousePressed(mc, mouseX, mouseY)) { } else if (checkbox.mousePressed(mc, mouseX, mouseY)) {
checkbox.checked = !checkbox.checked; checkbox.checked = !checkbox.checked;
mod.experimentalSkinDrop = checkbox.checked; mod.experimentalSkinDrop = checkbox.checked;