mirror of
https://github.com/MineLittlePony/MineLittlePony.git
synced 2025-02-13 16:24:23 +01:00
Fixed the pony level
This commit is contained in:
parent
3f1744d98a
commit
8446ec3ca7
2 changed files with 24 additions and 0 deletions
|
@ -0,0 +1,18 @@
|
||||||
|
package com.minelittlepony.client.gui.hdskins;
|
||||||
|
|
||||||
|
import com.minelittlepony.client.settings.ClientPonyConfig;
|
||||||
|
import com.minelittlepony.hdskins.HDSkins;
|
||||||
|
import com.minelittlepony.settings.PonyLevel;
|
||||||
|
|
||||||
|
class ClientPonyConfigHDSkins extends ClientPonyConfig {
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void setPonyLevel(PonyLevel ponylevel) {
|
||||||
|
// only trigger reloads when the value actually changes
|
||||||
|
if (ponylevel != getPonyLevel()) {
|
||||||
|
HDSkins.getInstance().getSkinParser().execute();
|
||||||
|
}
|
||||||
|
|
||||||
|
super.setPonyLevel(ponylevel);
|
||||||
|
}
|
||||||
|
}
|
|
@ -5,6 +5,7 @@ import net.minecraft.client.MinecraftClient;
|
||||||
import net.minecraft.util.Identifier;
|
import net.minecraft.util.Identifier;
|
||||||
|
|
||||||
import com.minelittlepony.client.MineLPClient;
|
import com.minelittlepony.client.MineLPClient;
|
||||||
|
import com.minelittlepony.client.settings.ClientPonyConfig;
|
||||||
import com.minelittlepony.client.LegacySkinConverter;
|
import com.minelittlepony.client.LegacySkinConverter;
|
||||||
import com.minelittlepony.hdskins.HDSkins;
|
import com.minelittlepony.hdskins.HDSkins;
|
||||||
import com.minelittlepony.hdskins.ISkinCacheClearListener;
|
import com.minelittlepony.hdskins.ISkinCacheClearListener;
|
||||||
|
@ -67,6 +68,11 @@ class MineLPHDSkins extends MineLPClient implements ISkinCacheClearListener {
|
||||||
manager.setSkinsGui(GuiSkinsMineLP::new);
|
manager.setSkinsGui(GuiSkinsMineLP::new);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
protected ClientPonyConfig createConfig() {
|
||||||
|
return new ClientPonyConfigHDSkins();
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public Map<MinecraftProfileTexture.Type, Identifier> getProfileTextures(@Nullable GameProfile profile) {
|
public Map<MinecraftProfileTexture.Type, Identifier> getProfileTextures(@Nullable GameProfile profile) {
|
||||||
return HDSkins.getInstance().getTextures(profile);
|
return HDSkins.getInstance().getTextures(profile);
|
||||||
|
|
Loading…
Reference in a new issue