Skip to content

Commit

Permalink
Fixed texture sprites not rendering correctly
Browse files Browse the repository at this point in the history
  • Loading branch information
Sollace committed Nov 19, 2024
1 parent 93e1697 commit 3e87809
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
import com.minelittlepony.common.client.gui.dimension.Bounds;
import net.minecraft.client.gui.DrawContext;
import net.minecraft.client.render.RenderLayer;
import net.minecraft.util.Colors;
import net.minecraft.util.Identifier;

public class TextureSprite implements ISprite {
Expand Down Expand Up @@ -52,10 +53,10 @@ public void render(DrawContext context, int x, int y, int mouseX, int mouseY, fl
RenderLayer::getGuiTextured,
texture,
x + bounds.left, y + bounds.top,
0,
textureBounds.left, textureBounds.top,
bounds.width, bounds.height,
textureBounds.width, textureBounds.height);
textureBounds.width, textureBounds.height,
Colors.WHITE);
}

@Override
Expand Down

0 comments on commit 3e87809

Please sign in to comment.