Исходник CustomScoreBoard | Expensive 3.1

Начинающий
Начинающий
Статус
Оффлайн
Регистрация
1 Авг 2024
Сообщения
426
Реакции
0
Выберите загрузчик игры
  1. OptiFine
Итак, приступим

Заходим в IngameGui.java
Ищем метод func_238447_a_ или же renderScoreboard

Заменяем на это

IngameGui.java:
Expand Collapse Copy
private void func_238447_a_(MatrixStack p_238447_1_, ScoreObjective p_238447_2_) {
        EventCancelOverlay eventCancelOverlay = new EventCancelOverlay(EventCancelOverlay.Overlays.SCOREBOARD);
        Demure.getInstance().getEventBus().post(eventCancelOverlay);

        if (eventCancelOverlay.isCancel()) {
            eventCancelOverlay.open();
            return;
        }

        Scoreboard scoreboard = p_238447_2_.getScoreboard();
        Collection<Score> collection = scoreboard.getSortedScores(p_238447_2_);
        List<Score> list = collection.stream().filter((p_lambda$renderScoreboard$1_0_) -> {
            return p_lambda$renderScoreboard$1_0_.getPlayerName() != null
                    && !p_lambda$renderScoreboard$1_0_.getPlayerName().startsWith("#");
        }).collect(Collectors.toList());

        if (list.size() > 15) {
            collection = Lists.newArrayList(Iterables.skip(list, collection.size() - 15));
        } else {
            collection = list;
        }

        List<Pair<Score, ITextComponent>> list1 = Lists.newArrayListWithCapacity(collection.size());
        ITextComponent itextcomponent = p_238447_2_.getDisplayName();
        int i = this.getFontRenderer().getStringPropertyWidth(itextcomponent);
        int j = i;
        int k = this.getFontRenderer().getStringWidth(": ");

        for (Score score : collection) {
            ScorePlayerTeam scoreplayerteam = scoreboard.getPlayersTeam(score.getPlayerName());
            ITextComponent itextcomponent1 = ScorePlayerTeam.formatPlayerName(scoreplayerteam,
                    new StringTextComponent(score.getPlayerName()));
            list1.add(Pair.of(score, itextcomponent1));
            j = Math.max(j, this.getFontRenderer().getStringPropertyWidth(itextcomponent1) + k
                    + this.getFontRenderer().getStringWidth(Integer.toString(score.getScorePoints())));
        }

        int i2 = collection.size() * 9;
        int j2 = this.scaledHeight / 2 + i2 / 3;
        int k2 = 3;
        int l2 = this.scaledWidth - j - 3;
        int l = 0;
        int i1 = this.mc.gameSettings.getTextBackgroundColor(0.3F);
        int j1 = this.mc.gameSettings.getTextBackgroundColor(0.4F);


        int витч = j + 6;
        int хеич = collection.size() * 9 + 10;
        int Xc = this.scaledWidth - totalWidth - 3;
        int Yc= j2 - totalHeight + 5;

        if(Demure.getInstance().getFunctionRegistry().getCustomScoreBoard().isState()) {

            if (CustomScoreBoard.bluyr.get()) {
                GaussianBlur.startBlur();
                DisplayUtils.drawRoundedRect(Xc  + 3,Yc - 7, витч, хеич + 4, 3, ColorUtils.rgba(0,0,0,100));
                GaussianBlur.endBlur(3,1);
            }
            DisplayUtils.drawRoundedRect(Xc + 3,Yc - 7, витч, хеич + 4, 3, ColorUtils.rgba(0,0,0,100));

            DisplayUtils.drawRoundedRectOutline(Xc + 3, Yc - 7, витч, хеич + 4, 3, 2, ColorUtils.getColor(0));
        }
        for (Pair<Score, ITextComponent> pair : list1) {
            ++l;
            Score score1 = pair.getFirst();
            ITextComponent itextcomponent2 = pair.getSecond();
            String s = TextFormatting.RED + "" + score1.getScorePoints();
            int k1 = j2 - l * 9;
            int l1 = this.scaledWidth - 3 + 2;

            if(!Demure.getInstance().getFunctionRegistry().getCustomScoreBoard().isState()){
                fill(p_238447_1_, l2 - 2, k1, l1, k1 + 9, i1);
            }

            this.getFontRenderer().func_243248_b(p_238447_1_, itextcomponent2, (float) l2, (float) k1, -1);
            this.getFontRenderer().drawString(p_238447_1_, s, (float) (l1 - this.getFontRenderer().getStringWidth(s)),
                    (float) k1, -1);

            if (l == collection.size()) {
                if(!Demure.getInstance().getFunctionRegistry().getCustomScoreBoard().isState()){
                    fill(p_238447_1_, l2 - 2, k1 - 9 - 1, l1, k1 - 1, j1);
                    fill(p_238447_1_, l2 - 2, k1 - 1, l1, k1, i1);
                }

                this.getFontRenderer().func_243248_b(p_238447_1_, itextcomponent, (float) (l2 + j / 2 - i / 2),
                        (float) (k1 - 9), -1);
            }
        }
    }

Далее создаем по пути im.expensive.functions.impl.render класс CustomScoreBoard с таким кодом
CustomScoreBoard.java:
Expand Collapse Copy
package fun.demure.functions.impl.render;

import fun.demure.functions.api.Category;
import fun.demure.functions.api.Function;
import fun.demure.functions.api.FunctionRegister;
import fun.demure.functions.settings.impl.BooleanSetting;

@FunctionRegister(name = "CustomScoreBoard", type = Category.Render)
public class CustomScoreBoard extends Function {
    public static final BooleanSetting bluyr = new BooleanSetting("Блюр", true);

    public CustomScoreBoard(){
        addSettings(bluyr);
    }
}

И регаем его в FunctionRegistry.java

Все! Ваш кастом боард готов.
1750236309553.png


1750236562982.png


Блюр, оутлайн рект, и тд заменяйте на свое
 
Последнее редактирование:
Обратите внимание, пользователь заблокирован на форуме. Не рекомендуется проводить сделки.
:seemsgood:Годно
 
Прикольно
 
прикольный рендер но сделать это труда не составит
 
Обратите внимание, пользователь заблокирован на форуме. Не рекомендуется проводить сделки.
пиздец сложно же сделать да?
 
Итак, приступим

Заходим в IngameGui.java
Ищем метод func_238447_a_ или же renderScoreboard

Заменяем на это

IngameGui.java:
Expand Collapse Copy
private void func_238447_a_(MatrixStack p_238447_1_, ScoreObjective p_238447_2_) {
        EventCancelOverlay eventCancelOverlay = new EventCancelOverlay(EventCancelOverlay.Overlays.SCOREBOARD);
        Demure.getInstance().getEventBus().post(eventCancelOverlay);

        if (eventCancelOverlay.isCancel()) {
            eventCancelOverlay.open();
            return;
        }

        Scoreboard scoreboard = p_238447_2_.getScoreboard();
        Collection<Score> collection = scoreboard.getSortedScores(p_238447_2_);
        List<Score> list = collection.stream().filter((p_lambda$renderScoreboard$1_0_) -> {
            return p_lambda$renderScoreboard$1_0_.getPlayerName() != null
                    && !p_lambda$renderScoreboard$1_0_.getPlayerName().startsWith("#");
        }).collect(Collectors.toList());

        if (list.size() > 15) {
            collection = Lists.newArrayList(Iterables.skip(list, collection.size() - 15));
        } else {
            collection = list;
        }

        List<Pair<Score, ITextComponent>> list1 = Lists.newArrayListWithCapacity(collection.size());
        ITextComponent itextcomponent = p_238447_2_.getDisplayName();
        int i = this.getFontRenderer().getStringPropertyWidth(itextcomponent);
        int j = i;
        int k = this.getFontRenderer().getStringWidth(": ");

        for (Score score : collection) {
            ScorePlayerTeam scoreplayerteam = scoreboard.getPlayersTeam(score.getPlayerName());
            ITextComponent itextcomponent1 = ScorePlayerTeam.formatPlayerName(scoreplayerteam,
                    new StringTextComponent(score.getPlayerName()));
            list1.add(Pair.of(score, itextcomponent1));
            j = Math.max(j, this.getFontRenderer().getStringPropertyWidth(itextcomponent1) + k
                    + this.getFontRenderer().getStringWidth(Integer.toString(score.getScorePoints())));
        }

        int i2 = collection.size() * 9;
        int j2 = this.scaledHeight / 2 + i2 / 3;
        int k2 = 3;
        int l2 = this.scaledWidth - j - 3;
        int l = 0;
        int i1 = this.mc.gameSettings.getTextBackgroundColor(0.3F);
        int j1 = this.mc.gameSettings.getTextBackgroundColor(0.4F);


        int витч = j + 6;
        int хеич = collection.size() * 9 + 10;
        int Xc = this.scaledWidth - totalWidth - 3;
        int Yc= j2 - totalHeight + 5;

        if(Demure.getInstance().getFunctionRegistry().getCustomScoreBoard().isState()) {

            if (CustomScoreBoard.bluyr.get()) {
                GaussianBlur.startBlur();
                DisplayUtils.drawRoundedRect(Xc  + 3,Yc - 7, витч, хеич + 4, 3, ColorUtils.rgba(0,0,0,100));
                GaussianBlur.endBlur(3,1);
            }
            DisplayUtils.drawRoundedRect(Xc + 3,Yc - 7, витч, хеич + 4, 3, ColorUtils.rgba(0,0,0,100));

            DisplayUtils.drawRoundedRectOutline(Xc + 3, Yc - 7, витч, хеич + 4, 3, 2, ColorUtils.getColor(0));
        }
        for (Pair<Score, ITextComponent> pair : list1) {
            ++l;
            Score score1 = pair.getFirst();
            ITextComponent itextcomponent2 = pair.getSecond();
            String s = TextFormatting.RED + "" + score1.getScorePoints();
            int k1 = j2 - l * 9;
            int l1 = this.scaledWidth - 3 + 2;

            if(!Demure.getInstance().getFunctionRegistry().getCustomScoreBoard().isState()){
                fill(p_238447_1_, l2 - 2, k1, l1, k1 + 9, i1);
            }

            this.getFontRenderer().func_243248_b(p_238447_1_, itextcomponent2, (float) l2, (float) k1, -1);
            this.getFontRenderer().drawString(p_238447_1_, s, (float) (l1 - this.getFontRenderer().getStringWidth(s)),
                    (float) k1, -1);

            if (l == collection.size()) {
                if(!Demure.getInstance().getFunctionRegistry().getCustomScoreBoard().isState()){
                    fill(p_238447_1_, l2 - 2, k1 - 9 - 1, l1, k1 - 1, j1);
                    fill(p_238447_1_, l2 - 2, k1 - 1, l1, k1, i1);
                }

                this.getFontRenderer().func_243248_b(p_238447_1_, itextcomponent, (float) (l2 + j / 2 - i / 2),
                        (float) (k1 - 9), -1);
            }
        }
    }

Далее создаем по пути im.expensive.functions.impl.render класс CustomScoreBoard с таким кодом
CustomScoreBoard.java:
Expand Collapse Copy
package fun.demure.functions.impl.render;

import fun.demure.functions.api.Category;
import fun.demure.functions.api.Function;
import fun.demure.functions.api.FunctionRegister;
import fun.demure.functions.settings.impl.BooleanSetting;

@FunctionRegister(name = "CustomScoreBoard", type = Category.Render)
public class CustomScoreBoard extends Function {
    public static final BooleanSetting bluyr = new BooleanSetting("Блюр", true);

    public CustomScoreBoard(){
        addSettings(bluyr);
    }
}

И регаем его в FunctionRegistry.java

Все! Ваш кастом боард готов.
Посмотреть вложение 309151

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

Блюр, оутлайн рект, и тд заменяйте на свое
Прикольная задумка , +rep :seemsgood:
 
Годно, но оутлайн и блюр легко вроде бы, надо сделать замену анки именно , это будет полезнее в разы
 
Итак, приступим

Заходим в IngameGui.java
Ищем метод func_238447_a_ или же renderScoreboard

Заменяем на это

IngameGui.java:
Expand Collapse Copy
private void func_238447_a_(MatrixStack p_238447_1_, ScoreObjective p_238447_2_) {
        EventCancelOverlay eventCancelOverlay = new EventCancelOverlay(EventCancelOverlay.Overlays.SCOREBOARD);
        Demure.getInstance().getEventBus().post(eventCancelOverlay);

        if (eventCancelOverlay.isCancel()) {
            eventCancelOverlay.open();
            return;
        }

        Scoreboard scoreboard = p_238447_2_.getScoreboard();
        Collection<Score> collection = scoreboard.getSortedScores(p_238447_2_);
        List<Score> list = collection.stream().filter((p_lambda$renderScoreboard$1_0_) -> {
            return p_lambda$renderScoreboard$1_0_.getPlayerName() != null
                    && !p_lambda$renderScoreboard$1_0_.getPlayerName().startsWith("#");
        }).collect(Collectors.toList());

        if (list.size() > 15) {
            collection = Lists.newArrayList(Iterables.skip(list, collection.size() - 15));
        } else {
            collection = list;
        }

        List<Pair<Score, ITextComponent>> list1 = Lists.newArrayListWithCapacity(collection.size());
        ITextComponent itextcomponent = p_238447_2_.getDisplayName();
        int i = this.getFontRenderer().getStringPropertyWidth(itextcomponent);
        int j = i;
        int k = this.getFontRenderer().getStringWidth(": ");

        for (Score score : collection) {
            ScorePlayerTeam scoreplayerteam = scoreboard.getPlayersTeam(score.getPlayerName());
            ITextComponent itextcomponent1 = ScorePlayerTeam.formatPlayerName(scoreplayerteam,
                    new StringTextComponent(score.getPlayerName()));
            list1.add(Pair.of(score, itextcomponent1));
            j = Math.max(j, this.getFontRenderer().getStringPropertyWidth(itextcomponent1) + k
                    + this.getFontRenderer().getStringWidth(Integer.toString(score.getScorePoints())));
        }

        int i2 = collection.size() * 9;
        int j2 = this.scaledHeight / 2 + i2 / 3;
        int k2 = 3;
        int l2 = this.scaledWidth - j - 3;
        int l = 0;
        int i1 = this.mc.gameSettings.getTextBackgroundColor(0.3F);
        int j1 = this.mc.gameSettings.getTextBackgroundColor(0.4F);


        int витч = j + 6;
        int хеич = collection.size() * 9 + 10;
        int Xc = this.scaledWidth - totalWidth - 3;
        int Yc= j2 - totalHeight + 5;

        if(Demure.getInstance().getFunctionRegistry().getCustomScoreBoard().isState()) {

            if (CustomScoreBoard.bluyr.get()) {
                GaussianBlur.startBlur();
                DisplayUtils.drawRoundedRect(Xc  + 3,Yc - 7, витч, хеич + 4, 3, ColorUtils.rgba(0,0,0,100));
                GaussianBlur.endBlur(3,1);
            }
            DisplayUtils.drawRoundedRect(Xc + 3,Yc - 7, витч, хеич + 4, 3, ColorUtils.rgba(0,0,0,100));

            DisplayUtils.drawRoundedRectOutline(Xc + 3, Yc - 7, витч, хеич + 4, 3, 2, ColorUtils.getColor(0));
        }
        for (Pair<Score, ITextComponent> pair : list1) {
            ++l;
            Score score1 = pair.getFirst();
            ITextComponent itextcomponent2 = pair.getSecond();
            String s = TextFormatting.RED + "" + score1.getScorePoints();
            int k1 = j2 - l * 9;
            int l1 = this.scaledWidth - 3 + 2;

            if(!Demure.getInstance().getFunctionRegistry().getCustomScoreBoard().isState()){
                fill(p_238447_1_, l2 - 2, k1, l1, k1 + 9, i1);
            }

            this.getFontRenderer().func_243248_b(p_238447_1_, itextcomponent2, (float) l2, (float) k1, -1);
            this.getFontRenderer().drawString(p_238447_1_, s, (float) (l1 - this.getFontRenderer().getStringWidth(s)),
                    (float) k1, -1);

            if (l == collection.size()) {
                if(!Demure.getInstance().getFunctionRegistry().getCustomScoreBoard().isState()){
                    fill(p_238447_1_, l2 - 2, k1 - 9 - 1, l1, k1 - 1, j1);
                    fill(p_238447_1_, l2 - 2, k1 - 1, l1, k1, i1);
                }

                this.getFontRenderer().func_243248_b(p_238447_1_, itextcomponent, (float) (l2 + j / 2 - i / 2),
                        (float) (k1 - 9), -1);
            }
        }
    }

Далее создаем по пути im.expensive.functions.impl.render класс CustomScoreBoard с таким кодом
CustomScoreBoard.java:
Expand Collapse Copy
package fun.demure.functions.impl.render;

import fun.demure.functions.api.Category;
import fun.demure.functions.api.Function;
import fun.demure.functions.api.FunctionRegister;
import fun.demure.functions.settings.impl.BooleanSetting;

@FunctionRegister(name = "CustomScoreBoard", type = Category.Render)
public class CustomScoreBoard extends Function {
    public static final BooleanSetting bluyr = new BooleanSetting("Блюр", true);

    public CustomScoreBoard(){
        addSettings(bluyr);
    }
}

И регаем его в FunctionRegistry.java

Все! Ваш кастом боард готов.
Посмотреть вложение 309151

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

Блюр, оутлайн рект, и тд заменяйте на свое
ебать у тебя рендер помойный
Годно, но оутлайн и блюр легко вроде бы, надо сделать замену анки именно , это будет полезнее в разы
там стринг тупо менять кент
 
Итак, приступим

Заходим в IngameGui.java
Ищем метод func_238447_a_ или же renderScoreboard

Заменяем на это

IngameGui.java:
Expand Collapse Copy
private void func_238447_a_(MatrixStack p_238447_1_, ScoreObjective p_238447_2_) {
        EventCancelOverlay eventCancelOverlay = new EventCancelOverlay(EventCancelOverlay.Overlays.SCOREBOARD);
        Demure.getInstance().getEventBus().post(eventCancelOverlay);

        if (eventCancelOverlay.isCancel()) {
            eventCancelOverlay.open();
            return;
        }

        Scoreboard scoreboard = p_238447_2_.getScoreboard();
        Collection<Score> collection = scoreboard.getSortedScores(p_238447_2_);
        List<Score> list = collection.stream().filter((p_lambda$renderScoreboard$1_0_) -> {
            return p_lambda$renderScoreboard$1_0_.getPlayerName() != null
                    && !p_lambda$renderScoreboard$1_0_.getPlayerName().startsWith("#");
        }).collect(Collectors.toList());

        if (list.size() > 15) {
            collection = Lists.newArrayList(Iterables.skip(list, collection.size() - 15));
        } else {
            collection = list;
        }

        List<Pair<Score, ITextComponent>> list1 = Lists.newArrayListWithCapacity(collection.size());
        ITextComponent itextcomponent = p_238447_2_.getDisplayName();
        int i = this.getFontRenderer().getStringPropertyWidth(itextcomponent);
        int j = i;
        int k = this.getFontRenderer().getStringWidth(": ");

        for (Score score : collection) {
            ScorePlayerTeam scoreplayerteam = scoreboard.getPlayersTeam(score.getPlayerName());
            ITextComponent itextcomponent1 = ScorePlayerTeam.formatPlayerName(scoreplayerteam,
                    new StringTextComponent(score.getPlayerName()));
            list1.add(Pair.of(score, itextcomponent1));
            j = Math.max(j, this.getFontRenderer().getStringPropertyWidth(itextcomponent1) + k
                    + this.getFontRenderer().getStringWidth(Integer.toString(score.getScorePoints())));
        }

        int i2 = collection.size() * 9;
        int j2 = this.scaledHeight / 2 + i2 / 3;
        int k2 = 3;
        int l2 = this.scaledWidth - j - 3;
        int l = 0;
        int i1 = this.mc.gameSettings.getTextBackgroundColor(0.3F);
        int j1 = this.mc.gameSettings.getTextBackgroundColor(0.4F);


        int витч = j + 6;
        int хеич = collection.size() * 9 + 10;
        int Xc = this.scaledWidth - totalWidth - 3;
        int Yc= j2 - totalHeight + 5;

        if(Demure.getInstance().getFunctionRegistry().getCustomScoreBoard().isState()) {

            if (CustomScoreBoard.bluyr.get()) {
                GaussianBlur.startBlur();
                DisplayUtils.drawRoundedRect(Xc  + 3,Yc - 7, витч, хеич + 4, 3, ColorUtils.rgba(0,0,0,100));
                GaussianBlur.endBlur(3,1);
            }
            DisplayUtils.drawRoundedRect(Xc + 3,Yc - 7, витч, хеич + 4, 3, ColorUtils.rgba(0,0,0,100));

            DisplayUtils.drawRoundedRectOutline(Xc + 3, Yc - 7, витч, хеич + 4, 3, 2, ColorUtils.getColor(0));
        }
        for (Pair<Score, ITextComponent> pair : list1) {
            ++l;
            Score score1 = pair.getFirst();
            ITextComponent itextcomponent2 = pair.getSecond();
            String s = TextFormatting.RED + "" + score1.getScorePoints();
            int k1 = j2 - l * 9;
            int l1 = this.scaledWidth - 3 + 2;

            if(!Demure.getInstance().getFunctionRegistry().getCustomScoreBoard().isState()){
                fill(p_238447_1_, l2 - 2, k1, l1, k1 + 9, i1);
            }

            this.getFontRenderer().func_243248_b(p_238447_1_, itextcomponent2, (float) l2, (float) k1, -1);
            this.getFontRenderer().drawString(p_238447_1_, s, (float) (l1 - this.getFontRenderer().getStringWidth(s)),
                    (float) k1, -1);

            if (l == collection.size()) {
                if(!Demure.getInstance().getFunctionRegistry().getCustomScoreBoard().isState()){
                    fill(p_238447_1_, l2 - 2, k1 - 9 - 1, l1, k1 - 1, j1);
                    fill(p_238447_1_, l2 - 2, k1 - 1, l1, k1, i1);
                }

                this.getFontRenderer().func_243248_b(p_238447_1_, itextcomponent, (float) (l2 + j / 2 - i / 2),
                        (float) (k1 - 9), -1);
            }
        }
    }

Далее создаем по пути im.expensive.functions.impl.render класс CustomScoreBoard с таким кодом
CustomScoreBoard.java:
Expand Collapse Copy
package fun.demure.functions.impl.render;

import fun.demure.functions.api.Category;
import fun.demure.functions.api.Function;
import fun.demure.functions.api.FunctionRegister;
import fun.demure.functions.settings.impl.BooleanSetting;

@FunctionRegister(name = "CustomScoreBoard", type = Category.Render)
public class CustomScoreBoard extends Function {
    public static final BooleanSetting bluyr = new BooleanSetting("Блюр", true);

    public CustomScoreBoard(){
        addSettings(bluyr);
    }
}

И регаем его в FunctionRegistry.java

Все! Ваш кастом боард готов.
Посмотреть вложение 309151

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

Блюр, оутлайн рект, и тд заменяйте на свое
норм
 
прикольно
 
Обратите внимание, пользователь заблокирован на форуме. Не рекомендуется проводить сделки.
Какое значение
totalHeight
totalWidht?
 
Обратите внимание, пользователь заблокирован на форуме. Не рекомендуется проводить сделки.
Назад
Сверху Снизу