Render the icon behind the reload/charge animation

This commit is contained in:
Sollace 2020-10-09 13:00:14 +02:00
parent 5152f7a4d3
commit 4d8c41fa8b

View file

@ -64,6 +64,9 @@ class Slot {
// background // background
UHud.drawTexture(matrices, 0, 0, textureU, textureV, size, size, 128, 128); UHud.drawTexture(matrices, 0, 0, textureU, textureV, size, size, 128, 128);
uHud.renderAbilityIcon(matrices, abilities.getStat(bSwap ? bSlot : aSlot), slotPadding / 2, slotPadding / 2, iconSize, iconSize, iconSize, iconSize);
if (cooldown > 0 && cooldown < 1) { if (cooldown > 0 && cooldown < 1) {
float lerpCooldown = MathHelper.lerp(tickDelta, cooldown, lastCooldown); float lerpCooldown = MathHelper.lerp(tickDelta, cooldown, lastCooldown);
@ -85,7 +88,6 @@ class Slot {
protected void renderContents(MatrixStack matrices, AbilityDispatcher abilities, boolean bSwap, float tickDelta) { protected void renderContents(MatrixStack matrices, AbilityDispatcher abilities, boolean bSwap, float tickDelta) {
// contents // contents
uHud.renderAbilityIcon(matrices, abilities.getStat(bSwap ? bSlot : aSlot), slotPadding / 2, slotPadding / 2, iconSize, iconSize, iconSize, iconSize);
UHud.drawTexture(matrices, 0, 0, backgroundU, backgroundV, size, size, 128, 128); UHud.drawTexture(matrices, 0, 0, backgroundU, backgroundV, size, size, 128, 128);
} }