Визуальная часть MotionGraph | Exp 3.1/Evaware

  • Автор темы Автор темы Terca
  • Дата начала Дата начала
Начинающий
Начинающий
Статус
Оффлайн
Регистрация
11 Май 2024
Сообщения
10
Реакции
0
Выберите загрузчик игры
  1. Vanilla

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

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

Спасибо!

Вижу все начали сливать и подумал тоже слить чо нет так сказать

ss -
Пожалуйста, авторизуйтесь для просмотра ссылки.

MotionGraphRenderer:
Expand Collapse Copy
package no.clips.ui.display.impl;

import no.clips.events.EventDisplay;
import no.clips.modules.impl.render.Theme;
import no.clips.ui.display.ElementRenderer;
import no.clips.utils.drag.Dragging;
import no.clips.utils.render.color.ColorUtils;
import no.clips.utils.render.font.Fonts;
import no.clips.utils.render.gl.Scissor;
import no.clips.utils.render.rect.RenderUtility;
import no.clips.modules.impl.render.HUD;
import org.lwjgl.opengl.GL11;

import java.awt.Color;
import java.util.LinkedList;

public class MotionGraphRenderer implements ElementRenderer {
    private final Dragging dragging;
    private final LinkedList<Double> speedPoints;
    private static final int MAX_POINTS = 100;
    private static final float GRAPH_WIDTH = 100;
    private static final float GRAPH_HEIGHT = 30;

    public MotionGraphRenderer(Dragging dragging) {
        this.dragging = dragging;
        this.speedPoints = new LinkedList<>();
    }

    [USER=1367676]@override[/USER]
    public void render(EventDisplay e) {
        if (mc.player == null) return;

        double xSpeed = mc.player.getPosX() - mc.player.lastTickPosX;
        double zSpeed = mc.player.getPosZ() - mc.player.lastTickPosZ;
        double currentSpeed = Math.sqrt(xSpeed * xSpeed + zSpeed * zSpeed) * 20;

        speedPoints.addLast(currentSpeed);
        if (speedPoints.size() > MAX_POINTS) {
            speedPoints.removeFirst();
        }

        float x = dragging.getX();
        float y = dragging.getY();

        drawStyledRect(x, y, GRAPH_WIDTH, GRAPH_HEIGHT, 3.5f);


        Scissor.push();
        Scissor.setFromComponentCoordinates(x + 0.5f, y + 0.5f, GRAPH_WIDTH - 1f, GRAPH_HEIGHT - 1f);

        String speedText = String.format("%.1f B/S", currentSpeed);
        float textWidth = Fonts.regular.getWidth(speedText, 7);
        float textHeight = Fonts.regular.getHeight(7);

        float centeredX = x + (GRAPH_WIDTH - textWidth) / 2;
        float centeredY = y + (GRAPH_HEIGHT - textHeight) / 2;

        Fonts.regular.drawText(e.getMatrixStack(), speedText, centeredX, centeredY, ColorUtils.setAlpha(Theme.Text(0), 100) , 7);

        int gridColor = new Color(255, 255, 255, 30).getRGB();
        for (int i = 0; i < 4; i++) {
            float gridY = y + (GRAPH_HEIGHT * i / 3);
            RenderUtility.drawRect(x, gridY, x + GRAPH_WIDTH, gridY + 0.5f, gridColor);
        }

        for (int i = 0; i < 4; i++) {
            float gridX = x + (GRAPH_WIDTH * i / 3);
            RenderUtility.drawRect(gridX, y, gridX + 0.5f, y + GRAPH_HEIGHT, gridColor);
        }

        if (speedPoints.size() > 1) {
            float lineThickness = 1.0f;
            for (int i = 0; i < speedPoints.size() - 1; i++) {
                float x1 = x + (i * GRAPH_WIDTH / MAX_POINTS);
                float x2 = x + ((i + 1) * GRAPH_WIDTH / MAX_POINTS);
                float y1 = (float) (y + GRAPH_HEIGHT - (speedPoints.get(i) * GRAPH_HEIGHT / 20));
                float y2 = (float) (y + GRAPH_HEIGHT - (speedPoints.get(i + 1) * GRAPH_HEIGHT / 20));

                float length = (float) Math.sqrt(Math.pow(x2 - x1, 2) + Math.pow(y2 - y1, 2));
                float angle = (float) Math.atan2(y2 - y1, x2 - x1);

                GL11.glPushMatrix();
                GL11.glTranslatef(x1, y1, 0);
                GL11.glRotatef((float) Math.toDegrees(angle), 0, 0, 1);
                RenderUtility.drawRect(0, -lineThickness / 2, length, lineThickness / 2, Theme.Text(0));
                GL11.glPopMatrix();
            }
        }

        dragging.setWidth(GRAPH_WIDTH);
        dragging.setHeight(GRAPH_HEIGHT);

        Scissor.unset();
        Scissor.pop();
        
        int outlineColor = ColorUtils.multDark(Theme.RectColor(0), 0.8f);
        RenderUtility.drawRoundedRectOutline(x, y, GRAPH_WIDTH, GRAPH_HEIGHT, 3.5f, 1.0f, outlineColor);
    }

    private void drawStyledRect(float x, float y, float width, float height, float radius) {
        int fillColor = ColorUtils.multDark(Theme.RectColor(0), 0.1f);
        int outlineColor = ColorUtils.multDark(Theme.RectColor(0), 0.8f);
        RenderUtility.drawRoundedRect(x, y, width, height, 4, ColorUtils.setAlpha(fillColor, 170));
        RenderUtility.drawRoundedRectOutline(x, y, width, height, 4, 1.0f, outlineColor);
    }
}
 
Обратите внимание, пользователь заблокирован на форуме. Не рекомендуется проводить сделки.
слава гифтису
 
Вижу все начали сливать и подумал тоже слить чо нет так сказать

ss -
Пожалуйста, авторизуйтесь для просмотра ссылки.

MotionGraphRenderer:
Expand Collapse Copy
package no.clips.ui.display.impl;

import no.clips.events.EventDisplay;
import no.clips.modules.impl.render.Theme;
import no.clips.ui.display.ElementRenderer;
import no.clips.utils.drag.Dragging;
import no.clips.utils.render.color.ColorUtils;
import no.clips.utils.render.font.Fonts;
import no.clips.utils.render.gl.Scissor;
import no.clips.utils.render.rect.RenderUtility;
import no.clips.modules.impl.render.HUD;
import org.lwjgl.opengl.GL11;

import java.awt.Color;
import java.util.LinkedList;

public class MotionGraphRenderer implements ElementRenderer {
    private final Dragging dragging;
    private final LinkedList<Double> speedPoints;
    private static final int MAX_POINTS = 100;
    private static final float GRAPH_WIDTH = 100;
    private static final float GRAPH_HEIGHT = 30;

    public MotionGraphRenderer(Dragging dragging) {
        this.dragging = dragging;
        this.speedPoints = new LinkedList<>();
    }

    [USER=1367676]@override[/USER]
    public void render(EventDisplay e) {
        if (mc.player == null) return;

        double xSpeed = mc.player.getPosX() - mc.player.lastTickPosX;
        double zSpeed = mc.player.getPosZ() - mc.player.lastTickPosZ;
        double currentSpeed = Math.sqrt(xSpeed * xSpeed + zSpeed * zSpeed) * 20;

        speedPoints.addLast(currentSpeed);
        if (speedPoints.size() > MAX_POINTS) {
            speedPoints.removeFirst();
        }

        float x = dragging.getX();
        float y = dragging.getY();

        drawStyledRect(x, y, GRAPH_WIDTH, GRAPH_HEIGHT, 3.5f);


        Scissor.push();
        Scissor.setFromComponentCoordinates(x + 0.5f, y + 0.5f, GRAPH_WIDTH - 1f, GRAPH_HEIGHT - 1f);

        String speedText = String.format("%.1f B/S", currentSpeed);
        float textWidth = Fonts.regular.getWidth(speedText, 7);
        float textHeight = Fonts.regular.getHeight(7);

        float centeredX = x + (GRAPH_WIDTH - textWidth) / 2;
        float centeredY = y + (GRAPH_HEIGHT - textHeight) / 2;

        Fonts.regular.drawText(e.getMatrixStack(), speedText, centeredX, centeredY, ColorUtils.setAlpha(Theme.Text(0), 100) , 7);

        int gridColor = new Color(255, 255, 255, 30).getRGB();
        for (int i = 0; i < 4; i++) {
            float gridY = y + (GRAPH_HEIGHT * i / 3);
            RenderUtility.drawRect(x, gridY, x + GRAPH_WIDTH, gridY + 0.5f, gridColor);
        }

        for (int i = 0; i < 4; i++) {
            float gridX = x + (GRAPH_WIDTH * i / 3);
            RenderUtility.drawRect(gridX, y, gridX + 0.5f, y + GRAPH_HEIGHT, gridColor);
        }

        if (speedPoints.size() > 1) {
            float lineThickness = 1.0f;
            for (int i = 0; i < speedPoints.size() - 1; i++) {
                float x1 = x + (i * GRAPH_WIDTH / MAX_POINTS);
                float x2 = x + ((i + 1) * GRAPH_WIDTH / MAX_POINTS);
                float y1 = (float) (y + GRAPH_HEIGHT - (speedPoints.get(i) * GRAPH_HEIGHT / 20));
                float y2 = (float) (y + GRAPH_HEIGHT - (speedPoints.get(i + 1) * GRAPH_HEIGHT / 20));

                float length = (float) Math.sqrt(Math.pow(x2 - x1, 2) + Math.pow(y2 - y1, 2));
                float angle = (float) Math.atan2(y2 - y1, x2 - x1);

                GL11.glPushMatrix();
                GL11.glTranslatef(x1, y1, 0);
                GL11.glRotatef((float) Math.toDegrees(angle), 0, 0, 1);
                RenderUtility.drawRect(0, -lineThickness / 2, length, lineThickness / 2, Theme.Text(0));
                GL11.glPopMatrix();
            }
        }

        dragging.setWidth(GRAPH_WIDTH);
        dragging.setHeight(GRAPH_HEIGHT);

        Scissor.unset();
        Scissor.pop();
       
        int outlineColor = ColorUtils.multDark(Theme.RectColor(0), 0.8f);
        RenderUtility.drawRoundedRectOutline(x, y, GRAPH_WIDTH, GRAPH_HEIGHT, 3.5f, 1.0f, outlineColor);
    }

    private void drawStyledRect(float x, float y, float width, float height, float radius) {
        int fillColor = ColorUtils.multDark(Theme.RectColor(0), 0.1f);
        int outlineColor = ColorUtils.multDark(Theme.RectColor(0), 0.8f);
        RenderUtility.drawRoundedRect(x, y, width, height, 4, ColorUtils.setAlpha(fillColor, 170));
        RenderUtility.drawRoundedRectOutline(x, y, width, height, 4, 1.0f, outlineColor);
    }
}
ахуеть, no clips клиент, я про него как сто лет забыл
 
y
Вижу все начали сливать и подумал тоже слить чо нет так сказать

ss -
Пожалуйста, авторизуйтесь для просмотра ссылки.

MotionGraphRenderer:
Expand Collapse Copy
package no.clips.ui.display.impl;

import no.clips.events.EventDisplay;
import no.clips.modules.impl.render.Theme;
import no.clips.ui.display.ElementRenderer;
import no.clips.utils.drag.Dragging;
import no.clips.utils.render.color.ColorUtils;
import no.clips.utils.render.font.Fonts;
import no.clips.utils.render.gl.Scissor;
import no.clips.utils.render.rect.RenderUtility;
import no.clips.modules.impl.render.HUD;
import org.lwjgl.opengl.GL11;

import java.awt.Color;
import java.util.LinkedList;

public class MotionGraphRenderer implements ElementRenderer {
    private final Dragging dragging;
    private final LinkedList<Double> speedPoints;
    private static final int MAX_POINTS = 100;
    private static final float GRAPH_WIDTH = 100;
    private static final float GRAPH_HEIGHT = 30;

    public MotionGraphRenderer(Dragging dragging) {
        this.dragging = dragging;
        this.speedPoints = new LinkedList<>();
    }

    [USER=1367676]@override[/USER]
    public void render(EventDisplay e) {
        if (mc.player == null) return;

        double xSpeed = mc.player.getPosX() - mc.player.lastTickPosX;
        double zSpeed = mc.player.getPosZ() - mc.player.lastTickPosZ;
        double currentSpeed = Math.sqrt(xSpeed * xSpeed + zSpeed * zSpeed) * 20;

        speedPoints.addLast(currentSpeed);
        if (speedPoints.size() > MAX_POINTS) {
            speedPoints.removeFirst();
        }

        float x = dragging.getX();
        float y = dragging.getY();

        drawStyledRect(x, y, GRAPH_WIDTH, GRAPH_HEIGHT, 3.5f);


        Scissor.push();
        Scissor.setFromComponentCoordinates(x + 0.5f, y + 0.5f, GRAPH_WIDTH - 1f, GRAPH_HEIGHT - 1f);

        String speedText = String.format("%.1f B/S", currentSpeed);
        float textWidth = Fonts.regular.getWidth(speedText, 7);
        float textHeight = Fonts.regular.getHeight(7);

        float centeredX = x + (GRAPH_WIDTH - textWidth) / 2;
        float centeredY = y + (GRAPH_HEIGHT - textHeight) / 2;

        Fonts.regular.drawText(e.getMatrixStack(), speedText, centeredX, centeredY, ColorUtils.setAlpha(Theme.Text(0), 100) , 7);

        int gridColor = new Color(255, 255, 255, 30).getRGB();
        for (int i = 0; i < 4; i++) {
            float gridY = y + (GRAPH_HEIGHT * i / 3);
            RenderUtility.drawRect(x, gridY, x + GRAPH_WIDTH, gridY + 0.5f, gridColor);
        }

        for (int i = 0; i < 4; i++) {
            float gridX = x + (GRAPH_WIDTH * i / 3);
            RenderUtility.drawRect(gridX, y, gridX + 0.5f, y + GRAPH_HEIGHT, gridColor);
        }

        if (speedPoints.size() > 1) {
            float lineThickness = 1.0f;
            for (int i = 0; i < speedPoints.size() - 1; i++) {
                float x1 = x + (i * GRAPH_WIDTH / MAX_POINTS);
                float x2 = x + ((i + 1) * GRAPH_WIDTH / MAX_POINTS);
                float y1 = (float) (y + GRAPH_HEIGHT - (speedPoints.get(i) * GRAPH_HEIGHT / 20));
                float y2 = (float) (y + GRAPH_HEIGHT - (speedPoints.get(i + 1) * GRAPH_HEIGHT / 20));

                float length = (float) Math.sqrt(Math.pow(x2 - x1, 2) + Math.pow(y2 - y1, 2));
                float angle = (float) Math.atan2(y2 - y1, x2 - x1);

                GL11.glPushMatrix();
                GL11.glTranslatef(x1, y1, 0);
                GL11.glRotatef((float) Math.toDegrees(angle), 0, 0, 1);
                RenderUtility.drawRect(0, -lineThickness / 2, length, lineThickness / 2, Theme.Text(0));
                GL11.glPopMatrix();
            }
        }

        dragging.setWidth(GRAPH_WIDTH);
        dragging.setHeight(GRAPH_HEIGHT);

        Scissor.unset();
        Scissor.pop();
       
        int outlineColor = ColorUtils.multDark(Theme.RectColor(0), 0.8f);
        RenderUtility.drawRoundedRectOutline(x, y, GRAPH_WIDTH, GRAPH_HEIGHT, 3.5f, 1.0f, outlineColor);
    }

    private void drawStyledRect(float x, float y, float width, float height, float radius) {
        int fillColor = ColorUtils.multDark(Theme.RectColor(0), 0.1f);
        int outlineColor = ColorUtils.multDark(Theme.RectColor(0), 0.8f);
        RenderUtility.drawRoundedRect(x, y, width, height, 4, ColorUtils.setAlpha(fillColor, 170));
        RenderUtility.drawRoundedRectOutline(x, y, width, height, 4, 1.0f, outlineColor);
    }
}
ну 50 на 50
 
Вижу все начали сливать и подумал тоже слить чо нет так сказать

ss -
Пожалуйста, авторизуйтесь для просмотра ссылки.

MotionGraphRenderer:
Expand Collapse Copy
package no.clips.ui.display.impl;

import no.clips.events.EventDisplay;
import no.clips.modules.impl.render.Theme;
import no.clips.ui.display.ElementRenderer;
import no.clips.utils.drag.Dragging;
import no.clips.utils.render.color.ColorUtils;
import no.clips.utils.render.font.Fonts;
import no.clips.utils.render.gl.Scissor;
import no.clips.utils.render.rect.RenderUtility;
import no.clips.modules.impl.render.HUD;
import org.lwjgl.opengl.GL11;

import java.awt.Color;
import java.util.LinkedList;

public class MotionGraphRenderer implements ElementRenderer {
    private final Dragging dragging;
    private final LinkedList<Double> speedPoints;
    private static final int MAX_POINTS = 100;
    private static final float GRAPH_WIDTH = 100;
    private static final float GRAPH_HEIGHT = 30;

    public MotionGraphRenderer(Dragging dragging) {
        this.dragging = dragging;
        this.speedPoints = new LinkedList<>();
    }

    [USER=1367676]@override[/USER]
    public void render(EventDisplay e) {
        if (mc.player == null) return;

        double xSpeed = mc.player.getPosX() - mc.player.lastTickPosX;
        double zSpeed = mc.player.getPosZ() - mc.player.lastTickPosZ;
        double currentSpeed = Math.sqrt(xSpeed * xSpeed + zSpeed * zSpeed) * 20;

        speedPoints.addLast(currentSpeed);
        if (speedPoints.size() > MAX_POINTS) {
            speedPoints.removeFirst();
        }

        float x = dragging.getX();
        float y = dragging.getY();

        drawStyledRect(x, y, GRAPH_WIDTH, GRAPH_HEIGHT, 3.5f);


        Scissor.push();
        Scissor.setFromComponentCoordinates(x + 0.5f, y + 0.5f, GRAPH_WIDTH - 1f, GRAPH_HEIGHT - 1f);

        String speedText = String.format("%.1f B/S", currentSpeed);
        float textWidth = Fonts.regular.getWidth(speedText, 7);
        float textHeight = Fonts.regular.getHeight(7);

        float centeredX = x + (GRAPH_WIDTH - textWidth) / 2;
        float centeredY = y + (GRAPH_HEIGHT - textHeight) / 2;

        Fonts.regular.drawText(e.getMatrixStack(), speedText, centeredX, centeredY, ColorUtils.setAlpha(Theme.Text(0), 100) , 7);

        int gridColor = new Color(255, 255, 255, 30).getRGB();
        for (int i = 0; i < 4; i++) {
            float gridY = y + (GRAPH_HEIGHT * i / 3);
            RenderUtility.drawRect(x, gridY, x + GRAPH_WIDTH, gridY + 0.5f, gridColor);
        }

        for (int i = 0; i < 4; i++) {
            float gridX = x + (GRAPH_WIDTH * i / 3);
            RenderUtility.drawRect(gridX, y, gridX + 0.5f, y + GRAPH_HEIGHT, gridColor);
        }

        if (speedPoints.size() > 1) {
            float lineThickness = 1.0f;
            for (int i = 0; i < speedPoints.size() - 1; i++) {
                float x1 = x + (i * GRAPH_WIDTH / MAX_POINTS);
                float x2 = x + ((i + 1) * GRAPH_WIDTH / MAX_POINTS);
                float y1 = (float) (y + GRAPH_HEIGHT - (speedPoints.get(i) * GRAPH_HEIGHT / 20));
                float y2 = (float) (y + GRAPH_HEIGHT - (speedPoints.get(i + 1) * GRAPH_HEIGHT / 20));

                float length = (float) Math.sqrt(Math.pow(x2 - x1, 2) + Math.pow(y2 - y1, 2));
                float angle = (float) Math.atan2(y2 - y1, x2 - x1);

                GL11.glPushMatrix();
                GL11.glTranslatef(x1, y1, 0);
                GL11.glRotatef((float) Math.toDegrees(angle), 0, 0, 1);
                RenderUtility.drawRect(0, -lineThickness / 2, length, lineThickness / 2, Theme.Text(0));
                GL11.glPopMatrix();
            }
        }

        dragging.setWidth(GRAPH_WIDTH);
        dragging.setHeight(GRAPH_HEIGHT);

        Scissor.unset();
        Scissor.pop();
       
        int outlineColor = ColorUtils.multDark(Theme.RectColor(0), 0.8f);
        RenderUtility.drawRoundedRectOutline(x, y, GRAPH_WIDTH, GRAPH_HEIGHT, 3.5f, 1.0f, outlineColor);
    }

    private void drawStyledRect(float x, float y, float width, float height, float radius) {
        int fillColor = ColorUtils.multDark(Theme.RectColor(0), 0.1f);
        int outlineColor = ColorUtils.multDark(Theme.RectColor(0), 0.8f);
        RenderUtility.drawRoundedRect(x, y, width, height, 4, ColorUtils.setAlpha(fillColor, 170));
        RenderUtility.drawRoundedRectOutline(x, y, width, height, 4, 1.0f, outlineColor);
    }
}
ого, первый раз вижу что гыфтыс что-то слил
 
шикардос
 
Вижу все начали сливать и подумал тоже слить чо нет так сказать

ss -
Пожалуйста, авторизуйтесь для просмотра ссылки.

MotionGraphRenderer:
Expand Collapse Copy
package no.clips.ui.display.impl;

import no.clips.events.EventDisplay;
import no.clips.modules.impl.render.Theme;
import no.clips.ui.display.ElementRenderer;
import no.clips.utils.drag.Dragging;
import no.clips.utils.render.color.ColorUtils;
import no.clips.utils.render.font.Fonts;
import no.clips.utils.render.gl.Scissor;
import no.clips.utils.render.rect.RenderUtility;
import no.clips.modules.impl.render.HUD;
import org.lwjgl.opengl.GL11;

import java.awt.Color;
import java.util.LinkedList;

public class MotionGraphRenderer implements ElementRenderer {
    private final Dragging dragging;
    private final LinkedList<Double> speedPoints;
    private static final int MAX_POINTS = 100;
    private static final float GRAPH_WIDTH = 100;
    private static final float GRAPH_HEIGHT = 30;

    public MotionGraphRenderer(Dragging dragging) {
        this.dragging = dragging;
        this.speedPoints = new LinkedList<>();
    }

    [USER=1367676]@override[/USER]
    public void render(EventDisplay e) {
        if (mc.player == null) return;

        double xSpeed = mc.player.getPosX() - mc.player.lastTickPosX;
        double zSpeed = mc.player.getPosZ() - mc.player.lastTickPosZ;
        double currentSpeed = Math.sqrt(xSpeed * xSpeed + zSpeed * zSpeed) * 20;

        speedPoints.addLast(currentSpeed);
        if (speedPoints.size() > MAX_POINTS) {
            speedPoints.removeFirst();
        }

        float x = dragging.getX();
        float y = dragging.getY();

        drawStyledRect(x, y, GRAPH_WIDTH, GRAPH_HEIGHT, 3.5f);


        Scissor.push();
        Scissor.setFromComponentCoordinates(x + 0.5f, y + 0.5f, GRAPH_WIDTH - 1f, GRAPH_HEIGHT - 1f);

        String speedText = String.format("%.1f B/S", currentSpeed);
        float textWidth = Fonts.regular.getWidth(speedText, 7);
        float textHeight = Fonts.regular.getHeight(7);

        float centeredX = x + (GRAPH_WIDTH - textWidth) / 2;
        float centeredY = y + (GRAPH_HEIGHT - textHeight) / 2;

        Fonts.regular.drawText(e.getMatrixStack(), speedText, centeredX, centeredY, ColorUtils.setAlpha(Theme.Text(0), 100) , 7);

        int gridColor = new Color(255, 255, 255, 30).getRGB();
        for (int i = 0; i < 4; i++) {
            float gridY = y + (GRAPH_HEIGHT * i / 3);
            RenderUtility.drawRect(x, gridY, x + GRAPH_WIDTH, gridY + 0.5f, gridColor);
        }

        for (int i = 0; i < 4; i++) {
            float gridX = x + (GRAPH_WIDTH * i / 3);
            RenderUtility.drawRect(gridX, y, gridX + 0.5f, y + GRAPH_HEIGHT, gridColor);
        }

        if (speedPoints.size() > 1) {
            float lineThickness = 1.0f;
            for (int i = 0; i < speedPoints.size() - 1; i++) {
                float x1 = x + (i * GRAPH_WIDTH / MAX_POINTS);
                float x2 = x + ((i + 1) * GRAPH_WIDTH / MAX_POINTS);
                float y1 = (float) (y + GRAPH_HEIGHT - (speedPoints.get(i) * GRAPH_HEIGHT / 20));
                float y2 = (float) (y + GRAPH_HEIGHT - (speedPoints.get(i + 1) * GRAPH_HEIGHT / 20));

                float length = (float) Math.sqrt(Math.pow(x2 - x1, 2) + Math.pow(y2 - y1, 2));
                float angle = (float) Math.atan2(y2 - y1, x2 - x1);

                GL11.glPushMatrix();
                GL11.glTranslatef(x1, y1, 0);
                GL11.glRotatef((float) Math.toDegrees(angle), 0, 0, 1);
                RenderUtility.drawRect(0, -lineThickness / 2, length, lineThickness / 2, Theme.Text(0));
                GL11.glPopMatrix();
            }
        }

        dragging.setWidth(GRAPH_WIDTH);
        dragging.setHeight(GRAPH_HEIGHT);

        Scissor.unset();
        Scissor.pop();
       
        int outlineColor = ColorUtils.multDark(Theme.RectColor(0), 0.8f);
        RenderUtility.drawRoundedRectOutline(x, y, GRAPH_WIDTH, GRAPH_HEIGHT, 3.5f, 1.0f, outlineColor);
    }

    private void drawStyledRect(float x, float y, float width, float height, float radius) {
        int fillColor = ColorUtils.multDark(Theme.RectColor(0), 0.1f);
        int outlineColor = ColorUtils.multDark(Theme.RectColor(0), 0.8f);
        RenderUtility.drawRoundedRect(x, y, width, height, 4, ColorUtils.setAlpha(fillColor, 170));
        RenderUtility.drawRoundedRectOutline(x, y, width, height, 4, 1.0f, outlineColor);
    }
}
это пизда
 
ахуеть, неплохо для югейма
 
Обратите внимание, пользователь заблокирован на форуме. Не рекомендуется проводить сделки.
бесполезный элемент в худе, данный калл слепленный из отбросов рендера использовалась максимум игроками на мете и браво, ну и частично риливорлд
 
Ой бля панапастил
 
Вижу все начали сливать и подумал тоже слить чо нет так сказать

ss -
Пожалуйста, авторизуйтесь для просмотра ссылки.

MotionGraphRenderer:
Expand Collapse Copy
package no.clips.ui.display.impl;

import no.clips.events.EventDisplay;
import no.clips.modules.impl.render.Theme;
import no.clips.ui.display.ElementRenderer;
import no.clips.utils.drag.Dragging;
import no.clips.utils.render.color.ColorUtils;
import no.clips.utils.render.font.Fonts;
import no.clips.utils.render.gl.Scissor;
import no.clips.utils.render.rect.RenderUtility;
import no.clips.modules.impl.render.HUD;
import org.lwjgl.opengl.GL11;

import java.awt.Color;
import java.util.LinkedList;

public class MotionGraphRenderer implements ElementRenderer {
    private final Dragging dragging;
    private final LinkedList<Double> speedPoints;
    private static final int MAX_POINTS = 100;
    private static final float GRAPH_WIDTH = 100;
    private static final float GRAPH_HEIGHT = 30;

    public MotionGraphRenderer(Dragging dragging) {
        this.dragging = dragging;
        this.speedPoints = new LinkedList<>();
    }

    [USER=1367676]@override[/USER]
    public void render(EventDisplay e) {
        if (mc.player == null) return;

        double xSpeed = mc.player.getPosX() - mc.player.lastTickPosX;
        double zSpeed = mc.player.getPosZ() - mc.player.lastTickPosZ;
        double currentSpeed = Math.sqrt(xSpeed * xSpeed + zSpeed * zSpeed) * 20;

        speedPoints.addLast(currentSpeed);
        if (speedPoints.size() > MAX_POINTS) {
            speedPoints.removeFirst();
        }

        float x = dragging.getX();
        float y = dragging.getY();

        drawStyledRect(x, y, GRAPH_WIDTH, GRAPH_HEIGHT, 3.5f);


        Scissor.push();
        Scissor.setFromComponentCoordinates(x + 0.5f, y + 0.5f, GRAPH_WIDTH - 1f, GRAPH_HEIGHT - 1f);

        String speedText = String.format("%.1f B/S", currentSpeed);
        float textWidth = Fonts.regular.getWidth(speedText, 7);
        float textHeight = Fonts.regular.getHeight(7);

        float centeredX = x + (GRAPH_WIDTH - textWidth) / 2;
        float centeredY = y + (GRAPH_HEIGHT - textHeight) / 2;

        Fonts.regular.drawText(e.getMatrixStack(), speedText, centeredX, centeredY, ColorUtils.setAlpha(Theme.Text(0), 100) , 7);

        int gridColor = new Color(255, 255, 255, 30).getRGB();
        for (int i = 0; i < 4; i++) {
            float gridY = y + (GRAPH_HEIGHT * i / 3);
            RenderUtility.drawRect(x, gridY, x + GRAPH_WIDTH, gridY + 0.5f, gridColor);
        }

        for (int i = 0; i < 4; i++) {
            float gridX = x + (GRAPH_WIDTH * i / 3);
            RenderUtility.drawRect(gridX, y, gridX + 0.5f, y + GRAPH_HEIGHT, gridColor);
        }

        if (speedPoints.size() > 1) {
            float lineThickness = 1.0f;
            for (int i = 0; i < speedPoints.size() - 1; i++) {
                float x1 = x + (i * GRAPH_WIDTH / MAX_POINTS);
                float x2 = x + ((i + 1) * GRAPH_WIDTH / MAX_POINTS);
                float y1 = (float) (y + GRAPH_HEIGHT - (speedPoints.get(i) * GRAPH_HEIGHT / 20));
                float y2 = (float) (y + GRAPH_HEIGHT - (speedPoints.get(i + 1) * GRAPH_HEIGHT / 20));

                float length = (float) Math.sqrt(Math.pow(x2 - x1, 2) + Math.pow(y2 - y1, 2));
                float angle = (float) Math.atan2(y2 - y1, x2 - x1);

                GL11.glPushMatrix();
                GL11.glTranslatef(x1, y1, 0);
                GL11.glRotatef((float) Math.toDegrees(angle), 0, 0, 1);
                RenderUtility.drawRect(0, -lineThickness / 2, length, lineThickness / 2, Theme.Text(0));
                GL11.glPopMatrix();
            }
        }

        dragging.setWidth(GRAPH_WIDTH);
        dragging.setHeight(GRAPH_HEIGHT);

        Scissor.unset();
        Scissor.pop();
       
        int outlineColor = ColorUtils.multDark(Theme.RectColor(0), 0.8f);
        RenderUtility.drawRoundedRectOutline(x, y, GRAPH_WIDTH, GRAPH_HEIGHT, 3.5f, 1.0f, outlineColor);
    }

    private void drawStyledRect(float x, float y, float width, float height, float radius) {
        int fillColor = ColorUtils.multDark(Theme.RectColor(0), 0.1f);
        int outlineColor = ColorUtils.multDark(Theme.RectColor(0), 0.8f);
        RenderUtility.drawRoundedRect(x, y, width, height, 4, ColorUtils.setAlpha(fillColor, 170));
        RenderUtility.drawRoundedRectOutline(x, y, width, height, 4, 1.0f, outlineColor);
    }
}

made by "paster" for "pasta-yougame-client.lol"
 
Вижу все начали сливать и подумал тоже слить чо нет так сказать

ss -
Пожалуйста, авторизуйтесь для просмотра ссылки.

MotionGraphRenderer:
Expand Collapse Copy
package no.clips.ui.display.impl;

import no.clips.events.EventDisplay;
import no.clips.modules.impl.render.Theme;
import no.clips.ui.display.ElementRenderer;
import no.clips.utils.drag.Dragging;
import no.clips.utils.render.color.ColorUtils;
import no.clips.utils.render.font.Fonts;
import no.clips.utils.render.gl.Scissor;
import no.clips.utils.render.rect.RenderUtility;
import no.clips.modules.impl.render.HUD;
import org.lwjgl.opengl.GL11;

import java.awt.Color;
import java.util.LinkedList;

public class MotionGraphRenderer implements ElementRenderer {
    private final Dragging dragging;
    private final LinkedList<Double> speedPoints;
    private static final int MAX_POINTS = 100;
    private static final float GRAPH_WIDTH = 100;
    private static final float GRAPH_HEIGHT = 30;

    public MotionGraphRenderer(Dragging dragging) {
        this.dragging = dragging;
        this.speedPoints = new LinkedList<>();
    }

    [USER=1367676]@override[/USER]
    public void render(EventDisplay e) {
        if (mc.player == null) return;

        double xSpeed = mc.player.getPosX() - mc.player.lastTickPosX;
        double zSpeed = mc.player.getPosZ() - mc.player.lastTickPosZ;
        double currentSpeed = Math.sqrt(xSpeed * xSpeed + zSpeed * zSpeed) * 20;

        speedPoints.addLast(currentSpeed);
        if (speedPoints.size() > MAX_POINTS) {
            speedPoints.removeFirst();
        }

        float x = dragging.getX();
        float y = dragging.getY();

        drawStyledRect(x, y, GRAPH_WIDTH, GRAPH_HEIGHT, 3.5f);


        Scissor.push();
        Scissor.setFromComponentCoordinates(x + 0.5f, y + 0.5f, GRAPH_WIDTH - 1f, GRAPH_HEIGHT - 1f);

        String speedText = String.format("%.1f B/S", currentSpeed);
        float textWidth = Fonts.regular.getWidth(speedText, 7);
        float textHeight = Fonts.regular.getHeight(7);

        float centeredX = x + (GRAPH_WIDTH - textWidth) / 2;
        float centeredY = y + (GRAPH_HEIGHT - textHeight) / 2;

        Fonts.regular.drawText(e.getMatrixStack(), speedText, centeredX, centeredY, ColorUtils.setAlpha(Theme.Text(0), 100) , 7);

        int gridColor = new Color(255, 255, 255, 30).getRGB();
        for (int i = 0; i < 4; i++) {
            float gridY = y + (GRAPH_HEIGHT * i / 3);
            RenderUtility.drawRect(x, gridY, x + GRAPH_WIDTH, gridY + 0.5f, gridColor);
        }

        for (int i = 0; i < 4; i++) {
            float gridX = x + (GRAPH_WIDTH * i / 3);
            RenderUtility.drawRect(gridX, y, gridX + 0.5f, y + GRAPH_HEIGHT, gridColor);
        }

        if (speedPoints.size() > 1) {
            float lineThickness = 1.0f;
            for (int i = 0; i < speedPoints.size() - 1; i++) {
                float x1 = x + (i * GRAPH_WIDTH / MAX_POINTS);
                float x2 = x + ((i + 1) * GRAPH_WIDTH / MAX_POINTS);
                float y1 = (float) (y + GRAPH_HEIGHT - (speedPoints.get(i) * GRAPH_HEIGHT / 20));
                float y2 = (float) (y + GRAPH_HEIGHT - (speedPoints.get(i + 1) * GRAPH_HEIGHT / 20));

                float length = (float) Math.sqrt(Math.pow(x2 - x1, 2) + Math.pow(y2 - y1, 2));
                float angle = (float) Math.atan2(y2 - y1, x2 - x1);

                GL11.glPushMatrix();
                GL11.glTranslatef(x1, y1, 0);
                GL11.glRotatef((float) Math.toDegrees(angle), 0, 0, 1);
                RenderUtility.drawRect(0, -lineThickness / 2, length, lineThickness / 2, Theme.Text(0));
                GL11.glPopMatrix();
            }
        }

        dragging.setWidth(GRAPH_WIDTH);
        dragging.setHeight(GRAPH_HEIGHT);

        Scissor.unset();
        Scissor.pop();
       
        int outlineColor = ColorUtils.multDark(Theme.RectColor(0), 0.8f);
        RenderUtility.drawRoundedRectOutline(x, y, GRAPH_WIDTH, GRAPH_HEIGHT, 3.5f, 1.0f, outlineColor);
    }

    private void drawStyledRect(float x, float y, float width, float height, float radius) {
        int fillColor = ColorUtils.multDark(Theme.RectColor(0), 0.1f);
        int outlineColor = ColorUtils.multDark(Theme.RectColor(0), 0.8f);
        RenderUtility.drawRoundedRect(x, y, width, height, 4, ColorUtils.setAlpha(fillColor, 170));
        RenderUtility.drawRoundedRectOutline(x, y, width, height, 4, 1.0f, outlineColor);
    }
}
гифитс легенда
 
Назад
Сверху Снизу