mirror of
https://github.com/KAMKEEL/CustomNPC-Plus.git
synced 2026-11-26 19:43:07 +00:00
Revert "NPC Skin Changes"
This commit is contained in:
1 parent
3b6668ea15
commit
fd0a99b3ed
13 files changed
+64
-106
No files matched your search
@@ -77,7 +77,7 @@ public class GuiNpcTextureOverlays extends GuiNpcSelectionInterface{
|
||||
public void elementClicked(){
|
||||
if(dataTextures.contains(slot.selected) && slot.selected != null){
|
||||
//npc.display.glowTexture = assets.getAsset(slot.selected);
|
||||
//npc.textureGlowLocation = null;
|
||||
npc.textureGlowLocation = null;
|
||||
|
||||
npc.display.skinOverlayData.overlayList.put(0,new SkinOverlay(
|
||||
assets.getAsset(slot.selected), true, 1.0F, 1.0F, 0.0F, 0.0F,
|
||||
|
||||
@@ -129,14 +129,12 @@ public class GuiNpcDisplay extends GuiNPCInterface2 implements ITextfieldListene
|
||||
display.cloakTexture = textfield.getText();
|
||||
}
|
||||
else if(textfield.id == 9){
|
||||
//npc.textureGlowLocation = null;
|
||||
npc.textureGlowLocation = null;
|
||||
//display.glowTexture = textfield.getText();
|
||||
if (!textfield.getText().isEmpty()) {
|
||||
npc.display.skinOverlayData.overlayList.put(0, new SkinOverlay(
|
||||
textfield.getText(), true, 1.0F, 1.0F, 0.0F, 0.0F,
|
||||
1.0F, 1.0F, 0.0F, 0.0F, 0.0F
|
||||
));
|
||||
}
|
||||
npc.display.skinOverlayData.overlayList.put(0,new SkinOverlay(
|
||||
textfield.getText(), true, 1.0F, 1.0F, 0.0F, 0.0F,
|
||||
1.0F, 1.0F, 0.0F, 0.0F, 0.0F
|
||||
));
|
||||
}
|
||||
else if(textfield.id == 11){
|
||||
display.title = textfield.getText();
|
||||
|
||||
@@ -110,25 +110,25 @@ public class GuiCreationScreen extends GuiModelInterface implements ICustomScrol
|
||||
addButton(new GuiNpcButton(7, guiLeft + 50, y += 22, 50, 20, "selectServer.edit"));
|
||||
addLabel(new GuiNpcLabel(4, "Legs", guiLeft, y + 5, 0xFFFFFF));
|
||||
|
||||
addButton(new GuiNpcButton(250, guiLeft + 50, y += 22, 50, 20, new String[]{"Steve","Alex"}, this.npc.display.modelType/2));
|
||||
addButton(new GuiNpcButton(250, guiLeft + 50, y += 22, 50, 20, new String[]{"Default","Steve64","Alex"}, this.npc.display.modelType));
|
||||
addLabel(new GuiNpcLabel(250, "Model", guiLeft, y + 5, 0xFFFFFF));
|
||||
|
||||
|
||||
addButton(new GuiNpcButton(44, guiLeft + 310, guiTop + 14, 80, 20, "Save Model"));
|
||||
addButton(new GuiNpcButton(45, guiLeft + 310, guiTop + 36, 80, 20, "Load Model"));
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
private void showPixelmonMenu(EntityLivingBase entity) {
|
||||
GuiCustomScroll scroll = new GuiCustomScroll(this, 0);
|
||||
scroll.setSize(120, 200);
|
||||
scroll.guiLeft = guiLeft;
|
||||
scroll.guiTop = guiTop + 20;
|
||||
addScroll(scroll);
|
||||
|
||||
|
||||
scroll.setList(PixelmonHelper.getPixelmonList());
|
||||
scroll.setSelected(PixelmonHelper.getName(entity));
|
||||
|
||||
|
||||
Minecraft.getMinecraft().thePlayer.sendChatMessage(PixelmonHelper.getName(entity));
|
||||
}
|
||||
|
||||
@@ -137,7 +137,7 @@ public class GuiCreationScreen extends GuiModelInterface implements ICustomScrol
|
||||
if(entity instanceof EntityNPCInterface)
|
||||
return;
|
||||
int y = guiTop + 20;
|
||||
|
||||
|
||||
NBTTagCompound compound = getExtras(entity);
|
||||
Set<String> keys = compound.func_150296_c();
|
||||
int i = 0;
|
||||
@@ -159,7 +159,7 @@ public class GuiCreationScreen extends GuiModelInterface implements ICustomScrol
|
||||
i++;
|
||||
addLabel(new GuiNpcLabel(100 + i, name, guiLeft, y + 5 + i * 22, 0xFFFFFF));
|
||||
addButton(new GuiNpcButton(100 + i, guiLeft + 80, y + i * 22, 50, 20, new String[]{"gui.no","gui.yes"}, b));
|
||||
|
||||
|
||||
mapped.put(i, name);
|
||||
}
|
||||
}
|
||||
@@ -169,7 +169,7 @@ public class GuiCreationScreen extends GuiModelInterface implements ICustomScrol
|
||||
Method method = entity.getClass().getMethod("getBreedID");
|
||||
breed = (Integer) method.invoke(entity);
|
||||
} catch (Exception e) {
|
||||
|
||||
|
||||
}
|
||||
i++;
|
||||
addLabel(new GuiNpcLabel(201, "Breed", guiLeft, y + 5 + i * 22, 0xFFFFFF));
|
||||
@@ -186,18 +186,18 @@ public class GuiCreationScreen extends GuiModelInterface implements ICustomScrol
|
||||
private NBTTagCompound getExtras(EntityLivingBase entity) {
|
||||
NBTTagCompound fake = new NBTTagCompound();
|
||||
new EntityFakeLiving(entity.worldObj).writeEntityToNBT(fake);
|
||||
|
||||
|
||||
NBTTagCompound compound = new NBTTagCompound();
|
||||
try{
|
||||
entity.writeEntityToNBT(compound);
|
||||
}
|
||||
catch(Exception e){
|
||||
|
||||
|
||||
}
|
||||
Set<String> keys = fake.func_150296_c();
|
||||
for(String name : keys)
|
||||
compound.removeTag(name);
|
||||
|
||||
|
||||
return compound;
|
||||
}
|
||||
|
||||
@@ -221,7 +221,7 @@ public class GuiCreationScreen extends GuiModelInterface implements ICustomScrol
|
||||
}
|
||||
else{
|
||||
playerdata.setEntityClass(data.get(list.get(index)));
|
||||
|
||||
|
||||
EntityLivingBase entity = playerdata.getEntity(npc);
|
||||
if(entity != null){
|
||||
RendererLivingEntity render = (RendererLivingEntity) RenderManager.instance.getEntityRenderObject(entity);
|
||||
@@ -231,6 +231,7 @@ public class GuiCreationScreen extends GuiModelInterface implements ICustomScrol
|
||||
//npc.display.glowTexture = "";
|
||||
npc.display.skinOverlayData.overlayList.remove(0);
|
||||
npc.textureLocation = null;
|
||||
npc.textureGlowLocation = null;
|
||||
npc.updateHitbox();
|
||||
}
|
||||
catch(Exception ex){
|
||||
@@ -246,10 +247,10 @@ public class GuiCreationScreen extends GuiModelInterface implements ICustomScrol
|
||||
playerdata.setEntityClass(data.get(list.get(index)));
|
||||
|
||||
updateTexture();
|
||||
|
||||
|
||||
initGui();
|
||||
}
|
||||
|
||||
|
||||
if(button.id == 1){
|
||||
this.mc.displayGuiScreen(new GuiEntitySelection(this, playerdata, npc));
|
||||
}
|
||||
@@ -270,18 +271,21 @@ public class GuiCreationScreen extends GuiModelInterface implements ICustomScrol
|
||||
// New Button for Changing Models
|
||||
// URL Swapper
|
||||
if(button.id == 250){
|
||||
npc.display.modelType = button.displayString.equals("Alex") ? 2 : 1;
|
||||
|
||||
if(npc.display.modelType == 1){
|
||||
if(npc.display.modelType == 0){
|
||||
if (npc.display.skinType == 2){
|
||||
npc.display.skinType = 3;
|
||||
}
|
||||
} else {
|
||||
npc.display.modelType = 1;
|
||||
}
|
||||
else if(npc.display.modelType == 1){
|
||||
npc.display.modelType = 2;
|
||||
}
|
||||
else {
|
||||
if (npc.display.skinType == 3){
|
||||
npc.display.skinType = 2;
|
||||
}
|
||||
npc.display.modelType = 0;
|
||||
}
|
||||
npc.textureLocation = null;
|
||||
}
|
||||
|
||||
if(button.id == 8){
|
||||
@@ -335,6 +339,7 @@ public class GuiCreationScreen extends GuiModelInterface implements ICustomScrol
|
||||
//npc.display.glowTexture = "";
|
||||
npc.display.skinOverlayData.overlayList.remove(0);
|
||||
npc.textureLocation = null;
|
||||
npc.textureGlowLocation = null;
|
||||
npc.updateHitbox();
|
||||
}
|
||||
catch(Exception ex){
|
||||
|
||||
@@ -129,6 +129,7 @@ public class GuiEntitySelection extends GuiNPCInterface
|
||||
//npc.display.glowTexture = "";
|
||||
npc.display.skinOverlayData.overlayList.remove(0);
|
||||
npc.textureLocation = null;
|
||||
npc.textureGlowLocation = null;
|
||||
npc.updateHitbox();
|
||||
}
|
||||
catch(Exception ex){
|
||||
|
||||
Reference in new issue
Block a user