Подведи собственные итоги года совместно с YOUGAME и забери ценные призы! Перейти

ArrayList сочный // Expensive 2.0

Начинающий
Начинающий
Статус
Оффлайн
Регистрация
4 Янв 2023
Сообщения
370
Реакции
11
Аура лист с градиентом
отделение от функций добавите сами что всё сочиталось

SS
2024-03-11_19-23-16.png


Сам код

Java:
Expand Collapse Copy
    private void renderFunctions(MatrixStack matrixStack, int offset, boolean glowing) {
        float padding = 4;
float dumbOffset = 1.5f;

float height = small.getFontHeight() - dumbOffset + padding;

List<Function> fs = new ArrayList<>();

for (Function f : functions) {
f.animation = AnimationMath.fast(f.animation, f.state ? 1 : 0, 15);
if (f.animation < 0.1) continue;
fs.add(f);
}

List<Function> fs1 = new ArrayList<>();
int in = 0;
for (Function f : functions) {
if (!f.state) continue;
fs1.add(f);
}

for (Function f : fs1) {
boolean isLast = in == fs1.size() - 1;

f.degree = isLast ? round_degree : Math.min(small.getWidth(f.name) + 1 - small.getWidth(fs1.get(in + 1).name), round_degree);
in++;
}

float index = 0;

for (Function f : fs) {
boolean isFirst = index == 0;
boolean isLast = Math.round(index) == fs.size() - 1;

float width = small.getWidth(f.name) + (padding * 2);

float r_posX = window.scaledWidth() - offset - width;
float r_posY = offset + (index * height);

float degree = f.degree;

Vector4f left_vec = new Vector4f(isFirst ? round_degree : 0, degree, 0, 0);
Vector4f right_vec = new Vector4f(0, 0, isFirst ? round_degree : 0, isLast ? round_degree : 0);

float finalIndex = index;

Vector4i vec = new Vector4i(getColor((int) (finalIndex * 10)), getColor((int) ((finalIndex + 1) * 10)), getColor((int) (finalIndex * 10)), getColor((int) ((finalIndex + 1) * 10)));


GlStateManager.pushMatrix();
GlStateManager.translated(r_posX - cWidth, r_posY, 0);
GlStateManager.scaled(1, f.animation, 1);
GlStateManager.translated(-(r_posX - cWidth), -r_posY, 0);
// gradient
            RenderUtil.Render2D.drawGradientRound(r_posX - cWidth, r_posY, width, height, 1, w_color, t_color, ColorUtil.getColorStyle(180), ColorUtil.getColorStyle(270));
RenderUtil.Render2D.drawShadow(r_posX - cWidth, r_posY, width, height, 10, RenderUtil.reAlphaInt(b_color, 64));
//backround
            RenderUtil.Render2D.drawRoundedCorner(r_posX - cWidth, r_posY, width, height, right_vec, b_color);

small.drawString(matrixStack, f.name, r_posX + padding - cWidth - 1, r_posY - dumbOffset + (height / 2), -1);

GlStateManager.popMatrix();

index+=f.animation;
in++;
}
}

    }
 
Последнее редактирование:
Обратите внимание, пользователь заблокирован на форуме. Не рекомендуется проводить сделки.
Обратите внимание, пользователь заблокирован на форуме. Не рекомендуется проводить сделки.
Честно, ещё то говно
 
Аура лист с градиентом
отделение от функций добавите сами что всё сочиталось

SSПосмотреть вложение 272356

Сам код

Java:
Expand Collapse Copy
    private void renderFunctions(MatrixStack matrixStack, int offset, boolean glowing) {
        float padding = 4;
float dumbOffset = 1.5f;

float height = small.getFontHeight() - dumbOffset + padding;

List<Function> fs = new ArrayList<>();

for (Function f : functions) {
f.animation = AnimationMath.fast(f.animation, f.state ? 1 : 0, 15);
if (f.animation < 0.1) continue;
fs.add(f);
}

List<Function> fs1 = new ArrayList<>();
int in = 0;
for (Function f : functions) {
if (!f.state) continue;
fs1.add(f);
}

for (Function f : fs1) {
boolean isLast = in == fs1.size() - 1;

f.degree = isLast ? round_degree : Math.min(small.getWidth(f.name) + 1 - small.getWidth(fs1.get(in + 1).name), round_degree);
in++;
}

float index = 0;

for (Function f : fs) {
boolean isFirst = index == 0;
boolean isLast = Math.round(index) == fs.size() - 1;

float width = small.getWidth(f.name) + (padding * 2);

float r_posX = window.scaledWidth() - offset - width;
float r_posY = offset + (index * height);

float degree = f.degree;

Vector4f left_vec = new Vector4f(isFirst ? round_degree : 0, degree, 0, 0);
Vector4f right_vec = new Vector4f(0, 0, isFirst ? round_degree : 0, isLast ? round_degree : 0);

float finalIndex = index;

Vector4i vec = new Vector4i(getColor((int) (finalIndex * 10)), getColor((int) ((finalIndex + 1) * 10)), getColor((int) (finalIndex * 10)), getColor((int) ((finalIndex + 1) * 10)));


GlStateManager.pushMatrix();
GlStateManager.translated(r_posX - cWidth, r_posY, 0);
GlStateManager.scaled(1, f.animation, 1);
GlStateManager.translated(-(r_posX - cWidth), -r_posY, 0);
// gradient
            RenderUtil.Render2D.drawGradientRound(r_posX - cWidth, r_posY, width, height, 1, w_color, t_color, ColorUtil.getColorStyle(180), ColorUtil.getColorStyle(270));
RenderUtil.Render2D.drawShadow(r_posX - cWidth, r_posY, width, height, 10, RenderUtil.reAlphaInt(b_color, 64));
//backround
            RenderUtil.Render2D.drawRoundedCorner(r_posX - cWidth, r_posY, width, height, right_vec, b_color);

small.drawString(matrixStack, f.name, r_posX + padding - cWidth - 1, r_posY - dumbOffset + (height / 2), -1);

GlStateManager.popMatrix();

index+=f.animation;
in++;
}
}

    }
Блять
 
Аура лист с градиентом
отделение от функций добавите сами что всё сочиталось

SSПосмотреть вложение 272356

Сам код

Java:
Expand Collapse Copy
    private void renderFunctions(MatrixStack matrixStack, int offset, boolean glowing) {
        float padding = 4;
float dumbOffset = 1.5f;

float height = small.getFontHeight() - dumbOffset + padding;

List<Function> fs = new ArrayList<>();

for (Function f : functions) {
f.animation = AnimationMath.fast(f.animation, f.state ? 1 : 0, 15);
if (f.animation < 0.1) continue;
fs.add(f);
}

List<Function> fs1 = new ArrayList<>();
int in = 0;
for (Function f : functions) {
if (!f.state) continue;
fs1.add(f);
}

for (Function f : fs1) {
boolean isLast = in == fs1.size() - 1;

f.degree = isLast ? round_degree : Math.min(small.getWidth(f.name) + 1 - small.getWidth(fs1.get(in + 1).name), round_degree);
in++;
}

float index = 0;

for (Function f : fs) {
boolean isFirst = index == 0;
boolean isLast = Math.round(index) == fs.size() - 1;

float width = small.getWidth(f.name) + (padding * 2);

float r_posX = window.scaledWidth() - offset - width;
float r_posY = offset + (index * height);

float degree = f.degree;

Vector4f left_vec = new Vector4f(isFirst ? round_degree : 0, degree, 0, 0);
Vector4f right_vec = new Vector4f(0, 0, isFirst ? round_degree : 0, isLast ? round_degree : 0);

float finalIndex = index;

Vector4i vec = new Vector4i(getColor((int) (finalIndex * 10)), getColor((int) ((finalIndex + 1) * 10)), getColor((int) (finalIndex * 10)), getColor((int) ((finalIndex + 1) * 10)));


GlStateManager.pushMatrix();
GlStateManager.translated(r_posX - cWidth, r_posY, 0);
GlStateManager.scaled(1, f.animation, 1);
GlStateManager.translated(-(r_posX - cWidth), -r_posY, 0);
// gradient
            RenderUtil.Render2D.drawGradientRound(r_posX - cWidth, r_posY, width, height, 1, w_color, t_color, ColorUtil.getColorStyle(180), ColorUtil.getColorStyle(270));
RenderUtil.Render2D.drawShadow(r_posX - cWidth, r_posY, width, height, 10, RenderUtil.reAlphaInt(b_color, 64));
//backround
            RenderUtil.Render2D.drawRoundedCorner(r_posX - cWidth, r_posY, width, height, right_vec, b_color);

small.drawString(matrixStack, f.name, r_posX + padding - cWidth - 1, r_posY - dumbOffset + (height / 2), -1);

GlStateManager.popMatrix();

index+=f.animation;
in++;
}
}

    }
arbuz client$$$
 
Обратите внимание, пользователь заблокирован на форуме. Не рекомендуется проводить сделки.
Лева, этот понос даже пастеры юзать не будут, это что-то на очень сташном ты сюда залил
 
не вижу тут сочного ничего
 
Обратите внимание, пользователь заблокирован на форуме. Не рекомендуется проводить сделки.
дружЫще закидывай это произведение$$ в свое портфолио и оформляйся на фрилансе как ux/ui de$ign€R зделою дровградиентраунд за вас дорага 999$ 1 строка, это недалжно остатьстя без внимания О_О
 
Скид арбуз free?
 
Обратите внимание, пользователь заблокирован на форуме. Не рекомендуется проводить сделки.
Аура лист с градиентом
отделение от функций добавите сами что всё сочиталось

SSПосмотреть вложение 272356

Сам код

Java:
Expand Collapse Copy
    private void renderFunctions(MatrixStack matrixStack, int offset, boolean glowing) {
        float padding = 4;
float dumbOffset = 1.5f;

float height = small.getFontHeight() - dumbOffset + padding;

List<Function> fs = new ArrayList<>();

for (Function f : functions) {
f.animation = AnimationMath.fast(f.animation, f.state ? 1 : 0, 15);
if (f.animation < 0.1) continue;
fs.add(f);
}

List<Function> fs1 = new ArrayList<>();
int in = 0;
for (Function f : functions) {
if (!f.state) continue;
fs1.add(f);
}

for (Function f : fs1) {
boolean isLast = in == fs1.size() - 1;

f.degree = isLast ? round_degree : Math.min(small.getWidth(f.name) + 1 - small.getWidth(fs1.get(in + 1).name), round_degree);
in++;
}

float index = 0;

for (Function f : fs) {
boolean isFirst = index == 0;
boolean isLast = Math.round(index) == fs.size() - 1;

float width = small.getWidth(f.name) + (padding * 2);

float r_posX = window.scaledWidth() - offset - width;
float r_posY = offset + (index * height);

float degree = f.degree;

Vector4f left_vec = new Vector4f(isFirst ? round_degree : 0, degree, 0, 0);
Vector4f right_vec = new Vector4f(0, 0, isFirst ? round_degree : 0, isLast ? round_degree : 0);

float finalIndex = index;

Vector4i vec = new Vector4i(getColor((int) (finalIndex * 10)), getColor((int) ((finalIndex + 1) * 10)), getColor((int) (finalIndex * 10)), getColor((int) ((finalIndex + 1) * 10)));


GlStateManager.pushMatrix();
GlStateManager.translated(r_posX - cWidth, r_posY, 0);
GlStateManager.scaled(1, f.animation, 1);
GlStateManager.translated(-(r_posX - cWidth), -r_posY, 0);
// gradient
            RenderUtil.Render2D.drawGradientRound(r_posX - cWidth, r_posY, width, height, 1, w_color, t_color, ColorUtil.getColorStyle(180), ColorUtil.getColorStyle(270));
RenderUtil.Render2D.drawShadow(r_posX - cWidth, r_posY, width, height, 10, RenderUtil.reAlphaInt(b_color, 64));
//backround
            RenderUtil.Render2D.drawRoundedCorner(r_posX - cWidth, r_posY, width, height, right_vec, b_color);

small.drawString(matrixStack, f.name, r_posX + padding - cWidth - 1, r_posY - dumbOffset + (height / 2), -1);

GlStateManager.popMatrix();

index+=f.animation;
in++;
}
}

    }
а че они друг на друга наложились? или это изюминка?
 
Назад
Сверху Снизу