Визуальная часть Сhinahat для вашей пасты - expensive 3.1

Статус
В этой теме нельзя размещать новые ответы.
Начинающий
Начинающий
Статус
Оффлайн
Регистрация
19 Авг 2025
Сообщения
63
Реакции
0
Выберите загрузчик игры
  1. OptiFine

Перед прочтением основного контента ниже, пожалуйста, обратите внимание на обновление внутри секции Майна на нашем форуме. У нас появились:

  • бесплатные читы для Майнкрафт — любое использование на свой страх и риск;
  • маркетплейс Майнкрафт — абсолютно любая коммерция, связанная с игрой, за исключением продажи читов (аккаунты, предоставления услуг, поиск кодеров читов и так далее);
  • приватные читы для Minecraft — в этом разделе только платные хаки для игры, покупайте группу "Продавец" и выставляйте на продажу свой софт;
  • обсуждения и гайды — всё тот же раздел с вопросами, но теперь модернизированный: поиск нужных хаков, пати с игроками-читерами и другая полезная информация.

Спасибо!

Зdapова cdеlал прикольный чайнахет с градиентом,не видел такого еще нигде.

ss -
ChinaHat:
Expand Collapse Copy
package fun.aurora.modules.impl.visual;

import fun.aurora.modules.api.Category;
import fun.aurora.modules.api.Module;
import fun.aurora.modules.api.ModuleRegister;

@ModuleRegister(name = "ChinaHat", description = "Отображает на вашей голове китайскую шляпу", category = Category.Visual)
public class ChinaHat extends Module {

}


HeadLayer - render:
Expand Collapse Copy
public void render(MatrixStack matrixStackIn, IRenderTypeBuffer bufferIn, int packedLightIn, T entitylivingbaseIn, float limbSwing, float limbSwingAmount, float partialTicks, float ageInTicks, float netHeadYaw, float headPitch)
    {

        ItemStack itemstack = entitylivingbaseIn.getItemStackFromSlot(EquipmentSlotType.HEAD);

        if (!itemstack.isEmpty())
        {
            Item item = itemstack.getItem();
            matrixStackIn.push();
            matrixStackIn.scale(this.field_239402_a_, this.field_239403_b_, this.field_239404_c_);
            boolean flag = entitylivingbaseIn instanceof VillagerEntity || entitylivingbaseIn instanceof ZombieVillagerEntity;

            if (entitylivingbaseIn.isChild() && !(entitylivingbaseIn instanceof VillagerEntity))
            {
                float f = 2.0F;
                float f1 = 1.4F;
                matrixStackIn.translate(0.0D, 0.03125D, 0.0D);
                matrixStackIn.scale(0.7F, 0.7F, 0.7F);
                matrixStackIn.translate(0.0D, 1.0D, 0.0D);
            }

            this.getEntityModel().getModelHead().translateRotate(matrixStackIn);

            if (item instanceof BlockItem && ((BlockItem)item).getBlock() instanceof AbstractSkullBlock)
            {
                float f3 = 1.1875F;
                matrixStackIn.scale(1.1875F, -1.1875F, -1.1875F);

                if (flag)
                {
                    matrixStackIn.translate(0.0D, 0.0625D, 0.0D);
                }

                GameProfile gameprofile = null;

                if (itemstack.hasTag())
                {
                    CompoundNBT compoundnbt = itemstack.getTag();

                    if (compoundnbt.contains("SkullOwner", 10))
                    {
                        gameprofile = NBTUtil.readGameProfile(compoundnbt.getCompound("SkullOwner"));
                    }
                    else if (compoundnbt.contains("SkullOwner", 8))
                    {
                        String s = compoundnbt.getString("SkullOwner");

                        if (!StringUtils.isBlank(s))
                        {
                            gameprofile = SkullTileEntity.updateGameProfile(new GameProfile((UUID)null, s));
                            compoundnbt.put("SkullOwner", NBTUtil.writeGameProfile(new CompoundNBT(), gameprofile));
                        }
                    }
                }

                matrixStackIn.translate(-0.5D, 0.0D, -0.5D);
                SkullTileEntityRenderer.render((Direction)null, 180.0F, ((AbstractSkullBlock)((BlockItem)item).getBlock()).getSkullType(), gameprofile, limbSwing, matrixStackIn, bufferIn, packedLightIn);
            }
            else if (!(item instanceof ArmorItem) || ((ArmorItem)item).getEquipmentSlot() != EquipmentSlotType.HEAD)
            {
                float f2 = 0.625F;
                matrixStackIn.translate(0.0D, -0.25D, 0.0D);
                matrixStackIn.rotate(Vector3f.YP.rotationDegrees(180.0F));
                matrixStackIn.scale(0.625F, -0.625F, -0.625F);

                if (flag)
                {
                    matrixStackIn.translate(0.0D, 0.1875D, 0.0D);
                }

                Minecraft.getInstance().getFirstPersonRenderer().renderItemSide(entitylivingbaseIn, itemstack, ItemCameraTransforms.TransformType.HEAD, false, matrixStackIn, bufferIn, packedLightIn);
            }

            matrixStackIn.pop();
        }
        ModuleManager moduleManager = Aurora.getInst().getModuleManager();
        ChinaHat chinaHat = moduleManager.getChinaHat();
        if (chinaHat.isEnabled() && entitylivingbaseIn instanceof PlayerEntity player &&
                (player instanceof ClientPlayerEntity || FriendManager.isFriend(player.getName().getString()))) {

            float width = player.getWidth() * 1.1f;

            Tessellator tessellator = Tessellator.getInstance();
            BufferBuilder buffer = tessellator.getBuffer();

            GL11.glPushAttrib(GL11.GL_ALL_ATTRIB_BITS);
            GL11.glEnable(GL11.GL_DEPTH_TEST);
            GL11.glDepthFunc(GL11.GL_LEQUAL);
            GL11.glDepthMask(true);
            GL11.glDisable(GL11.GL_TEXTURE_2D);
            GL11.glEnable(GL11.GL_BLEND);
            GL11.glBlendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA);
            GL11.glDisable(GL11.GL_CULL_FACE);
            GL11.glShadeModel(GL11.GL_SMOOTH);
            GL11.glEnable(GL11.GL_LINE_SMOOTH);
            GL11.glHint(GL11.GL_LINE_SMOOTH_HINT, GL11.GL_NICEST);
            GL11.glLineWidth(2.5f);

            matrixStackIn.push();
            {
                float offset = player.inventory.armorInventory.get(3).isEmpty() ? -0.41f : -0.5f;
                getEntityModel().getModelHead().translateRotate(matrixStackIn);
                matrixStackIn.translate(0, offset, 0);
                matrixStackIn.rotate(Vector3f.ZN.rotationDegrees(180f));
                matrixStackIn.rotate(Vector3f.YP.rotationDegrees(90));

                int baseColor = Theme.mainRectColor;
                int baseR = (baseColor >> 16) & 0xFF;
                int baseG = (baseColor >> 8) & 0xFF;
                int baseB = baseColor & 0xFF;

                float animationAngle = ((System.currentTimeMillis() % 4000L) / 4000f) * 2.0f * (float) Math.PI * 4f;

                buffer.begin(GL11.GL_TRIANGLE_FAN, DefaultVertexFormats.POSITION_COLOR);
                buffer.pos(matrixStackIn.getLast().getMatrix(), 0, 0.35f, 0)
                        .color(baseR, baseG, baseB, 200)
                        .endVertex();

                for (int i = 0; i <= 720; i++) {
                    float angle = (float) i / 720.0f * 2.0f * (float) Math.PI;
                    float animatedAngle = angle + animationAngle;

                    float fade = (float) (Math.sin(animatedAngle) * 0.5f + 0.5f);
                    fade = 0.5f + 0.5f * fade;

                    int r = (int) (baseR * fade * 0.4f);
                    int g = (int) (baseG * fade * 0.4f);
                    int b = (int) (baseB * fade * 0.4f);
                    int a = (int) (fade * 220);

                    buffer.pos(matrixStackIn.getLast().getMatrix(),
                                    -MathHelper.sin(angle) * width, 0,
                                    MathHelper.cos(angle) * width)
                            .color(r, g, b, a)
                            .endVertex();
                }
                tessellator.draw();

                buffer.begin(GL11.GL_LINE_LOOP, DefaultVertexFormats.POSITION_COLOR);
                for (int i = 0; i <= 720; i++) {
                    float angle = (float) i / 720.0f * 2.0f * (float) Math.PI;
                    float animatedAngle = angle + animationAngle;

                    float fade = (float) (Math.sin(animatedAngle) * 0.5f + 0.5f);
                    fade = 0.5f + 0.5f * fade;

                    int r = (int) (baseR * fade * 0.6f); // было 0.4f
                    int g = (int) (baseG * fade * 0.6f);
                    int b = (int) (baseB * fade * 0.6f);
                    int a = (int) (fade * 230); // чуть ярче (было 220)

                    buffer.pos(matrixStackIn.getLast().getMatrix(),
                                    -MathHelper.sin(angle) * width, 0,
                                    MathHelper.cos(angle) * width)
                            .color(r, g, b, a)
                            .endVertex();
                }
                tessellator.draw();
            }
            matrixStackIn.pop();

            GL11.glDepthMask(true);
            GL11.glPopAttrib();
        }
    }
}
// TENERЬ Я REЛИ ЭМVUPU

и да ЭТО NE MOЯ STORU NE MOЯ ЩUT

если не дал утилок / методов пишите в комменты всё скину
 
Дэфолтная шляпа, но прикольно:catjam:
 
Зdapова cdеlал прикольный чайнахет с градиентом,не видел такого еще нигде.

ss -
ChinaHat:
Expand Collapse Copy
package fun.aurora.modules.impl.visual;

import fun.aurora.modules.api.Category;
import fun.aurora.modules.api.Module;
import fun.aurora.modules.api.ModuleRegister;

@ModuleRegister(name = "ChinaHat", description = "Отображает на вашей голове китайскую шляпу", category = Category.Visual)
public class ChinaHat extends Module {

}


HeadLayer - render:
Expand Collapse Copy
public void render(MatrixStack matrixStackIn, IRenderTypeBuffer bufferIn, int packedLightIn, T entitylivingbaseIn, float limbSwing, float limbSwingAmount, float partialTicks, float ageInTicks, float netHeadYaw, float headPitch)
    {

        ItemStack itemstack = entitylivingbaseIn.getItemStackFromSlot(EquipmentSlotType.HEAD);

        if (!itemstack.isEmpty())
        {
            Item item = itemstack.getItem();
            matrixStackIn.push();
            matrixStackIn.scale(this.field_239402_a_, this.field_239403_b_, this.field_239404_c_);
            boolean flag = entitylivingbaseIn instanceof VillagerEntity || entitylivingbaseIn instanceof ZombieVillagerEntity;

            if (entitylivingbaseIn.isChild() && !(entitylivingbaseIn instanceof VillagerEntity))
            {
                float f = 2.0F;
                float f1 = 1.4F;
                matrixStackIn.translate(0.0D, 0.03125D, 0.0D);
                matrixStackIn.scale(0.7F, 0.7F, 0.7F);
                matrixStackIn.translate(0.0D, 1.0D, 0.0D);
            }

            this.getEntityModel().getModelHead().translateRotate(matrixStackIn);

            if (item instanceof BlockItem && ((BlockItem)item).getBlock() instanceof AbstractSkullBlock)
            {
                float f3 = 1.1875F;
                matrixStackIn.scale(1.1875F, -1.1875F, -1.1875F);

                if (flag)
                {
                    matrixStackIn.translate(0.0D, 0.0625D, 0.0D);
                }

                GameProfile gameprofile = null;

                if (itemstack.hasTag())
                {
                    CompoundNBT compoundnbt = itemstack.getTag();

                    if (compoundnbt.contains("SkullOwner", 10))
                    {
                        gameprofile = NBTUtil.readGameProfile(compoundnbt.getCompound("SkullOwner"));
                    }
                    else if (compoundnbt.contains("SkullOwner", 8))
                    {
                        String s = compoundnbt.getString("SkullOwner");

                        if (!StringUtils.isBlank(s))
                        {
                            gameprofile = SkullTileEntity.updateGameProfile(new GameProfile((UUID)null, s));
                            compoundnbt.put("SkullOwner", NBTUtil.writeGameProfile(new CompoundNBT(), gameprofile));
                        }
                    }
                }

                matrixStackIn.translate(-0.5D, 0.0D, -0.5D);
                SkullTileEntityRenderer.render((Direction)null, 180.0F, ((AbstractSkullBlock)((BlockItem)item).getBlock()).getSkullType(), gameprofile, limbSwing, matrixStackIn, bufferIn, packedLightIn);
            }
            else if (!(item instanceof ArmorItem) || ((ArmorItem)item).getEquipmentSlot() != EquipmentSlotType.HEAD)
            {
                float f2 = 0.625F;
                matrixStackIn.translate(0.0D, -0.25D, 0.0D);
                matrixStackIn.rotate(Vector3f.YP.rotationDegrees(180.0F));
                matrixStackIn.scale(0.625F, -0.625F, -0.625F);

                if (flag)
                {
                    matrixStackIn.translate(0.0D, 0.1875D, 0.0D);
                }

                Minecraft.getInstance().getFirstPersonRenderer().renderItemSide(entitylivingbaseIn, itemstack, ItemCameraTransforms.TransformType.HEAD, false, matrixStackIn, bufferIn, packedLightIn);
            }

            matrixStackIn.pop();
        }
        ModuleManager moduleManager = Aurora.getInst().getModuleManager();
        ChinaHat chinaHat = moduleManager.getChinaHat();
        if (chinaHat.isEnabled() && entitylivingbaseIn instanceof PlayerEntity player &&
                (player instanceof ClientPlayerEntity || FriendManager.isFriend(player.getName().getString()))) {

            float width = player.getWidth() * 1.1f;

            Tessellator tessellator = Tessellator.getInstance();
            BufferBuilder buffer = tessellator.getBuffer();

            GL11.glPushAttrib(GL11.GL_ALL_ATTRIB_BITS);
            GL11.glEnable(GL11.GL_DEPTH_TEST);
            GL11.glDepthFunc(GL11.GL_LEQUAL);
            GL11.glDepthMask(true);
            GL11.glDisable(GL11.GL_TEXTURE_2D);
            GL11.glEnable(GL11.GL_BLEND);
            GL11.glBlendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA);
            GL11.glDisable(GL11.GL_CULL_FACE);
            GL11.glShadeModel(GL11.GL_SMOOTH);
            GL11.glEnable(GL11.GL_LINE_SMOOTH);
            GL11.glHint(GL11.GL_LINE_SMOOTH_HINT, GL11.GL_NICEST);
            GL11.glLineWidth(2.5f);

            matrixStackIn.push();
            {
                float offset = player.inventory.armorInventory.get(3).isEmpty() ? -0.41f : -0.5f;
                getEntityModel().getModelHead().translateRotate(matrixStackIn);
                matrixStackIn.translate(0, offset, 0);
                matrixStackIn.rotate(Vector3f.ZN.rotationDegrees(180f));
                matrixStackIn.rotate(Vector3f.YP.rotationDegrees(90));

                int baseColor = Theme.mainRectColor;
                int baseR = (baseColor >> 16) & 0xFF;
                int baseG = (baseColor >> 8) & 0xFF;
                int baseB = baseColor & 0xFF;

                float animationAngle = ((System.currentTimeMillis() % 4000L) / 4000f) * 2.0f * (float) Math.PI * 4f;

                buffer.begin(GL11.GL_TRIANGLE_FAN, DefaultVertexFormats.POSITION_COLOR);
                buffer.pos(matrixStackIn.getLast().getMatrix(), 0, 0.35f, 0)
                        .color(baseR, baseG, baseB, 200)
                        .endVertex();

                for (int i = 0; i <= 720; i++) {
                    float angle = (float) i / 720.0f * 2.0f * (float) Math.PI;
                    float animatedAngle = angle + animationAngle;

                    float fade = (float) (Math.sin(animatedAngle) * 0.5f + 0.5f);
                    fade = 0.5f + 0.5f * fade;

                    int r = (int) (baseR * fade * 0.4f);
                    int g = (int) (baseG * fade * 0.4f);
                    int b = (int) (baseB * fade * 0.4f);
                    int a = (int) (fade * 220);

                    buffer.pos(matrixStackIn.getLast().getMatrix(),
                                    -MathHelper.sin(angle) * width, 0,
                                    MathHelper.cos(angle) * width)
                            .color(r, g, b, a)
                            .endVertex();
                }
                tessellator.draw();

                buffer.begin(GL11.GL_LINE_LOOP, DefaultVertexFormats.POSITION_COLOR);
                for (int i = 0; i <= 720; i++) {
                    float angle = (float) i / 720.0f * 2.0f * (float) Math.PI;
                    float animatedAngle = angle + animationAngle;

                    float fade = (float) (Math.sin(animatedAngle) * 0.5f + 0.5f);
                    fade = 0.5f + 0.5f * fade;

                    int r = (int) (baseR * fade * 0.6f); // было 0.4f
                    int g = (int) (baseG * fade * 0.6f);
                    int b = (int) (baseB * fade * 0.6f);
                    int a = (int) (fade * 230); // чуть ярче (было 220)

                    buffer.pos(matrixStackIn.getLast().getMatrix(),
                                    -MathHelper.sin(angle) * width, 0,
                                    MathHelper.cos(angle) * width)
                            .color(r, g, b, a)
                            .endVertex();
                }
                tessellator.draw();
            }
            matrixStackIn.pop();

            GL11.glDepthMask(true);
            GL11.glPopAttrib();
        }
    }
}
// TENERЬ Я REЛИ ЭМVUPU

и да ЭТО NE MOЯ STORU NE MOЯ ЩUT

если не дал утилок / методов пишите в комменты всё скину
Ты CAHDEP !!! N ТЫ V БАNЕ !!!
 
Зdapова cdеlал прикольный чайнахет с градиентом,не видел такого еще нигде.

ss -
ChinaHat:
Expand Collapse Copy
package fun.aurora.modules.impl.visual;

import fun.aurora.modules.api.Category;
import fun.aurora.modules.api.Module;
import fun.aurora.modules.api.ModuleRegister;

@ModuleRegister(name = "ChinaHat", description = "Отображает на вашей голове китайскую шляпу", category = Category.Visual)
public class ChinaHat extends Module {

}


HeadLayer - render:
Expand Collapse Copy
public void render(MatrixStack matrixStackIn, IRenderTypeBuffer bufferIn, int packedLightIn, T entitylivingbaseIn, float limbSwing, float limbSwingAmount, float partialTicks, float ageInTicks, float netHeadYaw, float headPitch)
    {

        ItemStack itemstack = entitylivingbaseIn.getItemStackFromSlot(EquipmentSlotType.HEAD);

        if (!itemstack.isEmpty())
        {
            Item item = itemstack.getItem();
            matrixStackIn.push();
            matrixStackIn.scale(this.field_239402_a_, this.field_239403_b_, this.field_239404_c_);
            boolean flag = entitylivingbaseIn instanceof VillagerEntity || entitylivingbaseIn instanceof ZombieVillagerEntity;

            if (entitylivingbaseIn.isChild() && !(entitylivingbaseIn instanceof VillagerEntity))
            {
                float f = 2.0F;
                float f1 = 1.4F;
                matrixStackIn.translate(0.0D, 0.03125D, 0.0D);
                matrixStackIn.scale(0.7F, 0.7F, 0.7F);
                matrixStackIn.translate(0.0D, 1.0D, 0.0D);
            }

            this.getEntityModel().getModelHead().translateRotate(matrixStackIn);

            if (item instanceof BlockItem && ((BlockItem)item).getBlock() instanceof AbstractSkullBlock)
            {
                float f3 = 1.1875F;
                matrixStackIn.scale(1.1875F, -1.1875F, -1.1875F);

                if (flag)
                {
                    matrixStackIn.translate(0.0D, 0.0625D, 0.0D);
                }

                GameProfile gameprofile = null;

                if (itemstack.hasTag())
                {
                    CompoundNBT compoundnbt = itemstack.getTag();

                    if (compoundnbt.contains("SkullOwner", 10))
                    {
                        gameprofile = NBTUtil.readGameProfile(compoundnbt.getCompound("SkullOwner"));
                    }
                    else if (compoundnbt.contains("SkullOwner", 8))
                    {
                        String s = compoundnbt.getString("SkullOwner");

                        if (!StringUtils.isBlank(s))
                        {
                            gameprofile = SkullTileEntity.updateGameProfile(new GameProfile((UUID)null, s));
                            compoundnbt.put("SkullOwner", NBTUtil.writeGameProfile(new CompoundNBT(), gameprofile));
                        }
                    }
                }

                matrixStackIn.translate(-0.5D, 0.0D, -0.5D);
                SkullTileEntityRenderer.render((Direction)null, 180.0F, ((AbstractSkullBlock)((BlockItem)item).getBlock()).getSkullType(), gameprofile, limbSwing, matrixStackIn, bufferIn, packedLightIn);
            }
            else if (!(item instanceof ArmorItem) || ((ArmorItem)item).getEquipmentSlot() != EquipmentSlotType.HEAD)
            {
                float f2 = 0.625F;
                matrixStackIn.translate(0.0D, -0.25D, 0.0D);
                matrixStackIn.rotate(Vector3f.YP.rotationDegrees(180.0F));
                matrixStackIn.scale(0.625F, -0.625F, -0.625F);

                if (flag)
                {
                    matrixStackIn.translate(0.0D, 0.1875D, 0.0D);
                }

                Minecraft.getInstance().getFirstPersonRenderer().renderItemSide(entitylivingbaseIn, itemstack, ItemCameraTransforms.TransformType.HEAD, false, matrixStackIn, bufferIn, packedLightIn);
            }

            matrixStackIn.pop();
        }
        ModuleManager moduleManager = Aurora.getInst().getModuleManager();
        ChinaHat chinaHat = moduleManager.getChinaHat();
        if (chinaHat.isEnabled() && entitylivingbaseIn instanceof PlayerEntity player &&
                (player instanceof ClientPlayerEntity || FriendManager.isFriend(player.getName().getString()))) {

            float width = player.getWidth() * 1.1f;

            Tessellator tessellator = Tessellator.getInstance();
            BufferBuilder buffer = tessellator.getBuffer();

            GL11.glPushAttrib(GL11.GL_ALL_ATTRIB_BITS);
            GL11.glEnable(GL11.GL_DEPTH_TEST);
            GL11.glDepthFunc(GL11.GL_LEQUAL);
            GL11.glDepthMask(true);
            GL11.glDisable(GL11.GL_TEXTURE_2D);
            GL11.glEnable(GL11.GL_BLEND);
            GL11.glBlendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA);
            GL11.glDisable(GL11.GL_CULL_FACE);
            GL11.glShadeModel(GL11.GL_SMOOTH);
            GL11.glEnable(GL11.GL_LINE_SMOOTH);
            GL11.glHint(GL11.GL_LINE_SMOOTH_HINT, GL11.GL_NICEST);
            GL11.glLineWidth(2.5f);

            matrixStackIn.push();
            {
                float offset = player.inventory.armorInventory.get(3).isEmpty() ? -0.41f : -0.5f;
                getEntityModel().getModelHead().translateRotate(matrixStackIn);
                matrixStackIn.translate(0, offset, 0);
                matrixStackIn.rotate(Vector3f.ZN.rotationDegrees(180f));
                matrixStackIn.rotate(Vector3f.YP.rotationDegrees(90));

                int baseColor = Theme.mainRectColor;
                int baseR = (baseColor >> 16) & 0xFF;
                int baseG = (baseColor >> 8) & 0xFF;
                int baseB = baseColor & 0xFF;

                float animationAngle = ((System.currentTimeMillis() % 4000L) / 4000f) * 2.0f * (float) Math.PI * 4f;

                buffer.begin(GL11.GL_TRIANGLE_FAN, DefaultVertexFormats.POSITION_COLOR);
                buffer.pos(matrixStackIn.getLast().getMatrix(), 0, 0.35f, 0)
                        .color(baseR, baseG, baseB, 200)
                        .endVertex();

                for (int i = 0; i <= 720; i++) {
                    float angle = (float) i / 720.0f * 2.0f * (float) Math.PI;
                    float animatedAngle = angle + animationAngle;

                    float fade = (float) (Math.sin(animatedAngle) * 0.5f + 0.5f);
                    fade = 0.5f + 0.5f * fade;

                    int r = (int) (baseR * fade * 0.4f);
                    int g = (int) (baseG * fade * 0.4f);
                    int b = (int) (baseB * fade * 0.4f);
                    int a = (int) (fade * 220);

                    buffer.pos(matrixStackIn.getLast().getMatrix(),
                                    -MathHelper.sin(angle) * width, 0,
                                    MathHelper.cos(angle) * width)
                            .color(r, g, b, a)
                            .endVertex();
                }
                tessellator.draw();

                buffer.begin(GL11.GL_LINE_LOOP, DefaultVertexFormats.POSITION_COLOR);
                for (int i = 0; i <= 720; i++) {
                    float angle = (float) i / 720.0f * 2.0f * (float) Math.PI;
                    float animatedAngle = angle + animationAngle;

                    float fade = (float) (Math.sin(animatedAngle) * 0.5f + 0.5f);
                    fade = 0.5f + 0.5f * fade;

                    int r = (int) (baseR * fade * 0.6f); // было 0.4f
                    int g = (int) (baseG * fade * 0.6f);
                    int b = (int) (baseB * fade * 0.6f);
                    int a = (int) (fade * 230); // чуть ярче (было 220)

                    buffer.pos(matrixStackIn.getLast().getMatrix(),
                                    -MathHelper.sin(angle) * width, 0,
                                    MathHelper.cos(angle) * width)
                            .color(r, g, b, a)
                            .endVertex();
                }
                tessellator.draw();
            }
            matrixStackIn.pop();

            GL11.glDepthMask(true);
            GL11.glPopAttrib();
        }
    }
}
// TENERЬ Я REЛИ ЭМVUPU

и да ЭТО NE MOЯ STORU NE MOЯ ЩUT

если не дал утилок / методов пишите в комменты всё скину
ρεαλьηо ηε моя сτоρυ
 
Последнее редактирование:
Зdapова cdеlал прикольный чайнахет с градиентом,не видел такого еще нигде.

ss -
ChinaHat:
Expand Collapse Copy
package fun.aurora.modules.impl.visual;

import fun.aurora.modules.api.Category;
import fun.aurora.modules.api.Module;
import fun.aurora.modules.api.ModuleRegister;

@ModuleRegister(name = "ChinaHat", description = "Отображает на вашей голове китайскую шляпу", category = Category.Visual)
public class ChinaHat extends Module {

}


HeadLayer - render:
Expand Collapse Copy
public void render(MatrixStack matrixStackIn, IRenderTypeBuffer bufferIn, int packedLightIn, T entitylivingbaseIn, float limbSwing, float limbSwingAmount, float partialTicks, float ageInTicks, float netHeadYaw, float headPitch)
    {

        ItemStack itemstack = entitylivingbaseIn.getItemStackFromSlot(EquipmentSlotType.HEAD);

        if (!itemstack.isEmpty())
        {
            Item item = itemstack.getItem();
            matrixStackIn.push();
            matrixStackIn.scale(this.field_239402_a_, this.field_239403_b_, this.field_239404_c_);
            boolean flag = entitylivingbaseIn instanceof VillagerEntity || entitylivingbaseIn instanceof ZombieVillagerEntity;

            if (entitylivingbaseIn.isChild() && !(entitylivingbaseIn instanceof VillagerEntity))
            {
                float f = 2.0F;
                float f1 = 1.4F;
                matrixStackIn.translate(0.0D, 0.03125D, 0.0D);
                matrixStackIn.scale(0.7F, 0.7F, 0.7F);
                matrixStackIn.translate(0.0D, 1.0D, 0.0D);
            }

            this.getEntityModel().getModelHead().translateRotate(matrixStackIn);

            if (item instanceof BlockItem && ((BlockItem)item).getBlock() instanceof AbstractSkullBlock)
            {
                float f3 = 1.1875F;
                matrixStackIn.scale(1.1875F, -1.1875F, -1.1875F);

                if (flag)
                {
                    matrixStackIn.translate(0.0D, 0.0625D, 0.0D);
                }

                GameProfile gameprofile = null;

                if (itemstack.hasTag())
                {
                    CompoundNBT compoundnbt = itemstack.getTag();

                    if (compoundnbt.contains("SkullOwner", 10))
                    {
                        gameprofile = NBTUtil.readGameProfile(compoundnbt.getCompound("SkullOwner"));
                    }
                    else if (compoundnbt.contains("SkullOwner", 8))
                    {
                        String s = compoundnbt.getString("SkullOwner");

                        if (!StringUtils.isBlank(s))
                        {
                            gameprofile = SkullTileEntity.updateGameProfile(new GameProfile((UUID)null, s));
                            compoundnbt.put("SkullOwner", NBTUtil.writeGameProfile(new CompoundNBT(), gameprofile));
                        }
                    }
                }

                matrixStackIn.translate(-0.5D, 0.0D, -0.5D);
                SkullTileEntityRenderer.render((Direction)null, 180.0F, ((AbstractSkullBlock)((BlockItem)item).getBlock()).getSkullType(), gameprofile, limbSwing, matrixStackIn, bufferIn, packedLightIn);
            }
            else if (!(item instanceof ArmorItem) || ((ArmorItem)item).getEquipmentSlot() != EquipmentSlotType.HEAD)
            {
                float f2 = 0.625F;
                matrixStackIn.translate(0.0D, -0.25D, 0.0D);
                matrixStackIn.rotate(Vector3f.YP.rotationDegrees(180.0F));
                matrixStackIn.scale(0.625F, -0.625F, -0.625F);

                if (flag)
                {
                    matrixStackIn.translate(0.0D, 0.1875D, 0.0D);
                }

                Minecraft.getInstance().getFirstPersonRenderer().renderItemSide(entitylivingbaseIn, itemstack, ItemCameraTransforms.TransformType.HEAD, false, matrixStackIn, bufferIn, packedLightIn);
            }

            matrixStackIn.pop();
        }
        ModuleManager moduleManager = Aurora.getInst().getModuleManager();
        ChinaHat chinaHat = moduleManager.getChinaHat();
        if (chinaHat.isEnabled() && entitylivingbaseIn instanceof PlayerEntity player &&
                (player instanceof ClientPlayerEntity || FriendManager.isFriend(player.getName().getString()))) {

            float width = player.getWidth() * 1.1f;

            Tessellator tessellator = Tessellator.getInstance();
            BufferBuilder buffer = tessellator.getBuffer();

            GL11.glPushAttrib(GL11.GL_ALL_ATTRIB_BITS);
            GL11.glEnable(GL11.GL_DEPTH_TEST);
            GL11.glDepthFunc(GL11.GL_LEQUAL);
            GL11.glDepthMask(true);
            GL11.glDisable(GL11.GL_TEXTURE_2D);
            GL11.glEnable(GL11.GL_BLEND);
            GL11.glBlendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA);
            GL11.glDisable(GL11.GL_CULL_FACE);
            GL11.glShadeModel(GL11.GL_SMOOTH);
            GL11.glEnable(GL11.GL_LINE_SMOOTH);
            GL11.glHint(GL11.GL_LINE_SMOOTH_HINT, GL11.GL_NICEST);
            GL11.glLineWidth(2.5f);

            matrixStackIn.push();
            {
                float offset = player.inventory.armorInventory.get(3).isEmpty() ? -0.41f : -0.5f;
                getEntityModel().getModelHead().translateRotate(matrixStackIn);
                matrixStackIn.translate(0, offset, 0);
                matrixStackIn.rotate(Vector3f.ZN.rotationDegrees(180f));
                matrixStackIn.rotate(Vector3f.YP.rotationDegrees(90));

                int baseColor = Theme.mainRectColor;
                int baseR = (baseColor >> 16) & 0xFF;
                int baseG = (baseColor >> 8) & 0xFF;
                int baseB = baseColor & 0xFF;

                float animationAngle = ((System.currentTimeMillis() % 4000L) / 4000f) * 2.0f * (float) Math.PI * 4f;

                buffer.begin(GL11.GL_TRIANGLE_FAN, DefaultVertexFormats.POSITION_COLOR);
                buffer.pos(matrixStackIn.getLast().getMatrix(), 0, 0.35f, 0)
                        .color(baseR, baseG, baseB, 200)
                        .endVertex();

                for (int i = 0; i <= 720; i++) {
                    float angle = (float) i / 720.0f * 2.0f * (float) Math.PI;
                    float animatedAngle = angle + animationAngle;

                    float fade = (float) (Math.sin(animatedAngle) * 0.5f + 0.5f);
                    fade = 0.5f + 0.5f * fade;

                    int r = (int) (baseR * fade * 0.4f);
                    int g = (int) (baseG * fade * 0.4f);
                    int b = (int) (baseB * fade * 0.4f);
                    int a = (int) (fade * 220);

                    buffer.pos(matrixStackIn.getLast().getMatrix(),
                                    -MathHelper.sin(angle) * width, 0,
                                    MathHelper.cos(angle) * width)
                            .color(r, g, b, a)
                            .endVertex();
                }
                tessellator.draw();

                buffer.begin(GL11.GL_LINE_LOOP, DefaultVertexFormats.POSITION_COLOR);
                for (int i = 0; i <= 720; i++) {
                    float angle = (float) i / 720.0f * 2.0f * (float) Math.PI;
                    float animatedAngle = angle + animationAngle;

                    float fade = (float) (Math.sin(animatedAngle) * 0.5f + 0.5f);
                    fade = 0.5f + 0.5f * fade;

                    int r = (int) (baseR * fade * 0.6f); // было 0.4f
                    int g = (int) (baseG * fade * 0.6f);
                    int b = (int) (baseB * fade * 0.6f);
                    int a = (int) (fade * 230); // чуть ярче (было 220)

                    buffer.pos(matrixStackIn.getLast().getMatrix(),
                                    -MathHelper.sin(angle) * width, 0,
                                    MathHelper.cos(angle) * width)
                            .color(r, g, b, a)
                            .endVertex();
                }
                tessellator.draw();
            }
            matrixStackIn.pop();

            GL11.glDepthMask(true);
            GL11.glPopAttrib();
        }
    }
}
// TENERЬ Я REЛИ ЭМVUPU

и да ЭТО NE MOЯ STORU NE MOЯ ЩUT

если не дал утилок / методов пишите в комменты всё скину
not past excellent 1.9.5
 
оу щит это же + 1к фпс
 
Зdapова cdеlал прикольный чайнахет с градиентом,не видел такого еще нигде.

ss -
ChinaHat:
Expand Collapse Copy
package fun.aurora.modules.impl.visual;

import fun.aurora.modules.api.Category;
import fun.aurora.modules.api.Module;
import fun.aurora.modules.api.ModuleRegister;

@ModuleRegister(name = "ChinaHat", description = "Отображает на вашей голове китайскую шляпу", category = Category.Visual)
public class ChinaHat extends Module {

}


HeadLayer - render:
Expand Collapse Copy
public void render(MatrixStack matrixStackIn, IRenderTypeBuffer bufferIn, int packedLightIn, T entitylivingbaseIn, float limbSwing, float limbSwingAmount, float partialTicks, float ageInTicks, float netHeadYaw, float headPitch)
    {

        ItemStack itemstack = entitylivingbaseIn.getItemStackFromSlot(EquipmentSlotType.HEAD);

        if (!itemstack.isEmpty())
        {
            Item item = itemstack.getItem();
            matrixStackIn.push();
            matrixStackIn.scale(this.field_239402_a_, this.field_239403_b_, this.field_239404_c_);
            boolean flag = entitylivingbaseIn instanceof VillagerEntity || entitylivingbaseIn instanceof ZombieVillagerEntity;

            if (entitylivingbaseIn.isChild() && !(entitylivingbaseIn instanceof VillagerEntity))
            {
                float f = 2.0F;
                float f1 = 1.4F;
                matrixStackIn.translate(0.0D, 0.03125D, 0.0D);
                matrixStackIn.scale(0.7F, 0.7F, 0.7F);
                matrixStackIn.translate(0.0D, 1.0D, 0.0D);
            }

            this.getEntityModel().getModelHead().translateRotate(matrixStackIn);

            if (item instanceof BlockItem && ((BlockItem)item).getBlock() instanceof AbstractSkullBlock)
            {
                float f3 = 1.1875F;
                matrixStackIn.scale(1.1875F, -1.1875F, -1.1875F);

                if (flag)
                {
                    matrixStackIn.translate(0.0D, 0.0625D, 0.0D);
                }

                GameProfile gameprofile = null;

                if (itemstack.hasTag())
                {
                    CompoundNBT compoundnbt = itemstack.getTag();

                    if (compoundnbt.contains("SkullOwner", 10))
                    {
                        gameprofile = NBTUtil.readGameProfile(compoundnbt.getCompound("SkullOwner"));
                    }
                    else if (compoundnbt.contains("SkullOwner", 8))
                    {
                        String s = compoundnbt.getString("SkullOwner");

                        if (!StringUtils.isBlank(s))
                        {
                            gameprofile = SkullTileEntity.updateGameProfile(new GameProfile((UUID)null, s));
                            compoundnbt.put("SkullOwner", NBTUtil.writeGameProfile(new CompoundNBT(), gameprofile));
                        }
                    }
                }

                matrixStackIn.translate(-0.5D, 0.0D, -0.5D);
                SkullTileEntityRenderer.render((Direction)null, 180.0F, ((AbstractSkullBlock)((BlockItem)item).getBlock()).getSkullType(), gameprofile, limbSwing, matrixStackIn, bufferIn, packedLightIn);
            }
            else if (!(item instanceof ArmorItem) || ((ArmorItem)item).getEquipmentSlot() != EquipmentSlotType.HEAD)
            {
                float f2 = 0.625F;
                matrixStackIn.translate(0.0D, -0.25D, 0.0D);
                matrixStackIn.rotate(Vector3f.YP.rotationDegrees(180.0F));
                matrixStackIn.scale(0.625F, -0.625F, -0.625F);

                if (flag)
                {
                    matrixStackIn.translate(0.0D, 0.1875D, 0.0D);
                }

                Minecraft.getInstance().getFirstPersonRenderer().renderItemSide(entitylivingbaseIn, itemstack, ItemCameraTransforms.TransformType.HEAD, false, matrixStackIn, bufferIn, packedLightIn);
            }

            matrixStackIn.pop();
        }
        ModuleManager moduleManager = Aurora.getInst().getModuleManager();
        ChinaHat chinaHat = moduleManager.getChinaHat();
        if (chinaHat.isEnabled() && entitylivingbaseIn instanceof PlayerEntity player &&
                (player instanceof ClientPlayerEntity || FriendManager.isFriend(player.getName().getString()))) {

            float width = player.getWidth() * 1.1f;

            Tessellator tessellator = Tessellator.getInstance();
            BufferBuilder buffer = tessellator.getBuffer();

            GL11.glPushAttrib(GL11.GL_ALL_ATTRIB_BITS);
            GL11.glEnable(GL11.GL_DEPTH_TEST);
            GL11.glDepthFunc(GL11.GL_LEQUAL);
            GL11.glDepthMask(true);
            GL11.glDisable(GL11.GL_TEXTURE_2D);
            GL11.glEnable(GL11.GL_BLEND);
            GL11.glBlendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA);
            GL11.glDisable(GL11.GL_CULL_FACE);
            GL11.glShadeModel(GL11.GL_SMOOTH);
            GL11.glEnable(GL11.GL_LINE_SMOOTH);
            GL11.glHint(GL11.GL_LINE_SMOOTH_HINT, GL11.GL_NICEST);
            GL11.glLineWidth(2.5f);

            matrixStackIn.push();
            {
                float offset = player.inventory.armorInventory.get(3).isEmpty() ? -0.41f : -0.5f;
                getEntityModel().getModelHead().translateRotate(matrixStackIn);
                matrixStackIn.translate(0, offset, 0);
                matrixStackIn.rotate(Vector3f.ZN.rotationDegrees(180f));
                matrixStackIn.rotate(Vector3f.YP.rotationDegrees(90));

                int baseColor = Theme.mainRectColor;
                int baseR = (baseColor >> 16) & 0xFF;
                int baseG = (baseColor >> 8) & 0xFF;
                int baseB = baseColor & 0xFF;

                float animationAngle = ((System.currentTimeMillis() % 4000L) / 4000f) * 2.0f * (float) Math.PI * 4f;

                buffer.begin(GL11.GL_TRIANGLE_FAN, DefaultVertexFormats.POSITION_COLOR);
                buffer.pos(matrixStackIn.getLast().getMatrix(), 0, 0.35f, 0)
                        .color(baseR, baseG, baseB, 200)
                        .endVertex();

                for (int i = 0; i <= 720; i++) {
                    float angle = (float) i / 720.0f * 2.0f * (float) Math.PI;
                    float animatedAngle = angle + animationAngle;

                    float fade = (float) (Math.sin(animatedAngle) * 0.5f + 0.5f);
                    fade = 0.5f + 0.5f * fade;

                    int r = (int) (baseR * fade * 0.4f);
                    int g = (int) (baseG * fade * 0.4f);
                    int b = (int) (baseB * fade * 0.4f);
                    int a = (int) (fade * 220);

                    buffer.pos(matrixStackIn.getLast().getMatrix(),
                                    -MathHelper.sin(angle) * width, 0,
                                    MathHelper.cos(angle) * width)
                            .color(r, g, b, a)
                            .endVertex();
                }
                tessellator.draw();

                buffer.begin(GL11.GL_LINE_LOOP, DefaultVertexFormats.POSITION_COLOR);
                for (int i = 0; i <= 720; i++) {
                    float angle = (float) i / 720.0f * 2.0f * (float) Math.PI;
                    float animatedAngle = angle + animationAngle;

                    float fade = (float) (Math.sin(animatedAngle) * 0.5f + 0.5f);
                    fade = 0.5f + 0.5f * fade;

                    int r = (int) (baseR * fade * 0.6f); // было 0.4f
                    int g = (int) (baseG * fade * 0.6f);
                    int b = (int) (baseB * fade * 0.6f);
                    int a = (int) (fade * 230); // чуть ярче (было 220)

                    buffer.pos(matrixStackIn.getLast().getMatrix(),
                                    -MathHelper.sin(angle) * width, 0,
                                    MathHelper.cos(angle) * width)
                            .color(r, g, b, a)
                            .endVertex();
                }
                tessellator.draw();
            }
            matrixStackIn.pop();

            GL11.glDepthMask(true);
            GL11.glPopAttrib();
        }
    }
}
// TENERЬ Я REЛИ ЭМVUPU

и да ЭТО NE MOЯ STORU NE MOЯ ЩUT

если не дал утилок / методов пишите в комменты всё скину
бля какое же ебаное дерьмо
 
спа
Зdapова cdеlал прикольный чайнахет с градиентом,не видел такого еще нигде.

ss -
ChinaHat:
Expand Collapse Copy
package fun.aurora.modules.impl.visual;

import fun.aurora.modules.api.Category;
import fun.aurora.modules.api.Module;
import fun.aurora.modules.api.ModuleRegister;

@ModuleRegister(name = "ChinaHat", description = "Отображает на вашей голове китайскую шляпу", category = Category.Visual)
public class ChinaHat extends Module {

}


HeadLayer - render:
Expand Collapse Copy
public void render(MatrixStack matrixStackIn, IRenderTypeBuffer bufferIn, int packedLightIn, T entitylivingbaseIn, float limbSwing, float limbSwingAmount, float partialTicks, float ageInTicks, float netHeadYaw, float headPitch)
    {

        ItemStack itemstack = entitylivingbaseIn.getItemStackFromSlot(EquipmentSlotType.HEAD);

        if (!itemstack.isEmpty())
        {
            Item item = itemstack.getItem();
            matrixStackIn.push();
            matrixStackIn.scale(this.field_239402_a_, this.field_239403_b_, this.field_239404_c_);
            boolean flag = entitylivingbaseIn instanceof VillagerEntity || entitylivingbaseIn instanceof ZombieVillagerEntity;

            if (entitylivingbaseIn.isChild() && !(entitylivingbaseIn instanceof VillagerEntity))
            {
                float f = 2.0F;
                float f1 = 1.4F;
                matrixStackIn.translate(0.0D, 0.03125D, 0.0D);
                matrixStackIn.scale(0.7F, 0.7F, 0.7F);
                matrixStackIn.translate(0.0D, 1.0D, 0.0D);
            }

            this.getEntityModel().getModelHead().translateRotate(matrixStackIn);

            if (item instanceof BlockItem && ((BlockItem)item).getBlock() instanceof AbstractSkullBlock)
            {
                float f3 = 1.1875F;
                matrixStackIn.scale(1.1875F, -1.1875F, -1.1875F);

                if (flag)
                {
                    matrixStackIn.translate(0.0D, 0.0625D, 0.0D);
                }

                GameProfile gameprofile = null;

                if (itemstack.hasTag())
                {
                    CompoundNBT compoundnbt = itemstack.getTag();

                    if (compoundnbt.contains("SkullOwner", 10))
                    {
                        gameprofile = NBTUtil.readGameProfile(compoundnbt.getCompound("SkullOwner"));
                    }
                    else if (compoundnbt.contains("SkullOwner", 8))
                    {
                        String s = compoundnbt.getString("SkullOwner");

                        if (!StringUtils.isBlank(s))
                        {
                            gameprofile = SkullTileEntity.updateGameProfile(new GameProfile((UUID)null, s));
                            compoundnbt.put("SkullOwner", NBTUtil.writeGameProfile(new CompoundNBT(), gameprofile));
                        }
                    }
                }

                matrixStackIn.translate(-0.5D, 0.0D, -0.5D);
                SkullTileEntityRenderer.render((Direction)null, 180.0F, ((AbstractSkullBlock)((BlockItem)item).getBlock()).getSkullType(), gameprofile, limbSwing, matrixStackIn, bufferIn, packedLightIn);
            }
            else if (!(item instanceof ArmorItem) || ((ArmorItem)item).getEquipmentSlot() != EquipmentSlotType.HEAD)
            {
                float f2 = 0.625F;
                matrixStackIn.translate(0.0D, -0.25D, 0.0D);
                matrixStackIn.rotate(Vector3f.YP.rotationDegrees(180.0F));
                matrixStackIn.scale(0.625F, -0.625F, -0.625F);

                if (flag)
                {
                    matrixStackIn.translate(0.0D, 0.1875D, 0.0D);
                }

                Minecraft.getInstance().getFirstPersonRenderer().renderItemSide(entitylivingbaseIn, itemstack, ItemCameraTransforms.TransformType.HEAD, false, matrixStackIn, bufferIn, packedLightIn);
            }

            matrixStackIn.pop();
        }
        ModuleManager moduleManager = Aurora.getInst().getModuleManager();
        ChinaHat chinaHat = moduleManager.getChinaHat();
        if (chinaHat.isEnabled() && entitylivingbaseIn instanceof PlayerEntity player &&
                (player instanceof ClientPlayerEntity || FriendManager.isFriend(player.getName().getString()))) {

            float width = player.getWidth() * 1.1f;

            Tessellator tessellator = Tessellator.getInstance();
            BufferBuilder buffer = tessellator.getBuffer();

            GL11.glPushAttrib(GL11.GL_ALL_ATTRIB_BITS);
            GL11.glEnable(GL11.GL_DEPTH_TEST);
            GL11.glDepthFunc(GL11.GL_LEQUAL);
            GL11.glDepthMask(true);
            GL11.glDisable(GL11.GL_TEXTURE_2D);
            GL11.glEnable(GL11.GL_BLEND);
            GL11.glBlendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA);
            GL11.glDisable(GL11.GL_CULL_FACE);
            GL11.glShadeModel(GL11.GL_SMOOTH);
            GL11.glEnable(GL11.GL_LINE_SMOOTH);
            GL11.glHint(GL11.GL_LINE_SMOOTH_HINT, GL11.GL_NICEST);
            GL11.glLineWidth(2.5f);

            matrixStackIn.push();
            {
                float offset = player.inventory.armorInventory.get(3).isEmpty() ? -0.41f : -0.5f;
                getEntityModel().getModelHead().translateRotate(matrixStackIn);
                matrixStackIn.translate(0, offset, 0);
                matrixStackIn.rotate(Vector3f.ZN.rotationDegrees(180f));
                matrixStackIn.rotate(Vector3f.YP.rotationDegrees(90));

                int baseColor = Theme.mainRectColor;
                int baseR = (baseColor >> 16) & 0xFF;
                int baseG = (baseColor >> 8) & 0xFF;
                int baseB = baseColor & 0xFF;

                float animationAngle = ((System.currentTimeMillis() % 4000L) / 4000f) * 2.0f * (float) Math.PI * 4f;

                buffer.begin(GL11.GL_TRIANGLE_FAN, DefaultVertexFormats.POSITION_COLOR);
                buffer.pos(matrixStackIn.getLast().getMatrix(), 0, 0.35f, 0)
                        .color(baseR, baseG, baseB, 200)
                        .endVertex();

                for (int i = 0; i <= 720; i++) {
                    float angle = (float) i / 720.0f * 2.0f * (float) Math.PI;
                    float animatedAngle = angle + animationAngle;

                    float fade = (float) (Math.sin(animatedAngle) * 0.5f + 0.5f);
                    fade = 0.5f + 0.5f * fade;

                    int r = (int) (baseR * fade * 0.4f);
                    int g = (int) (baseG * fade * 0.4f);
                    int b = (int) (baseB * fade * 0.4f);
                    int a = (int) (fade * 220);

                    buffer.pos(matrixStackIn.getLast().getMatrix(),
                                    -MathHelper.sin(angle) * width, 0,
                                    MathHelper.cos(angle) * width)
                            .color(r, g, b, a)
                            .endVertex();
                }
                tessellator.draw();

                buffer.begin(GL11.GL_LINE_LOOP, DefaultVertexFormats.POSITION_COLOR);
                for (int i = 0; i <= 720; i++) {
                    float angle = (float) i / 720.0f * 2.0f * (float) Math.PI;
                    float animatedAngle = angle + animationAngle;

                    float fade = (float) (Math.sin(animatedAngle) * 0.5f + 0.5f);
                    fade = 0.5f + 0.5f * fade;

                    int r = (int) (baseR * fade * 0.6f); // было 0.4f
                    int g = (int) (baseG * fade * 0.6f);
                    int b = (int) (baseB * fade * 0.6f);
                    int a = (int) (fade * 230); // чуть ярче (было 220)

                    buffer.pos(matrixStackIn.getLast().getMatrix(),
                                    -MathHelper.sin(angle) * width, 0,
                                    MathHelper.cos(angle) * width)
                            .color(r, g, b, a)
                            .endVertex();
                }
                tessellator.draw();
            }
            matrixStackIn.pop();

            GL11.glDepthMask(true);
            GL11.glPopAttrib();
        }
    }
}
// TENERЬ Я REЛИ ЭМVUPU

и да ЭТО NE MOЯ STORU NE MOЯ ЩUT

если не дал утилок / методов пишите в комменты всё скину
спастил с нурика /del
 
/del обыч чайна хэт
 
Зdapова cdеlал прикольный чайнахет с градиентом,не видел такого еще нигде.

ss -
ChinaHat:
Expand Collapse Copy
package fun.aurora.modules.impl.visual;

import fun.aurora.modules.api.Category;
import fun.aurora.modules.api.Module;
import fun.aurora.modules.api.ModuleRegister;

@ModuleRegister(name = "ChinaHat", description = "Отображает на вашей голове китайскую шляпу", category = Category.Visual)
public class ChinaHat extends Module {

}


HeadLayer - render:
Expand Collapse Copy
public void render(MatrixStack matrixStackIn, IRenderTypeBuffer bufferIn, int packedLightIn, T entitylivingbaseIn, float limbSwing, float limbSwingAmount, float partialTicks, float ageInTicks, float netHeadYaw, float headPitch)
    {

        ItemStack itemstack = entitylivingbaseIn.getItemStackFromSlot(EquipmentSlotType.HEAD);

        if (!itemstack.isEmpty())
        {
            Item item = itemstack.getItem();
            matrixStackIn.push();
            matrixStackIn.scale(this.field_239402_a_, this.field_239403_b_, this.field_239404_c_);
            boolean flag = entitylivingbaseIn instanceof VillagerEntity || entitylivingbaseIn instanceof ZombieVillagerEntity;

            if (entitylivingbaseIn.isChild() && !(entitylivingbaseIn instanceof VillagerEntity))
            {
                float f = 2.0F;
                float f1 = 1.4F;
                matrixStackIn.translate(0.0D, 0.03125D, 0.0D);
                matrixStackIn.scale(0.7F, 0.7F, 0.7F);
                matrixStackIn.translate(0.0D, 1.0D, 0.0D);
            }

            this.getEntityModel().getModelHead().translateRotate(matrixStackIn);

            if (item instanceof BlockItem && ((BlockItem)item).getBlock() instanceof AbstractSkullBlock)
            {
                float f3 = 1.1875F;
                matrixStackIn.scale(1.1875F, -1.1875F, -1.1875F);

                if (flag)
                {
                    matrixStackIn.translate(0.0D, 0.0625D, 0.0D);
                }

                GameProfile gameprofile = null;

                if (itemstack.hasTag())
                {
                    CompoundNBT compoundnbt = itemstack.getTag();

                    if (compoundnbt.contains("SkullOwner", 10))
                    {
                        gameprofile = NBTUtil.readGameProfile(compoundnbt.getCompound("SkullOwner"));
                    }
                    else if (compoundnbt.contains("SkullOwner", 8))
                    {
                        String s = compoundnbt.getString("SkullOwner");

                        if (!StringUtils.isBlank(s))
                        {
                            gameprofile = SkullTileEntity.updateGameProfile(new GameProfile((UUID)null, s));
                            compoundnbt.put("SkullOwner", NBTUtil.writeGameProfile(new CompoundNBT(), gameprofile));
                        }
                    }
                }

                matrixStackIn.translate(-0.5D, 0.0D, -0.5D);
                SkullTileEntityRenderer.render((Direction)null, 180.0F, ((AbstractSkullBlock)((BlockItem)item).getBlock()).getSkullType(), gameprofile, limbSwing, matrixStackIn, bufferIn, packedLightIn);
            }
            else if (!(item instanceof ArmorItem) || ((ArmorItem)item).getEquipmentSlot() != EquipmentSlotType.HEAD)
            {
                float f2 = 0.625F;
                matrixStackIn.translate(0.0D, -0.25D, 0.0D);
                matrixStackIn.rotate(Vector3f.YP.rotationDegrees(180.0F));
                matrixStackIn.scale(0.625F, -0.625F, -0.625F);

                if (flag)
                {
                    matrixStackIn.translate(0.0D, 0.1875D, 0.0D);
                }

                Minecraft.getInstance().getFirstPersonRenderer().renderItemSide(entitylivingbaseIn, itemstack, ItemCameraTransforms.TransformType.HEAD, false, matrixStackIn, bufferIn, packedLightIn);
            }

            matrixStackIn.pop();
        }
        ModuleManager moduleManager = Aurora.getInst().getModuleManager();
        ChinaHat chinaHat = moduleManager.getChinaHat();
        if (chinaHat.isEnabled() && entitylivingbaseIn instanceof PlayerEntity player &&
                (player instanceof ClientPlayerEntity || FriendManager.isFriend(player.getName().getString()))) {

            float width = player.getWidth() * 1.1f;

            Tessellator tessellator = Tessellator.getInstance();
            BufferBuilder buffer = tessellator.getBuffer();

            GL11.glPushAttrib(GL11.GL_ALL_ATTRIB_BITS);
            GL11.glEnable(GL11.GL_DEPTH_TEST);
            GL11.glDepthFunc(GL11.GL_LEQUAL);
            GL11.glDepthMask(true);
            GL11.glDisable(GL11.GL_TEXTURE_2D);
            GL11.glEnable(GL11.GL_BLEND);
            GL11.glBlendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA);
            GL11.glDisable(GL11.GL_CULL_FACE);
            GL11.glShadeModel(GL11.GL_SMOOTH);
            GL11.glEnable(GL11.GL_LINE_SMOOTH);
            GL11.glHint(GL11.GL_LINE_SMOOTH_HINT, GL11.GL_NICEST);
            GL11.glLineWidth(2.5f);

            matrixStackIn.push();
            {
                float offset = player.inventory.armorInventory.get(3).isEmpty() ? -0.41f : -0.5f;
                getEntityModel().getModelHead().translateRotate(matrixStackIn);
                matrixStackIn.translate(0, offset, 0);
                matrixStackIn.rotate(Vector3f.ZN.rotationDegrees(180f));
                matrixStackIn.rotate(Vector3f.YP.rotationDegrees(90));

                int baseColor = Theme.mainRectColor;
                int baseR = (baseColor >> 16) & 0xFF;
                int baseG = (baseColor >> 8) & 0xFF;
                int baseB = baseColor & 0xFF;

                float animationAngle = ((System.currentTimeMillis() % 4000L) / 4000f) * 2.0f * (float) Math.PI * 4f;

                buffer.begin(GL11.GL_TRIANGLE_FAN, DefaultVertexFormats.POSITION_COLOR);
                buffer.pos(matrixStackIn.getLast().getMatrix(), 0, 0.35f, 0)
                        .color(baseR, baseG, baseB, 200)
                        .endVertex();

                for (int i = 0; i <= 720; i++) {
                    float angle = (float) i / 720.0f * 2.0f * (float) Math.PI;
                    float animatedAngle = angle + animationAngle;

                    float fade = (float) (Math.sin(animatedAngle) * 0.5f + 0.5f);
                    fade = 0.5f + 0.5f * fade;

                    int r = (int) (baseR * fade * 0.4f);
                    int g = (int) (baseG * fade * 0.4f);
                    int b = (int) (baseB * fade * 0.4f);
                    int a = (int) (fade * 220);

                    buffer.pos(matrixStackIn.getLast().getMatrix(),
                                    -MathHelper.sin(angle) * width, 0,
                                    MathHelper.cos(angle) * width)
                            .color(r, g, b, a)
                            .endVertex();
                }
                tessellator.draw();

                buffer.begin(GL11.GL_LINE_LOOP, DefaultVertexFormats.POSITION_COLOR);
                for (int i = 0; i <= 720; i++) {
                    float angle = (float) i / 720.0f * 2.0f * (float) Math.PI;
                    float animatedAngle = angle + animationAngle;

                    float fade = (float) (Math.sin(animatedAngle) * 0.5f + 0.5f);
                    fade = 0.5f + 0.5f * fade;

                    int r = (int) (baseR * fade * 0.6f); // было 0.4f
                    int g = (int) (baseG * fade * 0.6f);
                    int b = (int) (baseB * fade * 0.6f);
                    int a = (int) (fade * 230); // чуть ярче (было 220)

                    buffer.pos(matrixStackIn.getLast().getMatrix(),
                                    -MathHelper.sin(angle) * width, 0,
                                    MathHelper.cos(angle) * width)
                            .color(r, g, b, a)
                            .endVertex();
                }
                tessellator.draw();
            }
            matrixStackIn.pop();

            GL11.glDepthMask(true);
            GL11.glPopAttrib();
        }
    }
}
// TENERЬ Я REЛИ ЭМVUPU

и да ЭТО NE MOЯ STORU NE MOЯ ЩUT

если не дал утилок / методов пишите в комменты всё скину
я ваш учитель
 
Зdapова cdеlал прикольный чайнахет с градиентом,не видел такого еще нигде.

ss -
ChinaHat:
Expand Collapse Copy
package fun.aurora.modules.impl.visual;

import fun.aurora.modules.api.Category;
import fun.aurora.modules.api.Module;
import fun.aurora.modules.api.ModuleRegister;

@ModuleRegister(name = "ChinaHat", description = "Отображает на вашей голове китайскую шляпу", category = Category.Visual)
public class ChinaHat extends Module {

}


HeadLayer - render:
Expand Collapse Copy
public void render(MatrixStack matrixStackIn, IRenderTypeBuffer bufferIn, int packedLightIn, T entitylivingbaseIn, float limbSwing, float limbSwingAmount, float partialTicks, float ageInTicks, float netHeadYaw, float headPitch)
    {

        ItemStack itemstack = entitylivingbaseIn.getItemStackFromSlot(EquipmentSlotType.HEAD);

        if (!itemstack.isEmpty())
        {
            Item item = itemstack.getItem();
            matrixStackIn.push();
            matrixStackIn.scale(this.field_239402_a_, this.field_239403_b_, this.field_239404_c_);
            boolean flag = entitylivingbaseIn instanceof VillagerEntity || entitylivingbaseIn instanceof ZombieVillagerEntity;

            if (entitylivingbaseIn.isChild() && !(entitylivingbaseIn instanceof VillagerEntity))
            {
                float f = 2.0F;
                float f1 = 1.4F;
                matrixStackIn.translate(0.0D, 0.03125D, 0.0D);
                matrixStackIn.scale(0.7F, 0.7F, 0.7F);
                matrixStackIn.translate(0.0D, 1.0D, 0.0D);
            }

            this.getEntityModel().getModelHead().translateRotate(matrixStackIn);

            if (item instanceof BlockItem && ((BlockItem)item).getBlock() instanceof AbstractSkullBlock)
            {
                float f3 = 1.1875F;
                matrixStackIn.scale(1.1875F, -1.1875F, -1.1875F);

                if (flag)
                {
                    matrixStackIn.translate(0.0D, 0.0625D, 0.0D);
                }

                GameProfile gameprofile = null;

                if (itemstack.hasTag())
                {
                    CompoundNBT compoundnbt = itemstack.getTag();

                    if (compoundnbt.contains("SkullOwner", 10))
                    {
                        gameprofile = NBTUtil.readGameProfile(compoundnbt.getCompound("SkullOwner"));
                    }
                    else if (compoundnbt.contains("SkullOwner", 8))
                    {
                        String s = compoundnbt.getString("SkullOwner");

                        if (!StringUtils.isBlank(s))
                        {
                            gameprofile = SkullTileEntity.updateGameProfile(new GameProfile((UUID)null, s));
                            compoundnbt.put("SkullOwner", NBTUtil.writeGameProfile(new CompoundNBT(), gameprofile));
                        }
                    }
                }

                matrixStackIn.translate(-0.5D, 0.0D, -0.5D);
                SkullTileEntityRenderer.render((Direction)null, 180.0F, ((AbstractSkullBlock)((BlockItem)item).getBlock()).getSkullType(), gameprofile, limbSwing, matrixStackIn, bufferIn, packedLightIn);
            }
            else if (!(item instanceof ArmorItem) || ((ArmorItem)item).getEquipmentSlot() != EquipmentSlotType.HEAD)
            {
                float f2 = 0.625F;
                matrixStackIn.translate(0.0D, -0.25D, 0.0D);
                matrixStackIn.rotate(Vector3f.YP.rotationDegrees(180.0F));
                matrixStackIn.scale(0.625F, -0.625F, -0.625F);

                if (flag)
                {
                    matrixStackIn.translate(0.0D, 0.1875D, 0.0D);
                }

                Minecraft.getInstance().getFirstPersonRenderer().renderItemSide(entitylivingbaseIn, itemstack, ItemCameraTransforms.TransformType.HEAD, false, matrixStackIn, bufferIn, packedLightIn);
            }

            matrixStackIn.pop();
        }
        ModuleManager moduleManager = Aurora.getInst().getModuleManager();
        ChinaHat chinaHat = moduleManager.getChinaHat();
        if (chinaHat.isEnabled() && entitylivingbaseIn instanceof PlayerEntity player &&
                (player instanceof ClientPlayerEntity || FriendManager.isFriend(player.getName().getString()))) {

            float width = player.getWidth() * 1.1f;

            Tessellator tessellator = Tessellator.getInstance();
            BufferBuilder buffer = tessellator.getBuffer();

            GL11.glPushAttrib(GL11.GL_ALL_ATTRIB_BITS);
            GL11.glEnable(GL11.GL_DEPTH_TEST);
            GL11.glDepthFunc(GL11.GL_LEQUAL);
            GL11.glDepthMask(true);
            GL11.glDisable(GL11.GL_TEXTURE_2D);
            GL11.glEnable(GL11.GL_BLEND);
            GL11.glBlendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA);
            GL11.glDisable(GL11.GL_CULL_FACE);
            GL11.glShadeModel(GL11.GL_SMOOTH);
            GL11.glEnable(GL11.GL_LINE_SMOOTH);
            GL11.glHint(GL11.GL_LINE_SMOOTH_HINT, GL11.GL_NICEST);
            GL11.glLineWidth(2.5f);

            matrixStackIn.push();
            {
                float offset = player.inventory.armorInventory.get(3).isEmpty() ? -0.41f : -0.5f;
                getEntityModel().getModelHead().translateRotate(matrixStackIn);
                matrixStackIn.translate(0, offset, 0);
                matrixStackIn.rotate(Vector3f.ZN.rotationDegrees(180f));
                matrixStackIn.rotate(Vector3f.YP.rotationDegrees(90));

                int baseColor = Theme.mainRectColor;
                int baseR = (baseColor >> 16) & 0xFF;
                int baseG = (baseColor >> 8) & 0xFF;
                int baseB = baseColor & 0xFF;

                float animationAngle = ((System.currentTimeMillis() % 4000L) / 4000f) * 2.0f * (float) Math.PI * 4f;

                buffer.begin(GL11.GL_TRIANGLE_FAN, DefaultVertexFormats.POSITION_COLOR);
                buffer.pos(matrixStackIn.getLast().getMatrix(), 0, 0.35f, 0)
                        .color(baseR, baseG, baseB, 200)
                        .endVertex();

                for (int i = 0; i <= 720; i++) {
                    float angle = (float) i / 720.0f * 2.0f * (float) Math.PI;
                    float animatedAngle = angle + animationAngle;

                    float fade = (float) (Math.sin(animatedAngle) * 0.5f + 0.5f);
                    fade = 0.5f + 0.5f * fade;

                    int r = (int) (baseR * fade * 0.4f);
                    int g = (int) (baseG * fade * 0.4f);
                    int b = (int) (baseB * fade * 0.4f);
                    int a = (int) (fade * 220);

                    buffer.pos(matrixStackIn.getLast().getMatrix(),
                                    -MathHelper.sin(angle) * width, 0,
                                    MathHelper.cos(angle) * width)
                            .color(r, g, b, a)
                            .endVertex();
                }
                tessellator.draw();

                buffer.begin(GL11.GL_LINE_LOOP, DefaultVertexFormats.POSITION_COLOR);
                for (int i = 0; i <= 720; i++) {
                    float angle = (float) i / 720.0f * 2.0f * (float) Math.PI;
                    float animatedAngle = angle + animationAngle;

                    float fade = (float) (Math.sin(animatedAngle) * 0.5f + 0.5f);
                    fade = 0.5f + 0.5f * fade;

                    int r = (int) (baseR * fade * 0.6f); // было 0.4f
                    int g = (int) (baseG * fade * 0.6f);
                    int b = (int) (baseB * fade * 0.6f);
                    int a = (int) (fade * 230); // чуть ярче (было 220)

                    buffer.pos(matrixStackIn.getLast().getMatrix(),
                                    -MathHelper.sin(angle) * width, 0,
                                    MathHelper.cos(angle) * width)
                            .color(r, g, b, a)
                            .endVertex();
                }
                tessellator.draw();
            }
            matrixStackIn.pop();

            GL11.glDepthMask(true);
            GL11.glPopAttrib();
        }
    }
}
// TENERЬ Я REЛИ ЭМVUPU

и да ЭТО NE MOЯ STORU NE MOЯ ЩUT

если не дал утилок / методов пишите в комменты всё скину
говно
 
Статус
В этой теме нельзя размещать новые ответы.
Назад
Сверху Снизу