Прикольный thud , expensive 3.1

  • Автор темы Автор темы chooo
  • Дата начала Дата начала
Забаненный
Забаненный
Статус
Оффлайн
Регистрация
29 Апр 2023
Сообщения
986
Реакции
16
2.6. Запрещено попрошайничество реакций, денег и так далее. К этому пункту относятся завуалированные сообщения, например: «Не откажусь от реакций», «Буду рад благодарности за проделанную работу» и т.п.
Обратите внимание, пользователь заблокирован на форуме. Не рекомендуется проводить сделки.
сделал простое вычисление проценты выигрыша а точнее 4 стадии :Tie - ничья , losing- проигрываешь,winning - выигрываешь, EZ -враг на 1 крит
(все значения можете заменить на свои,и цвет текста тоже)
Мейби где-то криво и т.д. Тут уж простите
SS -
Пожалуйста, авторизуйтесь для просмотра ссылки.


thud.java:
Expand Collapse Copy
package im.expensive.ui.display.impl;

import com.mojang.blaze3d.platform.GlStateManager;
import im.expensive.Expensive;
import im.expensive.events.EventDisplay;
import im.expensive.ui.display.ElementRenderer;
import im.expensive.ui.styles.Style;
import im.expensive.utils.animations.Animation;
import im.expensive.utils.animations.Direction;
import im.expensive.utils.animations.impl.EaseBackIn;
import im.expensive.utils.client.ClientUtil;
import im.expensive.utils.drag.Dragging;
import im.expensive.utils.math.MathUtil;
import im.expensive.utils.math.StopWatch;
import im.expensive.utils.math.Vector4i;
import im.expensive.utils.render.ColorUtils;
import im.expensive.utils.render.DisplayUtils;
import im.expensive.utils.render.KawaseBlur;
import im.expensive.utils.render.Scissor;
import im.expensive.utils.render.font.Fonts;
import lombok.AccessLevel;
import lombok.RequiredArgsConstructor;
import lombok.experimental.FieldDefaults;
import net.minecraft.client.gui.AbstractGui;
import net.minecraft.client.gui.screen.ChatScreen;
import net.minecraft.client.renderer.entity.EntityRenderer;
import net.minecraft.entity.LivingEntity;
import net.minecraft.entity.player.PlayerEntity;
import net.minecraft.scoreboard.Score;
import net.minecraft.util.ResourceLocation;
import net.minecraft.util.math.MathHelper;
import net.minecraft.util.math.vector.Vector4f;
import org.lwjgl.opengl.GL11;

@FieldDefaults(level = AccessLevel.PRIVATE)
@RequiredArgsConstructor
public class TargetInfoRenderer implements ElementRenderer {
    final StopWatch stopWatch = new StopWatch();
    final Dragging drag;
    LivingEntity entity = null;
    boolean allow;
    final Animation animation = new EaseBackIn(400, 1, 1);
    float healthAnimation = 0.0f;
    float absorptionAnimation = 0.0f;

    @Override
    public void render(EventDisplay eventDisplay) {
        entity = getTarget(entity);

        float rounding = 6;
        boolean out = !allow || stopWatch.isReached(1000);
        animation.setDuration(out ? 900 : 800);
        animation.setDirection(out ? Direction.BACKWARDS : Direction.FORWARDS);

        if (animation.getOutput() == 0.0f) {
            entity = null;
        }

        if (entity != null) {
            String name = entity.getName().getString();

            float posX = drag.getX();
            float posY = drag.getY();

            float headSize = 28;
            float spacing = 5;

            float width = 172 / 1.5f;
            float height = 59 / 1.5f;
            drag.setWidth(width);
            drag.setHeight(height);
            float shrinking = 1.5f;
            Score score = mc.world.getScoreboard().getOrCreateScore(entity.getScoreboardName(), mc.world.getScoreboard().getObjectiveInDisplaySlot(2));


            float hp = entity.getHealth();
            float maxHp = entity.getMaxHealth();
            String header = mc.ingameGUI.getTabList().header == null ? " " : mc.ingameGUI.getTabList().header.getString().toLowerCase();

            if (mc.getCurrentServerData() != null && mc.getCurrentServerData().serverIP.contains("funtime")
                    && (header.contains("анархия") || header.contains("гриферский")) && entity instanceof PlayerEntity) {
                hp = score.getScorePoints();
                maxHp = 20;
            }
            healthAnimation = MathUtil.fast(healthAnimation, MathHelper.clamp(hp / maxHp, 0, 1), 3);
            absorptionAnimation = MathUtil.fast(absorptionAnimation, MathHelper.clamp(entity.getAbsorptionAmount() / maxHp, 0, 1), 10);


            if (mc.getCurrentServerData() != null && mc.getCurrentServerData().serverIP.contains("funtime")
                    && (header.contains("анархия") || header.contains("гриферский")) && entity instanceof PlayerEntity) {
                hp = score.getScorePoints();
                maxHp = 20;
            }


            float animationValue = (float) animation.getOutput();

            float halfAnimationValueRest = (1 - animationValue) / 2f;

            float testX = posX + (width * halfAnimationValueRest);
            float testY = posY + (height * halfAnimationValueRest);
            float testW = width * animationValue;
            float testH = height * animationValue;
            int windowWidth = ClientUtil.calc(mc.getMainWindow().getScaledWidth());

            GlStateManager.pushMatrix();
            Style style = Expensive.getInstance().getStyleManager().getCurrentStyle();

            sizeAnimation(posX + (width / 2), posY + (height / 2), animation.getOutput());
            DisplayUtils.drawRoundedRect(posX, posY, width, height, rounding,ColorUtils.setAlpha( style.getSecondColor().getRGB(), 100));

            DisplayUtils.drawShadow(posX, posY, width, height, 10,ColorUtils.setAlpha( style.getSecondColor().getRGB(), 100));
            KawaseBlur.blur.updateBlur(1, 1);
            KawaseBlur.blur.render(() -> {
                drawStyledRect(posX, posY, width, height, rounding, 255);
            });

            drawTargetHead(entity, posX + spacing, posY + spacing + 1, headSize, headSize);
            Scissor.push();
            Scissor.setFromComponentCoordinates(testX, testY, testW - 6, testH);
            Fonts.sfui.drawText(eventDisplay.getMatrixStack(), entity.getName().getString(), posX + headSize + spacing + spacing, posY + spacing + 1, -1, 8);
            Fonts.sfMedium.drawText(eventDisplay.getMatrixStack(), "HP: " + ((int) hp + (int) mc.player.getAbsorptionAmount()), posX + headSize + spacing + spacing,
                    posY + spacing + 1 + spacing + spacing, ColorUtils.rgb(200, 200, 200), 7);
            if (hp <= 3) {
                Fonts.sfbold.drawCenteredText(eventDisplay.getMatrixStack(), "EZ", posX + 95, posY + height / 2.3f - 17+ Fonts.sfbold.getHeight(15.4f) + 1, ColorUtils.rgb(0, 150, 0), 6F);

            }
            if (hp == mc.player.getHealth() && !(hp <= 3)) {
                Fonts.sfbold.drawCenteredText(eventDisplay.getMatrixStack(), "Tie!", posX + 95, posY + height / 2.3f - 17 + Fonts.sfbold.getHeight(15.4f) + 1, ColorUtils.rgb(150, 150, 150), 6F);
            }
            if (hp > mc.player.getHealth() && !(hp <= 3)) {
                Fonts.sfbold.drawCenteredText(eventDisplay.getMatrixStack(), "Losing", posX + 95, posY + height / 2.3f - 17 + Fonts.sfbold.getHeight(15.4f) + 1, ColorUtils.rgb(150, 0, 0), 6F);
            } else if (hp < mc.player.getHealth() && !(hp <= 3)) {
                Fonts.sfbold.drawCenteredText(eventDisplay.getMatrixStack(), "Winning", posX + 95, posY + height / 2.3f - 17 + Fonts.sfbold.getHeight(15.4f) + 1, ColorUtils.rgb(0, 0, 150), 6F);
            }

            Scissor.unset();
            Scissor.pop();





            DisplayUtils.drawShadow(posX + headSize + spacing + spacing, posY + height - spacing * 2 - 3, (width - 42) * healthAnimation, 7, 10, ColorUtils.rgb(190,190,190));

            DisplayUtils.drawRoundedRect(posX + headSize + spacing + spacing, posY + height - spacing * 2 - 3, (width - 42) * healthAnimation, 7, 3, ColorUtils.rgb(190 ,190,190));

            GlStateManager.popMatrix();
        }
    }


    private LivingEntity getTarget(LivingEntity nullTarget) {
        LivingEntity auraTarget = Expensive.getInstance().getFunctionRegistry().getKillAura().getTarget();
        LivingEntity target = nullTarget;
        if (auraTarget != null) {
            stopWatch.reset();
            allow = true;
            target = auraTarget;
        } else if (mc.currentScreen instanceof ChatScreen) {
            stopWatch.reset();
            allow = true;
            target = mc.player;
        } else {
            allow = false;
        }
        return target;
    }

    public void drawTargetHead(LivingEntity entity, float x, float y, float width, float height) {
        if (entity != null) {
            EntityRenderer<? super LivingEntity> rendererManager = mc.getRenderManager().getRenderer(entity);
            drawFace(rendererManager.getEntityTexture(entity), x, y, 8F, 8F, 8F, 8F, width, height, 64F, 64F, entity);
        }
    }

    public static void sizeAnimation(double width, double height, double scale) {
        GlStateManager.translated(width, height, 0);
        GlStateManager.scaled(scale, scale, scale);
        GlStateManager.translated(-width, -height, 0);
    }

    public void drawFace(ResourceLocation res, float d,
                         float y,
                         float u,
                         float v,
                         float uWidth,
                         float vHeight,
                         float width,
                         float height,
                         float tileWidth,
                         float tileHeight,
                         LivingEntity target) {
        GL11.glPushMatrix();
        GL11.glEnable(GL11.GL_BLEND);
        mc.getTextureManager().bindTexture(res);
        float hurtPercent = (target.hurtTime - (target.hurtTime != 0 ? mc.timer.renderPartialTicks : 0.0f)) / 10.0f;
        GL11.glColor4f(1, 1 - hurtPercent, 1 - hurtPercent, 1);
        AbstractGui.drawScaledCustomSizeModalRect(d, y, u, v, uWidth, vHeight, width, height, tileWidth, tileHeight);
        GL11.glColor4f(1, 1, 1, 1);
        GL11.glPopMatrix();
    }

    private void drawStyledRect(float x,
                                float y,
                                float width,
                                float height,
                                float radius, int alpha) {
        Style style = Expensive.getInstance().getStyleManager().getCurrentStyle();

        DisplayUtils.drawRoundedRect(x - 0.5f, y - 0.5f, width + 1, height + 1, radius + 0.5f, ColorUtils.setAlpha(ColorUtils.getColor(0), alpha)); // outline
        DisplayUtils.drawRoundedRect(x, y, width, height, radius, ColorUtils.rgba(21, 21, 21, alpha));
    }
}
 
Последнее редактирование модератором:
Обратите внимание, пользователь заблокирован на форуме. Не рекомендуется проводить сделки.
уебищный код и выглядит как дерьмо боже пастер фейспалм ??
съебись уже с форума и не клянчи у моей залупы реакции мс 272 сообщения/2жалости?
? ? ? ? ? ? ? ? ? ? ? ? ? собираю тебе на лечение от аутизма
 
Обратите внимание, пользователь заблокирован на форуме. Не рекомендуется проводить сделки.
накиньте хороших реакций,я старался:disappointed:
сделал простое вычисление проценты выигрыша а точнее 4 стадии :Tie - ничья , losing- проигрываешь,winning - выигрываешь, EZ -враг на 1 крит
(все значения можете заменить на свои,и цвет текста тоже)
Мейби где-то криво и т.д. Тут уж простите
SS -
Пожалуйста, авторизуйтесь для просмотра ссылки.


thud.java:
Expand Collapse Copy
package im.expensive.ui.display.impl;

import com.mojang.blaze3d.platform.GlStateManager;
import im.expensive.Expensive;
import im.expensive.events.EventDisplay;
import im.expensive.ui.display.ElementRenderer;
import im.expensive.ui.styles.Style;
import im.expensive.utils.animations.Animation;
import im.expensive.utils.animations.Direction;
import im.expensive.utils.animations.impl.EaseBackIn;
import im.expensive.utils.client.ClientUtil;
import im.expensive.utils.drag.Dragging;
import im.expensive.utils.math.MathUtil;
import im.expensive.utils.math.StopWatch;
import im.expensive.utils.math.Vector4i;
import im.expensive.utils.render.ColorUtils;
import im.expensive.utils.render.DisplayUtils;
import im.expensive.utils.render.KawaseBlur;
import im.expensive.utils.render.Scissor;
import im.expensive.utils.render.font.Fonts;
import lombok.AccessLevel;
import lombok.RequiredArgsConstructor;
import lombok.experimental.FieldDefaults;
import net.minecraft.client.gui.AbstractGui;
import net.minecraft.client.gui.screen.ChatScreen;
import net.minecraft.client.renderer.entity.EntityRenderer;
import net.minecraft.entity.LivingEntity;
import net.minecraft.entity.player.PlayerEntity;
import net.minecraft.scoreboard.Score;
import net.minecraft.util.ResourceLocation;
import net.minecraft.util.math.MathHelper;
import net.minecraft.util.math.vector.Vector4f;
import org.lwjgl.opengl.GL11;

@FieldDefaults(level = AccessLevel.PRIVATE)
@RequiredArgsConstructor
public class TargetInfoRenderer implements ElementRenderer {
    final StopWatch stopWatch = new StopWatch();
    final Dragging drag;
    LivingEntity entity = null;
    boolean allow;
    final Animation animation = new EaseBackIn(400, 1, 1);
    float healthAnimation = 0.0f;
    float absorptionAnimation = 0.0f;

    @Override
    public void render(EventDisplay eventDisplay) {
        entity = getTarget(entity);

        float rounding = 6;
        boolean out = !allow || stopWatch.isReached(1000);
        animation.setDuration(out ? 900 : 800);
        animation.setDirection(out ? Direction.BACKWARDS : Direction.FORWARDS);

        if (animation.getOutput() == 0.0f) {
            entity = null;
        }

        if (entity != null) {
            String name = entity.getName().getString();

            float posX = drag.getX();
            float posY = drag.getY();

            float headSize = 28;
            float spacing = 5;

            float width = 172 / 1.5f;
            float height = 59 / 1.5f;
            drag.setWidth(width);
            drag.setHeight(height);
            float shrinking = 1.5f;
            Score score = mc.world.getScoreboard().getOrCreateScore(entity.getScoreboardName(), mc.world.getScoreboard().getObjectiveInDisplaySlot(2));


            float hp = entity.getHealth();
            float maxHp = entity.getMaxHealth();
            String header = mc.ingameGUI.getTabList().header == null ? " " : mc.ingameGUI.getTabList().header.getString().toLowerCase();

            if (mc.getCurrentServerData() != null && mc.getCurrentServerData().serverIP.contains("funtime")
                    && (header.contains("анархия") || header.contains("гриферский")) && entity instanceof PlayerEntity) {
                hp = score.getScorePoints();
                maxHp = 20;
            }
            healthAnimation = MathUtil.fast(healthAnimation, MathHelper.clamp(hp / maxHp, 0, 1), 3);
            absorptionAnimation = MathUtil.fast(absorptionAnimation, MathHelper.clamp(entity.getAbsorptionAmount() / maxHp, 0, 1), 10);


            if (mc.getCurrentServerData() != null && mc.getCurrentServerData().serverIP.contains("funtime")
                    && (header.contains("анархия") || header.contains("гриферский")) && entity instanceof PlayerEntity) {
                hp = score.getScorePoints();
                maxHp = 20;
            }


            float animationValue = (float) animation.getOutput();

            float halfAnimationValueRest = (1 - animationValue) / 2f;

            float testX = posX + (width * halfAnimationValueRest);
            float testY = posY + (height * halfAnimationValueRest);
            float testW = width * animationValue;
            float testH = height * animationValue;
            int windowWidth = ClientUtil.calc(mc.getMainWindow().getScaledWidth());

            GlStateManager.pushMatrix();
            Style style = Expensive.getInstance().getStyleManager().getCurrentStyle();

            sizeAnimation(posX + (width / 2), posY + (height / 2), animation.getOutput());
            DisplayUtils.drawRoundedRect(posX, posY, width, height, rounding,ColorUtils.setAlpha( style.getSecondColor().getRGB(), 100));

            DisplayUtils.drawShadow(posX, posY, width, height, 10,ColorUtils.setAlpha( style.getSecondColor().getRGB(), 100));
            KawaseBlur.blur.updateBlur(1, 1);
            KawaseBlur.blur.render(() -> {
                drawStyledRect(posX, posY, width, height, rounding, 255);
            });

            drawTargetHead(entity, posX + spacing, posY + spacing + 1, headSize, headSize);
            Scissor.push();
            Scissor.setFromComponentCoordinates(testX, testY, testW - 6, testH);
            Fonts.sfui.drawText(eventDisplay.getMatrixStack(), entity.getName().getString(), posX + headSize + spacing + spacing, posY + spacing + 1, -1, 8);
            Fonts.sfMedium.drawText(eventDisplay.getMatrixStack(), "HP: " + ((int) hp + (int) mc.player.getAbsorptionAmount()), posX + headSize + spacing + spacing,
                    posY + spacing + 1 + spacing + spacing, ColorUtils.rgb(200, 200, 200), 7);
            if (hp <= 3) {
                Fonts.sfbold.drawCenteredText(eventDisplay.getMatrixStack(), "EZ", posX + 95, posY + height / 2.3f - 17+ Fonts.sfbold.getHeight(15.4f) + 1, ColorUtils.rgb(0, 150, 0), 6F);

            }
            if (hp == mc.player.getHealth() && !(hp <= 3)) {
                Fonts.sfbold.drawCenteredText(eventDisplay.getMatrixStack(), "Tie!", posX + 95, posY + height / 2.3f - 17 + Fonts.sfbold.getHeight(15.4f) + 1, ColorUtils.rgb(150, 150, 150), 6F);
            }
            if (hp > mc.player.getHealth() && !(hp <= 3)) {
                Fonts.sfbold.drawCenteredText(eventDisplay.getMatrixStack(), "Losing", posX + 95, posY + height / 2.3f - 17 + Fonts.sfbold.getHeight(15.4f) + 1, ColorUtils.rgb(150, 0, 0), 6F);
            } else if (hp < mc.player.getHealth() && !(hp <= 3)) {
                Fonts.sfbold.drawCenteredText(eventDisplay.getMatrixStack(), "Winning", posX + 95, posY + height / 2.3f - 17 + Fonts.sfbold.getHeight(15.4f) + 1, ColorUtils.rgb(0, 0, 150), 6F);
            }

            Scissor.unset();
            Scissor.pop();





            DisplayUtils.drawShadow(posX + headSize + spacing + spacing, posY + height - spacing * 2 - 3, (width - 42) * healthAnimation, 7, 10, ColorUtils.rgb(190,190,190));

            DisplayUtils.drawRoundedRect(posX + headSize + spacing + spacing, posY + height - spacing * 2 - 3, (width - 42) * healthAnimation, 7, 3, ColorUtils.rgb(190 ,190,190));

            GlStateManager.popMatrix();
        }
    }


    private LivingEntity getTarget(LivingEntity nullTarget) {
        LivingEntity auraTarget = Expensive.getInstance().getFunctionRegistry().getKillAura().getTarget();
        LivingEntity target = nullTarget;
        if (auraTarget != null) {
            stopWatch.reset();
            allow = true;
            target = auraTarget;
        } else if (mc.currentScreen instanceof ChatScreen) {
            stopWatch.reset();
            allow = true;
            target = mc.player;
        } else {
            allow = false;
        }
        return target;
    }

    public void drawTargetHead(LivingEntity entity, float x, float y, float width, float height) {
        if (entity != null) {
            EntityRenderer<? super LivingEntity> rendererManager = mc.getRenderManager().getRenderer(entity);
            drawFace(rendererManager.getEntityTexture(entity), x, y, 8F, 8F, 8F, 8F, width, height, 64F, 64F, entity);
        }
    }

    public static void sizeAnimation(double width, double height, double scale) {
        GlStateManager.translated(width, height, 0);
        GlStateManager.scaled(scale, scale, scale);
        GlStateManager.translated(-width, -height, 0);
    }

    public void drawFace(ResourceLocation res, float d,
                         float y,
                         float u,
                         float v,
                         float uWidth,
                         float vHeight,
                         float width,
                         float height,
                         float tileWidth,
                         float tileHeight,
                         LivingEntity target) {
        GL11.glPushMatrix();
        GL11.glEnable(GL11.GL_BLEND);
        mc.getTextureManager().bindTexture(res);
        float hurtPercent = (target.hurtTime - (target.hurtTime != 0 ? mc.timer.renderPartialTicks : 0.0f)) / 10.0f;
        GL11.glColor4f(1, 1 - hurtPercent, 1 - hurtPercent, 1);
        AbstractGui.drawScaledCustomSizeModalRect(d, y, u, v, uWidth, vHeight, width, height, tileWidth, tileHeight);
        GL11.glColor4f(1, 1, 1, 1);
        GL11.glPopMatrix();
    }

    private void drawStyledRect(float x,
                                float y,
                                float width,
                                float height,
                                float radius, int alpha) {
        Style style = Expensive.getInstance().getStyleManager().getCurrentStyle();

        DisplayUtils.drawRoundedRect(x - 0.5f, y - 0.5f, width + 1, height + 1, radius + 0.5f, ColorUtils.setAlpha(ColorUtils.getColor(0), alpha)); // outline
        DisplayUtils.drawRoundedRect(x, y, width, height, radius, ColorUtils.rgba(21, 21, 21, alpha));
    }
}
?
 
накиньте хороших реакций,я старался:disappointed:
сделал простое вычисление проценты выигрыша а точнее 4 стадии :Tie - ничья , losing- проигрываешь,winning - выигрываешь, EZ -враг на 1 крит
(все значения можете заменить на свои,и цвет текста тоже)
Мейби где-то криво и т.д. Тут уж простите
SS -
Пожалуйста, авторизуйтесь для просмотра ссылки.


thud.java:
Expand Collapse Copy
package im.expensive.ui.display.impl;

import com.mojang.blaze3d.platform.GlStateManager;
import im.expensive.Expensive;
import im.expensive.events.EventDisplay;
import im.expensive.ui.display.ElementRenderer;
import im.expensive.ui.styles.Style;
import im.expensive.utils.animations.Animation;
import im.expensive.utils.animations.Direction;
import im.expensive.utils.animations.impl.EaseBackIn;
import im.expensive.utils.client.ClientUtil;
import im.expensive.utils.drag.Dragging;
import im.expensive.utils.math.MathUtil;
import im.expensive.utils.math.StopWatch;
import im.expensive.utils.math.Vector4i;
import im.expensive.utils.render.ColorUtils;
import im.expensive.utils.render.DisplayUtils;
import im.expensive.utils.render.KawaseBlur;
import im.expensive.utils.render.Scissor;
import im.expensive.utils.render.font.Fonts;
import lombok.AccessLevel;
import lombok.RequiredArgsConstructor;
import lombok.experimental.FieldDefaults;
import net.minecraft.client.gui.AbstractGui;
import net.minecraft.client.gui.screen.ChatScreen;
import net.minecraft.client.renderer.entity.EntityRenderer;
import net.minecraft.entity.LivingEntity;
import net.minecraft.entity.player.PlayerEntity;
import net.minecraft.scoreboard.Score;
import net.minecraft.util.ResourceLocation;
import net.minecraft.util.math.MathHelper;
import net.minecraft.util.math.vector.Vector4f;
import org.lwjgl.opengl.GL11;

@FieldDefaults(level = AccessLevel.PRIVATE)
@RequiredArgsConstructor
public class TargetInfoRenderer implements ElementRenderer {
    final StopWatch stopWatch = new StopWatch();
    final Dragging drag;
    LivingEntity entity = null;
    boolean allow;
    final Animation animation = new EaseBackIn(400, 1, 1);
    float healthAnimation = 0.0f;
    float absorptionAnimation = 0.0f;

    @Override
    public void render(EventDisplay eventDisplay) {
        entity = getTarget(entity);

        float rounding = 6;
        boolean out = !allow || stopWatch.isReached(1000);
        animation.setDuration(out ? 900 : 800);
        animation.setDirection(out ? Direction.BACKWARDS : Direction.FORWARDS);

        if (animation.getOutput() == 0.0f) {
            entity = null;
        }

        if (entity != null) {
            String name = entity.getName().getString();

            float posX = drag.getX();
            float posY = drag.getY();

            float headSize = 28;
            float spacing = 5;

            float width = 172 / 1.5f;
            float height = 59 / 1.5f;
            drag.setWidth(width);
            drag.setHeight(height);
            float shrinking = 1.5f;
            Score score = mc.world.getScoreboard().getOrCreateScore(entity.getScoreboardName(), mc.world.getScoreboard().getObjectiveInDisplaySlot(2));


            float hp = entity.getHealth();
            float maxHp = entity.getMaxHealth();
            String header = mc.ingameGUI.getTabList().header == null ? " " : mc.ingameGUI.getTabList().header.getString().toLowerCase();

            if (mc.getCurrentServerData() != null && mc.getCurrentServerData().serverIP.contains("funtime")
                    && (header.contains("анархия") || header.contains("гриферский")) && entity instanceof PlayerEntity) {
                hp = score.getScorePoints();
                maxHp = 20;
            }
            healthAnimation = MathUtil.fast(healthAnimation, MathHelper.clamp(hp / maxHp, 0, 1), 3);
            absorptionAnimation = MathUtil.fast(absorptionAnimation, MathHelper.clamp(entity.getAbsorptionAmount() / maxHp, 0, 1), 10);


            if (mc.getCurrentServerData() != null && mc.getCurrentServerData().serverIP.contains("funtime")
                    && (header.contains("анархия") || header.contains("гриферский")) && entity instanceof PlayerEntity) {
                hp = score.getScorePoints();
                maxHp = 20;
            }


            float animationValue = (float) animation.getOutput();

            float halfAnimationValueRest = (1 - animationValue) / 2f;

            float testX = posX + (width * halfAnimationValueRest);
            float testY = posY + (height * halfAnimationValueRest);
            float testW = width * animationValue;
            float testH = height * animationValue;
            int windowWidth = ClientUtil.calc(mc.getMainWindow().getScaledWidth());

            GlStateManager.pushMatrix();
            Style style = Expensive.getInstance().getStyleManager().getCurrentStyle();

            sizeAnimation(posX + (width / 2), posY + (height / 2), animation.getOutput());
            DisplayUtils.drawRoundedRect(posX, posY, width, height, rounding,ColorUtils.setAlpha( style.getSecondColor().getRGB(), 100));

            DisplayUtils.drawShadow(posX, posY, width, height, 10,ColorUtils.setAlpha( style.getSecondColor().getRGB(), 100));
            KawaseBlur.blur.updateBlur(1, 1);
            KawaseBlur.blur.render(() -> {
                drawStyledRect(posX, posY, width, height, rounding, 255);
            });

            drawTargetHead(entity, posX + spacing, posY + spacing + 1, headSize, headSize);
            Scissor.push();
            Scissor.setFromComponentCoordinates(testX, testY, testW - 6, testH);
            Fonts.sfui.drawText(eventDisplay.getMatrixStack(), entity.getName().getString(), posX + headSize + spacing + spacing, posY + spacing + 1, -1, 8);
            Fonts.sfMedium.drawText(eventDisplay.getMatrixStack(), "HP: " + ((int) hp + (int) mc.player.getAbsorptionAmount()), posX + headSize + spacing + spacing,
                    posY + spacing + 1 + spacing + spacing, ColorUtils.rgb(200, 200, 200), 7);
            if (hp <= 3) {
                Fonts.sfbold.drawCenteredText(eventDisplay.getMatrixStack(), "EZ", posX + 95, posY + height / 2.3f - 17+ Fonts.sfbold.getHeight(15.4f) + 1, ColorUtils.rgb(0, 150, 0), 6F);

            }
            if (hp == mc.player.getHealth() && !(hp <= 3)) {
                Fonts.sfbold.drawCenteredText(eventDisplay.getMatrixStack(), "Tie!", posX + 95, posY + height / 2.3f - 17 + Fonts.sfbold.getHeight(15.4f) + 1, ColorUtils.rgb(150, 150, 150), 6F);
            }
            if (hp > mc.player.getHealth() && !(hp <= 3)) {
                Fonts.sfbold.drawCenteredText(eventDisplay.getMatrixStack(), "Losing", posX + 95, posY + height / 2.3f - 17 + Fonts.sfbold.getHeight(15.4f) + 1, ColorUtils.rgb(150, 0, 0), 6F);
            } else if (hp < mc.player.getHealth() && !(hp <= 3)) {
                Fonts.sfbold.drawCenteredText(eventDisplay.getMatrixStack(), "Winning", posX + 95, posY + height / 2.3f - 17 + Fonts.sfbold.getHeight(15.4f) + 1, ColorUtils.rgb(0, 0, 150), 6F);
            }

            Scissor.unset();
            Scissor.pop();





            DisplayUtils.drawShadow(posX + headSize + spacing + spacing, posY + height - spacing * 2 - 3, (width - 42) * healthAnimation, 7, 10, ColorUtils.rgb(190,190,190));

            DisplayUtils.drawRoundedRect(posX + headSize + spacing + spacing, posY + height - spacing * 2 - 3, (width - 42) * healthAnimation, 7, 3, ColorUtils.rgb(190 ,190,190));

            GlStateManager.popMatrix();
        }
    }


    private LivingEntity getTarget(LivingEntity nullTarget) {
        LivingEntity auraTarget = Expensive.getInstance().getFunctionRegistry().getKillAura().getTarget();
        LivingEntity target = nullTarget;
        if (auraTarget != null) {
            stopWatch.reset();
            allow = true;
            target = auraTarget;
        } else if (mc.currentScreen instanceof ChatScreen) {
            stopWatch.reset();
            allow = true;
            target = mc.player;
        } else {
            allow = false;
        }
        return target;
    }

    public void drawTargetHead(LivingEntity entity, float x, float y, float width, float height) {
        if (entity != null) {
            EntityRenderer<? super LivingEntity> rendererManager = mc.getRenderManager().getRenderer(entity);
            drawFace(rendererManager.getEntityTexture(entity), x, y, 8F, 8F, 8F, 8F, width, height, 64F, 64F, entity);
        }
    }

    public static void sizeAnimation(double width, double height, double scale) {
        GlStateManager.translated(width, height, 0);
        GlStateManager.scaled(scale, scale, scale);
        GlStateManager.translated(-width, -height, 0);
    }

    public void drawFace(ResourceLocation res, float d,
                         float y,
                         float u,
                         float v,
                         float uWidth,
                         float vHeight,
                         float width,
                         float height,
                         float tileWidth,
                         float tileHeight,
                         LivingEntity target) {
        GL11.glPushMatrix();
        GL11.glEnable(GL11.GL_BLEND);
        mc.getTextureManager().bindTexture(res);
        float hurtPercent = (target.hurtTime - (target.hurtTime != 0 ? mc.timer.renderPartialTicks : 0.0f)) / 10.0f;
        GL11.glColor4f(1, 1 - hurtPercent, 1 - hurtPercent, 1);
        AbstractGui.drawScaledCustomSizeModalRect(d, y, u, v, uWidth, vHeight, width, height, tileWidth, tileHeight);
        GL11.glColor4f(1, 1, 1, 1);
        GL11.glPopMatrix();
    }

    private void drawStyledRect(float x,
                                float y,
                                float width,
                                float height,
                                float radius, int alpha) {
        Style style = Expensive.getInstance().getStyleManager().getCurrentStyle();

        DisplayUtils.drawRoundedRect(x - 0.5f, y - 0.5f, width + 1, height + 1, radius + 0.5f, ColorUtils.setAlpha(ColorUtils.getColor(0), alpha)); // outline
        DisplayUtils.drawRoundedRect(x, y, width, height, radius, ColorUtils.rgba(21, 21, 21, alpha));
    }
}
бро топчик иди в том же духе
 
Обратите внимание, пользователь заблокирован на форуме. Не рекомендуется проводить сделки.
?
 
накинуть блюра и сделать его просто програчненьким таким и вообще сок будет
 
Обратите внимание, пользователь заблокирован на форуме. Не рекомендуется проводить сделки.
мне показалось или там шадоу на блюре
 
Обратите внимание, пользователь заблокирован на форуме. Не рекомендуется проводить сделки.
Обратите внимание, пользователь заблокирован на форуме. Не рекомендуется проводить сделки.
позор говно код моя рыбка и то лучше сделает
 
позор говно код моя рыбка и то лучше сделает
ВХАХВАХВХА пастер ты хоть что то см напишешь или только все пастишь?
накиньте хороших реакций,я старался:disappointed:
сделал простое вычисление проценты выигрыша а точнее 4 стадии :Tie - ничья , losing- проигрываешь,winning - выигрываешь, EZ -враг на 1 крит
(все значения можете заменить на свои,и цвет текста тоже)
Мейби где-то криво и т.д. Тут уж простите
SS -
Пожалуйста, авторизуйтесь для просмотра ссылки.


thud.java:
Expand Collapse Copy
package im.expensive.ui.display.impl;

import com.mojang.blaze3d.platform.GlStateManager;
import im.expensive.Expensive;
import im.expensive.events.EventDisplay;
import im.expensive.ui.display.ElementRenderer;
import im.expensive.ui.styles.Style;
import im.expensive.utils.animations.Animation;
import im.expensive.utils.animations.Direction;
import im.expensive.utils.animations.impl.EaseBackIn;
import im.expensive.utils.client.ClientUtil;
import im.expensive.utils.drag.Dragging;
import im.expensive.utils.math.MathUtil;
import im.expensive.utils.math.StopWatch;
import im.expensive.utils.math.Vector4i;
import im.expensive.utils.render.ColorUtils;
import im.expensive.utils.render.DisplayUtils;
import im.expensive.utils.render.KawaseBlur;
import im.expensive.utils.render.Scissor;
import im.expensive.utils.render.font.Fonts;
import lombok.AccessLevel;
import lombok.RequiredArgsConstructor;
import lombok.experimental.FieldDefaults;
import net.minecraft.client.gui.AbstractGui;
import net.minecraft.client.gui.screen.ChatScreen;
import net.minecraft.client.renderer.entity.EntityRenderer;
import net.minecraft.entity.LivingEntity;
import net.minecraft.entity.player.PlayerEntity;
import net.minecraft.scoreboard.Score;
import net.minecraft.util.ResourceLocation;
import net.minecraft.util.math.MathHelper;
import net.minecraft.util.math.vector.Vector4f;
import org.lwjgl.opengl.GL11;

@FieldDefaults(level = AccessLevel.PRIVATE)
@RequiredArgsConstructor
public class TargetInfoRenderer implements ElementRenderer {
    final StopWatch stopWatch = new StopWatch();
    final Dragging drag;
    LivingEntity entity = null;
    boolean allow;
    final Animation animation = new EaseBackIn(400, 1, 1);
    float healthAnimation = 0.0f;
    float absorptionAnimation = 0.0f;

    @Override
    public void render(EventDisplay eventDisplay) {
        entity = getTarget(entity);

        float rounding = 6;
        boolean out = !allow || stopWatch.isReached(1000);
        animation.setDuration(out ? 900 : 800);
        animation.setDirection(out ? Direction.BACKWARDS : Direction.FORWARDS);

        if (animation.getOutput() == 0.0f) {
            entity = null;
        }

        if (entity != null) {
            String name = entity.getName().getString();

            float posX = drag.getX();
            float posY = drag.getY();

            float headSize = 28;
            float spacing = 5;

            float width = 172 / 1.5f;
            float height = 59 / 1.5f;
            drag.setWidth(width);
            drag.setHeight(height);
            float shrinking = 1.5f;
            Score score = mc.world.getScoreboard().getOrCreateScore(entity.getScoreboardName(), mc.world.getScoreboard().getObjectiveInDisplaySlot(2));


            float hp = entity.getHealth();
            float maxHp = entity.getMaxHealth();
            String header = mc.ingameGUI.getTabList().header == null ? " " : mc.ingameGUI.getTabList().header.getString().toLowerCase();

            if (mc.getCurrentServerData() != null && mc.getCurrentServerData().serverIP.contains("funtime")
                    && (header.contains("анархия") || header.contains("гриферский")) && entity instanceof PlayerEntity) {
                hp = score.getScorePoints();
                maxHp = 20;
            }
            healthAnimation = MathUtil.fast(healthAnimation, MathHelper.clamp(hp / maxHp, 0, 1), 3);
            absorptionAnimation = MathUtil.fast(absorptionAnimation, MathHelper.clamp(entity.getAbsorptionAmount() / maxHp, 0, 1), 10);


            if (mc.getCurrentServerData() != null && mc.getCurrentServerData().serverIP.contains("funtime")
                    && (header.contains("анархия") || header.contains("гриферский")) && entity instanceof PlayerEntity) {
                hp = score.getScorePoints();
                maxHp = 20;
            }


            float animationValue = (float) animation.getOutput();

            float halfAnimationValueRest = (1 - animationValue) / 2f;

            float testX = posX + (width * halfAnimationValueRest);
            float testY = posY + (height * halfAnimationValueRest);
            float testW = width * animationValue;
            float testH = height * animationValue;
            int windowWidth = ClientUtil.calc(mc.getMainWindow().getScaledWidth());

            GlStateManager.pushMatrix();
            Style style = Expensive.getInstance().getStyleManager().getCurrentStyle();

            sizeAnimation(posX + (width / 2), posY + (height / 2), animation.getOutput());
            DisplayUtils.drawRoundedRect(posX, posY, width, height, rounding,ColorUtils.setAlpha( style.getSecondColor().getRGB(), 100));

            DisplayUtils.drawShadow(posX, posY, width, height, 10,ColorUtils.setAlpha( style.getSecondColor().getRGB(), 100));
            KawaseBlur.blur.updateBlur(1, 1);
            KawaseBlur.blur.render(() -> {
                drawStyledRect(posX, posY, width, height, rounding, 255);
            });

            drawTargetHead(entity, posX + spacing, posY + spacing + 1, headSize, headSize);
            Scissor.push();
            Scissor.setFromComponentCoordinates(testX, testY, testW - 6, testH);
            Fonts.sfui.drawText(eventDisplay.getMatrixStack(), entity.getName().getString(), posX + headSize + spacing + spacing, posY + spacing + 1, -1, 8);
            Fonts.sfMedium.drawText(eventDisplay.getMatrixStack(), "HP: " + ((int) hp + (int) mc.player.getAbsorptionAmount()), posX + headSize + spacing + spacing,
                    posY + spacing + 1 + spacing + spacing, ColorUtils.rgb(200, 200, 200), 7);
            if (hp <= 3) {
                Fonts.sfbold.drawCenteredText(eventDisplay.getMatrixStack(), "EZ", posX + 95, posY + height / 2.3f - 17+ Fonts.sfbold.getHeight(15.4f) + 1, ColorUtils.rgb(0, 150, 0), 6F);

            }
            if (hp == mc.player.getHealth() && !(hp <= 3)) {
                Fonts.sfbold.drawCenteredText(eventDisplay.getMatrixStack(), "Tie!", posX + 95, posY + height / 2.3f - 17 + Fonts.sfbold.getHeight(15.4f) + 1, ColorUtils.rgb(150, 150, 150), 6F);
            }
            if (hp > mc.player.getHealth() && !(hp <= 3)) {
                Fonts.sfbold.drawCenteredText(eventDisplay.getMatrixStack(), "Losing", posX + 95, posY + height / 2.3f - 17 + Fonts.sfbold.getHeight(15.4f) + 1, ColorUtils.rgb(150, 0, 0), 6F);
            } else if (hp < mc.player.getHealth() && !(hp <= 3)) {
                Fonts.sfbold.drawCenteredText(eventDisplay.getMatrixStack(), "Winning", posX + 95, posY + height / 2.3f - 17 + Fonts.sfbold.getHeight(15.4f) + 1, ColorUtils.rgb(0, 0, 150), 6F);
            }

            Scissor.unset();
            Scissor.pop();





            DisplayUtils.drawShadow(posX + headSize + spacing + spacing, posY + height - spacing * 2 - 3, (width - 42) * healthAnimation, 7, 10, ColorUtils.rgb(190,190,190));

            DisplayUtils.drawRoundedRect(posX + headSize + spacing + spacing, posY + height - spacing * 2 - 3, (width - 42) * healthAnimation, 7, 3, ColorUtils.rgb(190 ,190,190));

            GlStateManager.popMatrix();
        }
    }


    private LivingEntity getTarget(LivingEntity nullTarget) {
        LivingEntity auraTarget = Expensive.getInstance().getFunctionRegistry().getKillAura().getTarget();
        LivingEntity target = nullTarget;
        if (auraTarget != null) {
            stopWatch.reset();
            allow = true;
            target = auraTarget;
        } else if (mc.currentScreen instanceof ChatScreen) {
            stopWatch.reset();
            allow = true;
            target = mc.player;
        } else {
            allow = false;
        }
        return target;
    }

    public void drawTargetHead(LivingEntity entity, float x, float y, float width, float height) {
        if (entity != null) {
            EntityRenderer<? super LivingEntity> rendererManager = mc.getRenderManager().getRenderer(entity);
            drawFace(rendererManager.getEntityTexture(entity), x, y, 8F, 8F, 8F, 8F, width, height, 64F, 64F, entity);
        }
    }

    public static void sizeAnimation(double width, double height, double scale) {
        GlStateManager.translated(width, height, 0);
        GlStateManager.scaled(scale, scale, scale);
        GlStateManager.translated(-width, -height, 0);
    }

    public void drawFace(ResourceLocation res, float d,
                         float y,
                         float u,
                         float v,
                         float uWidth,
                         float vHeight,
                         float width,
                         float height,
                         float tileWidth,
                         float tileHeight,
                         LivingEntity target) {
        GL11.glPushMatrix();
        GL11.glEnable(GL11.GL_BLEND);
        mc.getTextureManager().bindTexture(res);
        float hurtPercent = (target.hurtTime - (target.hurtTime != 0 ? mc.timer.renderPartialTicks : 0.0f)) / 10.0f;
        GL11.glColor4f(1, 1 - hurtPercent, 1 - hurtPercent, 1);
        AbstractGui.drawScaledCustomSizeModalRect(d, y, u, v, uWidth, vHeight, width, height, tileWidth, tileHeight);
        GL11.glColor4f(1, 1, 1, 1);
        GL11.glPopMatrix();
    }

    private void drawStyledRect(float x,
                                float y,
                                float width,
                                float height,
                                float radius, int alpha) {
        Style style = Expensive.getInstance().getStyleManager().getCurrentStyle();

        DisplayUtils.drawRoundedRect(x - 0.5f, y - 0.5f, width + 1, height + 1, radius + 0.5f, ColorUtils.setAlpha(ColorUtils.getColor(0), alpha)); // outline
        DisplayUtils.drawRoundedRect(x, y, width, height, radius, ColorUtils.rgba(21, 21, 21, alpha));
    }
}
херовое ну пойдёт
 
уебищный код и выглядит как дерьмо боже пастер фейспалм ??
съебись уже с форума и не клянчи у моей залупы реакции мс 272 сообщения/2жалости?
аутизм помогает здоровью и кодингу :roflanBuldiga:
 
заебись а, ничего не можешь бл и выписываешь
тебе то хули надо я ваще на на код отвечал :roflanPominki:
заебись а, ничего не можешь бл и выписываешь
1717494828290.png
хз могу тебе много чего показать сказать что я могу
заебись а, ничего не можешь бл и выписываешь
1717495001250.png
ладно не признал прост
 
накиньте хороших реакций,я старался:disappointed:
сделал простое вычисление проценты выигрыша а точнее 4 стадии :Tie - ничья , losing- проигрываешь,winning - выигрываешь, EZ -враг на 1 крит
(все значения можете заменить на свои,и цвет текста тоже)
Мейби где-то криво и т.д. Тут уж простите
SS -
Пожалуйста, авторизуйтесь для просмотра ссылки.


thud.java:
Expand Collapse Copy
package im.expensive.ui.display.impl;

import com.mojang.blaze3d.platform.GlStateManager;
import im.expensive.Expensive;
import im.expensive.events.EventDisplay;
import im.expensive.ui.display.ElementRenderer;
import im.expensive.ui.styles.Style;
import im.expensive.utils.animations.Animation;
import im.expensive.utils.animations.Direction;
import im.expensive.utils.animations.impl.EaseBackIn;
import im.expensive.utils.client.ClientUtil;
import im.expensive.utils.drag.Dragging;
import im.expensive.utils.math.MathUtil;
import im.expensive.utils.math.StopWatch;
import im.expensive.utils.math.Vector4i;
import im.expensive.utils.render.ColorUtils;
import im.expensive.utils.render.DisplayUtils;
import im.expensive.utils.render.KawaseBlur;
import im.expensive.utils.render.Scissor;
import im.expensive.utils.render.font.Fonts;
import lombok.AccessLevel;
import lombok.RequiredArgsConstructor;
import lombok.experimental.FieldDefaults;
import net.minecraft.client.gui.AbstractGui;
import net.minecraft.client.gui.screen.ChatScreen;
import net.minecraft.client.renderer.entity.EntityRenderer;
import net.minecraft.entity.LivingEntity;
import net.minecraft.entity.player.PlayerEntity;
import net.minecraft.scoreboard.Score;
import net.minecraft.util.ResourceLocation;
import net.minecraft.util.math.MathHelper;
import net.minecraft.util.math.vector.Vector4f;
import org.lwjgl.opengl.GL11;

@FieldDefaults(level = AccessLevel.PRIVATE)
@RequiredArgsConstructor
public class TargetInfoRenderer implements ElementRenderer {
    final StopWatch stopWatch = new StopWatch();
    final Dragging drag;
    LivingEntity entity = null;
    boolean allow;
    final Animation animation = new EaseBackIn(400, 1, 1);
    float healthAnimation = 0.0f;
    float absorptionAnimation = 0.0f;

    @Override
    public void render(EventDisplay eventDisplay) {
        entity = getTarget(entity);

        float rounding = 6;
        boolean out = !allow || stopWatch.isReached(1000);
        animation.setDuration(out ? 900 : 800);
        animation.setDirection(out ? Direction.BACKWARDS : Direction.FORWARDS);

        if (animation.getOutput() == 0.0f) {
            entity = null;
        }

        if (entity != null) {
            String name = entity.getName().getString();

            float posX = drag.getX();
            float posY = drag.getY();

            float headSize = 28;
            float spacing = 5;

            float width = 172 / 1.5f;
            float height = 59 / 1.5f;
            drag.setWidth(width);
            drag.setHeight(height);
            float shrinking = 1.5f;
            Score score = mc.world.getScoreboard().getOrCreateScore(entity.getScoreboardName(), mc.world.getScoreboard().getObjectiveInDisplaySlot(2));


            float hp = entity.getHealth();
            float maxHp = entity.getMaxHealth();
            String header = mc.ingameGUI.getTabList().header == null ? " " : mc.ingameGUI.getTabList().header.getString().toLowerCase();

            if (mc.getCurrentServerData() != null && mc.getCurrentServerData().serverIP.contains("funtime")
                    && (header.contains("анархия") || header.contains("гриферский")) && entity instanceof PlayerEntity) {
                hp = score.getScorePoints();
                maxHp = 20;
            }
            healthAnimation = MathUtil.fast(healthAnimation, MathHelper.clamp(hp / maxHp, 0, 1), 3);
            absorptionAnimation = MathUtil.fast(absorptionAnimation, MathHelper.clamp(entity.getAbsorptionAmount() / maxHp, 0, 1), 10);


            if (mc.getCurrentServerData() != null && mc.getCurrentServerData().serverIP.contains("funtime")
                    && (header.contains("анархия") || header.contains("гриферский")) && entity instanceof PlayerEntity) {
                hp = score.getScorePoints();
                maxHp = 20;
            }


            float animationValue = (float) animation.getOutput();

            float halfAnimationValueRest = (1 - animationValue) / 2f;

            float testX = posX + (width * halfAnimationValueRest);
            float testY = posY + (height * halfAnimationValueRest);
            float testW = width * animationValue;
            float testH = height * animationValue;
            int windowWidth = ClientUtil.calc(mc.getMainWindow().getScaledWidth());

            GlStateManager.pushMatrix();
            Style style = Expensive.getInstance().getStyleManager().getCurrentStyle();

            sizeAnimation(posX + (width / 2), posY + (height / 2), animation.getOutput());
            DisplayUtils.drawRoundedRect(posX, posY, width, height, rounding,ColorUtils.setAlpha( style.getSecondColor().getRGB(), 100));

            DisplayUtils.drawShadow(posX, posY, width, height, 10,ColorUtils.setAlpha( style.getSecondColor().getRGB(), 100));
            KawaseBlur.blur.updateBlur(1, 1);
            KawaseBlur.blur.render(() -> {
                drawStyledRect(posX, posY, width, height, rounding, 255);
            });

            drawTargetHead(entity, posX + spacing, posY + spacing + 1, headSize, headSize);
            Scissor.push();
            Scissor.setFromComponentCoordinates(testX, testY, testW - 6, testH);
            Fonts.sfui.drawText(eventDisplay.getMatrixStack(), entity.getName().getString(), posX + headSize + spacing + spacing, posY + spacing + 1, -1, 8);
            Fonts.sfMedium.drawText(eventDisplay.getMatrixStack(), "HP: " + ((int) hp + (int) mc.player.getAbsorptionAmount()), posX + headSize + spacing + spacing,
                    posY + spacing + 1 + spacing + spacing, ColorUtils.rgb(200, 200, 200), 7);
            if (hp <= 3) {
                Fonts.sfbold.drawCenteredText(eventDisplay.getMatrixStack(), "EZ", posX + 95, posY + height / 2.3f - 17+ Fonts.sfbold.getHeight(15.4f) + 1, ColorUtils.rgb(0, 150, 0), 6F);

            }
            if (hp == mc.player.getHealth() && !(hp <= 3)) {
                Fonts.sfbold.drawCenteredText(eventDisplay.getMatrixStack(), "Tie!", posX + 95, posY + height / 2.3f - 17 + Fonts.sfbold.getHeight(15.4f) + 1, ColorUtils.rgb(150, 150, 150), 6F);
            }
            if (hp > mc.player.getHealth() && !(hp <= 3)) {
                Fonts.sfbold.drawCenteredText(eventDisplay.getMatrixStack(), "Losing", posX + 95, posY + height / 2.3f - 17 + Fonts.sfbold.getHeight(15.4f) + 1, ColorUtils.rgb(150, 0, 0), 6F);
            } else if (hp < mc.player.getHealth() && !(hp <= 3)) {
                Fonts.sfbold.drawCenteredText(eventDisplay.getMatrixStack(), "Winning", posX + 95, posY + height / 2.3f - 17 + Fonts.sfbold.getHeight(15.4f) + 1, ColorUtils.rgb(0, 0, 150), 6F);
            }

            Scissor.unset();
            Scissor.pop();





            DisplayUtils.drawShadow(posX + headSize + spacing + spacing, posY + height - spacing * 2 - 3, (width - 42) * healthAnimation, 7, 10, ColorUtils.rgb(190,190,190));

            DisplayUtils.drawRoundedRect(posX + headSize + spacing + spacing, posY + height - spacing * 2 - 3, (width - 42) * healthAnimation, 7, 3, ColorUtils.rgb(190 ,190,190));

            GlStateManager.popMatrix();
        }
    }


    private LivingEntity getTarget(LivingEntity nullTarget) {
        LivingEntity auraTarget = Expensive.getInstance().getFunctionRegistry().getKillAura().getTarget();
        LivingEntity target = nullTarget;
        if (auraTarget != null) {
            stopWatch.reset();
            allow = true;
            target = auraTarget;
        } else if (mc.currentScreen instanceof ChatScreen) {
            stopWatch.reset();
            allow = true;
            target = mc.player;
        } else {
            allow = false;
        }
        return target;
    }

    public void drawTargetHead(LivingEntity entity, float x, float y, float width, float height) {
        if (entity != null) {
            EntityRenderer<? super LivingEntity> rendererManager = mc.getRenderManager().getRenderer(entity);
            drawFace(rendererManager.getEntityTexture(entity), x, y, 8F, 8F, 8F, 8F, width, height, 64F, 64F, entity);
        }
    }

    public static void sizeAnimation(double width, double height, double scale) {
        GlStateManager.translated(width, height, 0);
        GlStateManager.scaled(scale, scale, scale);
        GlStateManager.translated(-width, -height, 0);
    }

    public void drawFace(ResourceLocation res, float d,
                         float y,
                         float u,
                         float v,
                         float uWidth,
                         float vHeight,
                         float width,
                         float height,
                         float tileWidth,
                         float tileHeight,
                         LivingEntity target) {
        GL11.glPushMatrix();
        GL11.glEnable(GL11.GL_BLEND);
        mc.getTextureManager().bindTexture(res);
        float hurtPercent = (target.hurtTime - (target.hurtTime != 0 ? mc.timer.renderPartialTicks : 0.0f)) / 10.0f;
        GL11.glColor4f(1, 1 - hurtPercent, 1 - hurtPercent, 1);
        AbstractGui.drawScaledCustomSizeModalRect(d, y, u, v, uWidth, vHeight, width, height, tileWidth, tileHeight);
        GL11.glColor4f(1, 1, 1, 1);
        GL11.glPopMatrix();
    }

    private void drawStyledRect(float x,
                                float y,
                                float width,
                                float height,
                                float radius, int alpha) {
        Style style = Expensive.getInstance().getStyleManager().getCurrentStyle();

        DisplayUtils.drawRoundedRect(x - 0.5f, y - 0.5f, width + 1, height + 1, radius + 0.5f, ColorUtils.setAlpha(ColorUtils.getColor(0), alpha)); // outline
        DisplayUtils.drawRoundedRect(x, y, width, height, radius, ColorUtils.rgba(21, 21, 21, alpha));
    }
}
выглядит как говно да и по коду говно (у меня лучше)
P.S. я мл. кодер виссенда
 
уебищный код и выглядит как дерьмо боже пастер фейспалм ??
съебись уже с форума и не клянчи у моей залупы реакции мс 272 сообщения/2жалости?
Говорит кодер wissend'a
выглядит как говно да и по коду говно (у меня лучше)
P.S. я мл. кодер виссенда
Вы случайно не с хеливом пастите?
 
Назад
Сверху Снизу