mirror of
https://github.com/Thorfusion/Mekanism-Community-Edition.git
synced 2026-11-20 20:12:30 +00:00
Fixed capes
This commit is contained in:
1 parent
50f7df5f98
commit
086dd83a57
3 files changed
+44
-24
No files matched your search
@@ -1,5 +1,9 @@
|
||||
package mekanism.client;
|
||||
|
||||
import static mekanism.client.sound.SoundHandler.Channel.FLAMETHROWER;
|
||||
import static mekanism.client.sound.SoundHandler.Channel.GASMASK;
|
||||
import static mekanism.client.sound.SoundHandler.Channel.JETPACK;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.HashSet;
|
||||
import java.util.Iterator;
|
||||
@@ -26,12 +30,14 @@ import mekanism.common.network.PacketJetpackData.JetpackPacket;
|
||||
import mekanism.common.network.PacketScubaTankData.ScubaTankDataMessage;
|
||||
import mekanism.common.network.PacketScubaTankData.ScubaTankPacket;
|
||||
import mekanism.common.util.MekanismUtils;
|
||||
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.entity.AbstractClientPlayer;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.StringUtils;
|
||||
|
||||
import com.mojang.authlib.minecraft.MinecraftProfileTexture;
|
||||
|
||||
import cpw.mods.fml.client.FMLClientHandler;
|
||||
import cpw.mods.fml.common.eventhandler.SubscribeEvent;
|
||||
import cpw.mods.fml.common.gameevent.TickEvent.ClientTickEvent;
|
||||
@@ -39,10 +45,6 @@ import cpw.mods.fml.common.gameevent.TickEvent.Phase;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
import static mekanism.client.sound.SoundHandler.Channel.FLAMETHROWER;
|
||||
import static mekanism.client.sound.SoundHandler.Channel.GASMASK;
|
||||
import static mekanism.client.sound.SoundHandler.Channel.JETPACK;
|
||||
|
||||
/**
|
||||
* Client-side tick handler for Mekanism. Used mainly for the update check upon startup.
|
||||
* @author AidanBrady
|
||||
@@ -150,8 +152,7 @@ public class ClientTickHandler
|
||||
continue;
|
||||
}
|
||||
|
||||
MekanismUtils.setPrivateValue(player, download.getImage(), AbstractClientPlayer.class, ObfuscatedNames.AbstractClientPlayer_downloadImageCape);
|
||||
MekanismUtils.setPrivateValue(player, download.getResourceLocation(), AbstractClientPlayer.class, ObfuscatedNames.AbstractClientPlayer_locationCape);
|
||||
player.func_152121_a(MinecraftProfileTexture.Type.CAPE, download.getResourceLocation());
|
||||
}
|
||||
}
|
||||
else if(StringUtils.stripControlCodes(player.getCommandSenderName()).equals("aidancbrady"))
|
||||
@@ -171,8 +172,7 @@ public class ClientTickHandler
|
||||
continue;
|
||||
}
|
||||
|
||||
MekanismUtils.setPrivateValue(player, download.getImage(), AbstractClientPlayer.class, ObfuscatedNames.AbstractClientPlayer_downloadImageCape);
|
||||
MekanismUtils.setPrivateValue(player, download.getResourceLocation(), AbstractClientPlayer.class, ObfuscatedNames.AbstractClientPlayer_locationCape);
|
||||
player.func_152121_a(MinecraftProfileTexture.Type.CAPE, download.getResourceLocation());
|
||||
}
|
||||
}
|
||||
else if(Mekanism.donators.contains(StringUtils.stripControlCodes(player.getCommandSenderName())))
|
||||
@@ -192,8 +192,7 @@ public class ClientTickHandler
|
||||
continue;
|
||||
}
|
||||
|
||||
MekanismUtils.setPrivateValue(player, download.getImage(), AbstractClientPlayer.class, ObfuscatedNames.AbstractClientPlayer_downloadImageCape);
|
||||
MekanismUtils.setPrivateValue(player, download.getResourceLocation(), AbstractClientPlayer.class, ObfuscatedNames.AbstractClientPlayer_locationCape);
|
||||
player.func_152121_a(MinecraftProfileTexture.Type.CAPE, download.getResourceLocation());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user