Начинающий
Начинающий
- Статус
- Оффлайн
- Регистрация
- 16 Дек 2023
- Сообщения
- 634
- Реакции
- 9
- Выберите загрузчик игры
- OptiFine
Сделал скид один в один,с такой же анимацией и прочей херью.
Код:
} else if (type.get("Celestial")) {
width = 170 / 1.5f;
height = 57 / 1.5f;
headSize = 32;
float alphaAnimationValue = (float) alphaAnimation.getValue();
int alpha = (int) (255 * alphaAnimationValue);
int shadowAlpha = (int) (255 * alphaAnimationValue);
DisplayUtils.drawShadow(posX, posY, width, height, 6, ColorUtils.setAlpha(handlerClient().getThemeManager().getCurrent().getColor(), shadowAlpha));
DisplayUtils.drawRoundedOutline(posX, posY, width, height, 5,-0.3f, ColorUtils.setAlpha(ColorUtils.rgb(8, 15, 28), alpha), Vec4i.copy(ColorUtils.setAlpha(handlerClient().getThemeManager().getCurrent().getColor(), shadowAlpha)));
float headCenterX = posX + 4 + headSize / 2f;
float headCenterY = posY + height / 2f;
RoundHeadUtils.drawHead(entity, headCenterX, headCenterY, headSize, headSize, 3, alphaAnimationValue, hurtAnimation);
float lineX = posX + headSize + spacing + 2;
float testY = (posY - 1);
float testW = width;
float testH = Fonts.celestial[17].getFontHeight();
ScissorUtil.enable();
ScissorUtil.setFromComponentCoordinates(lineX, testY + 6, testW - 40, testH);
Fonts.celestial[17].drawString(event.getMatrixStack(), getDisplayName(entity), lineX, (posY - 1) + spacing + 3, ColorUtils.setAlpha(-1, alpha));
ScissorUtil.unset();
ScissorUtil.disable();
float healthY = posY + height - spacing - 14;
String healthText = (entity.isInvisible() && isFT()) ? "HP: Неизвестно" : String.format("HP: %.1f", healthTextAnimation).replace(',', '.');
Fonts.celestial[13].drawString(event.getMatrixStack(), healthText, lineX, healthY, ColorUtils.setAlpha(-1, alpha));
float barWidth = width - (headSize + spacing * 2);
float barY = posY + height - spacing * 2 - 2.5f;
DisplayUtils.drawRoundedRect(lineX - 1, barY, barWidth, 8, 2, ColorUtils.setAlpha(ColorUtils.rgb(35, 35, 35), alpha));
DisplayUtils.drawRoundedRect(lineX - 1, barY, barWidth * healthBarAnimation, 7.5f, 2, ColorUtils.setAlpha(handlerClient().getThemeManager().getCurrent().getColor(), (int) (200 * alphaAnimationValue)));