mirror of
https://github.com/KAMKEEL/CustomNPC-Plus.git
synced 2026-11-16 21:05:06 +00:00
URLs on Cloaks
This commit is contained in:
1 parent
64a70fb1bb
commit
3f534ee004
7 files changed
+8
-10
No files matched your search
@@ -195,7 +195,6 @@ public class DataDisplay {
|
||||
|
||||
if(prevSkinType != skinType || !texture.equals(prevTexture))
|
||||
npc.textureLocation = null;
|
||||
npc.textureCloakLocation = null;
|
||||
npc.updateHitbox();
|
||||
}
|
||||
|
||||
|
||||
@@ -89,7 +89,6 @@ public class EntityUtil {
|
||||
EntityNPCInterface target = (EntityNPCInterface) entity;
|
||||
|
||||
target.textureLocation = npc.textureLocation;
|
||||
target.textureCloakLocation = npc.textureCloakLocation;
|
||||
target.display = npc.display;
|
||||
target.inventory = npc.inventory;
|
||||
|
||||
|
||||
@@ -74,7 +74,6 @@ public class GuiNpcTextureCloaks extends GuiNpcSelectionInterface
|
||||
public void elementClicked(){
|
||||
if(dataTextures.contains(slot.selected) && slot.selected != null){
|
||||
npc.display.cloakTexture = assets.getAsset(slot.selected);
|
||||
npc.textureCloakLocation = null;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -124,12 +124,9 @@ public class GuiNpcDisplay extends GuiNPCInterface2 implements ITextfieldListene
|
||||
display.texture = textfield.getText();
|
||||
}
|
||||
else if(textfield.id == 8){
|
||||
npc.textureCloakLocation = null;
|
||||
display.cloakTexture = textfield.getText();
|
||||
}
|
||||
else if(textfield.id == 9){
|
||||
//npc.textureGlowLocation = null;
|
||||
//display.glowTexture = textfield.getText();
|
||||
if (!textfield.getText().isEmpty()) {
|
||||
npc.display.skinOverlayData.overlayList.put(0,new SkinOverlay(textfield.getText()));
|
||||
} else {
|
||||
|
||||
@@ -934,10 +934,15 @@ public class ModelMPM extends ModelNPCMale{
|
||||
public void renderCloak(EntityCustomNpc npc, float f){
|
||||
if (!npc.display.cloakTexture.isEmpty() && !isArmor)
|
||||
{
|
||||
if(npc.textureCloakLocation == null){
|
||||
npc.textureCloakLocation = new ResourceLocation(npc.display.cloakTexture);
|
||||
ImageData imageData = ClientCacheHandler.getImageData(npc.display.cloakTexture);
|
||||
if (!imageData.imageLoaded())
|
||||
return;
|
||||
|
||||
try {
|
||||
imageData.bindTexture();
|
||||
} catch (Exception e) { return;
|
||||
}
|
||||
bindTexture((ResourceLocation) npc.textureCloakLocation);
|
||||
|
||||
GL11.glPushMatrix();
|
||||
GL11.glTranslatef(0.0F, 0.0F, 0.125F);
|
||||
double d = (npc.field_20066_r + (npc.field_20063_u - npc.field_20066_r) * (double)f) - (npc.prevPosX + (npc.posX - npc.prevPosX) * (double)f);
|
||||
|
||||
@@ -104,7 +104,6 @@ public abstract class EntityNPCInterface extends EntityCreature implements IEnti
|
||||
public List<EntityLivingBase> interactingEntities = new ArrayList<EntityLivingBase>();
|
||||
|
||||
public ResourceLocation textureLocation = null;
|
||||
public ResourceLocation textureCloakLocation = null;
|
||||
|
||||
public EnumAnimation currentAnimation = EnumAnimation.NONE;
|
||||
|
||||
|
||||
Reference in new issue
Block a user