update textures #2

This commit is contained in:
Sen 2025-07-19 18:06:14 +02:00
parent a3ceadd0ff
commit 3c7f2cf874
Signed by: sen
GPG key ID: 3AC50A6F47D1B722
62 changed files with 83 additions and 99 deletions

View file

@ -30,9 +30,8 @@ public abstract class ModelBakery
"blocks/destroy_stage_2", "blocks/destroy_stage_3",
"blocks/destroy_stage_4", "blocks/destroy_stage_5",
"blocks/destroy_stage_6", "blocks/destroy_stage_7",
"blocks/destroy_stage_8", "blocks/destroy_stage_9",
"items/empty_armor_slot_helmet", "items/empty_armor_slot_chestplate",
"items/empty_armor_slot_leggings", "items/empty_armor_slot_boots");
"blocks/destroy_stage_8", "blocks/destroy_stage_9"
);
protected static final String MISSING = "builtin/missing";
public static final ModelBlock MODEL_GENERATED = (ModelBlock)new ModelBlock(null).add().d("");
public static final ModelBlock MODEL_ENTITY = (ModelBlock)new ModelBlock(null).add().d("");

View file

@ -49,7 +49,7 @@ public class RenderHorse extends RenderLiving<EntityHorse>
*/
protected String getEntityTexture(EntityHorse entity)
{
if (!entity.func_110239_cn())
if (!entity.hasSpecificTexture())
{
switch (entity.getHorseType())
{
@ -66,15 +66,15 @@ public class RenderHorse extends RenderLiving<EntityHorse>
}
else
{
return this.func_110848_b(entity);
return this.loadHorseTexture(entity);
}
}
private String func_110848_b(EntityHorse horse)
private String loadHorseTexture(EntityHorse horse)
{
String s = horse.getHorseTexture();
if (!horse.func_175507_cI())
if (!horse.hasValidTexture())
{
return null;
}

View file

@ -124,12 +124,12 @@ public class ModelHorse extends ModelBase
this.setBoxRotation(this.head, 0.5235988F, 0.0F, 0.0F);
this.field_178711_b = new ModelRenderer(this, 24, 18);
this.field_178711_b.addBox(-2.0F, -10.0F, -7.0F, 4, 3, 6);
this.field_178711_b.setRotationPoint(0.0F, 3.95F, -10.0F);
this.setBoxRotation(this.field_178711_b, 0.5235988F, 0.0F, 0.0F);
this.field_178711_b.setRotationPoint(0.0F, 0.02F, 0.02F);
this.setBoxRotation(this.field_178711_b, 0.0F, 0.0F, 0.0F);
this.field_178712_c = new ModelRenderer(this, 24, 27);
this.field_178712_c.addBox(-2.0F, -7.0F, -6.5F, 4, 2, 5);
this.field_178712_c.setRotationPoint(0.0F, 4.0F, -10.0F);
this.setBoxRotation(this.field_178712_c, 0.5235988F, 0.0F, 0.0F);
this.field_178712_c.setRotationPoint(0.0F, 0.0F, 0.0F);
this.setBoxRotation(this.field_178712_c, 0.0F, 0.0F, 0.0F);
this.head.addChild(this.field_178711_b);
this.head.addChild(this.field_178712_c);
this.horseLeftEar = new ModelRenderer(this, 0, 0);
@ -211,14 +211,14 @@ public class ModelHorse extends ModelBase
public void render(Entity entityIn, float p_78088_2_, float p_78088_3_, float p_78088_4_, float p_78088_5_, float p_78088_6_, float scale)
{
EntityHorse entityhorse = (EntityHorse)entityIn;
int i = entityhorse.getHorseType();
float f = entityhorse.getGrassEatingAmount(0.0F);
boolean flag = entityhorse.isAdultHorse();
boolean flag1 = flag && entityhorse.isHorseSaddled();
boolean flag2 = flag && entityhorse.isChested();
int i = entityhorse == null ? 0 : entityhorse.getHorseType();
float f = entityhorse == null ? 0.0f :entityhorse.getGrassEatingAmount(0.0F);
boolean flag = entityhorse == null || entityhorse.isAdultHorse();
boolean flag1 = flag && (entityhorse == null || entityhorse.isHorseSaddled());
boolean flag2 = flag && entityhorse != null && entityhorse.isChested();
boolean flag3 = i == 1 || i == 2;
float f1 = entityhorse.getHorseSize();
boolean flag4 = entityhorse.passenger != null;
float f1 = entityhorse == null ? 0.5f : entityhorse.getHorseSize();
boolean flag4 = entityhorse != null && entityhorse.passenger != null;
if (flag1)
{

View file

@ -2,15 +2,19 @@ package client.renderer.tileentity;
import org.lwjgl.opengl.GL11;
import client.Client;
import client.renderer.GlState;
import client.renderer.layers.LayerArmor;
import client.renderer.model.ModelHorse;
import common.block.tech.BlockChest;
import common.block.tile.BlockSign;
import common.block.tile.BlockStandingSign;
import common.entity.types.EntityLiving;
import common.init.ItemRegistry;
import common.item.ItemStack;
import common.item.block.ItemSign;
import common.item.tool.ItemArmor;
import common.item.tool.ItemHorseArmor;
import common.tileentity.TileEntityChest;
import common.tileentity.TileEntitySign;
import common.util.Facing;
@ -46,15 +50,18 @@ public class TileEntityItemStackRenderer {
return ((ItemArmor)TileEntityItemStackRenderer.this.stack.getItem()).armorType.getIndex() == armorSlot ? TileEntityItemStackRenderer.this.stack : null;
}
};
private final ModelHorse horse = new ModelHorse();
public void renderByItem(ItemStack stack) {
if(stack.getItem() != null && stack.getItem().getBlock() instanceof BlockChest chest) {
this.state = chest.getState().withProperty(BlockChest.FACING, Facing.SOUTH);
TileEntityRendererDispatcher.instance.renderTileEntityAt(this.chest, 0.0D, 0.0D, 0.0D, 0.0F);
this.state = null;
}
else if(stack.getItem() instanceof ItemSign sign) {
this.state = sign.getBlock().getState().withProperty(BlockStandingSign.ROTATION, 8);
TileEntityRendererDispatcher.instance.renderTileEntityAt(this.sign, 0.0D, 0.0D, 0.0D, 0.0F);
this.state = null;
}
else if(stack.getItem() instanceof ItemArmor armor) {
this.stack = stack;
@ -84,6 +91,21 @@ public class TileEntityItemStackRenderer {
if(cull)
GlState.enableCull();
GL11.glPopMatrix();
this.stack = null;
}
else if(stack.getItem() instanceof ItemHorseArmor horseArmor) {
GL11.glPushMatrix();
GL11.glTranslatef(0.9f, 0.5f, 0.0f);
GL11.glRotatef(180.0f, 0.0f, 1.0f, 0.0f);
GL11.glScalef(0.85f, -0.85f, 0.85f);
boolean cull = GlState.isCullEnabled();
if(cull)
GlState.disableCull();
Client.CLIENT.getTextureManager().bindTexture("textures/armor/" + horseArmor.getArmorTexture() + "_horse.png");
this.horse.render(null, 0, 0, 0, 0, 0, 0.0625F);
if(cull)
GlState.enableCull();
GL11.glPopMatrix();
}
}
}

View file

Before

Width:  |  Height:  |  Size: 5.1 KiB

After

Width:  |  Height:  |  Size: 5.1 KiB

Before After
Before After

View file

Before

Width:  |  Height:  |  Size: 5 KiB

After

Width:  |  Height:  |  Size: 5 KiB

Before After
Before After

View file

Before

Width:  |  Height:  |  Size: 4.9 KiB

After

Width:  |  Height:  |  Size: 4.9 KiB

Before After
Before After

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 163 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 193 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 169 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 166 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 182 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 154 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 175 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 140 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 461 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 136 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 111 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 112 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 110 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 102 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 154 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 175 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 141 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 430 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 136 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 154 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 172 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 141 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 404 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 136 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.3 KiB