Skip to content

Commit

Permalink
Draw sprite fixes (#4027)
Browse files Browse the repository at this point in the history
* Update drawSprite methods to match scaling

* Update draw sprite region

* Fix lint
  • Loading branch information
kevinthegreat1 authored Oct 16, 2024
1 parent b891b45 commit 4eca8e4
Showing 1 changed file with 14 additions and 4 deletions.
18 changes: 14 additions & 4 deletions mappings/net/minecraft/client/gui/DrawContext.mapping
Original file line number Diff line number Diff line change
Expand Up @@ -367,32 +367,42 @@ CLASS net/minecraft/class_332 net/minecraft/client/gui/DrawContext
ARG 6 height
ARG 7 color
METHOD method_52708 drawGuiTexture (Ljava/util/function/Function;Lnet/minecraft/class_2960;IIIIIIII)V
COMMENT Draws a textured rectangle from a region in a gui texture.
COMMENT
COMMENT <p>The width and height of the region are the same as
COMMENT the dimensions of the rectangle.
ARG 1 renderLayers
ARG 2 sprite
ARG 3 textureWidth
COMMENT the width of the entire texture
ARG 4 textureHeight
COMMENT the height of the entire texture
ARG 5 u
COMMENT the x starting position of the region in the texture
ARG 6 v
COMMENT the y starting position of the region in the texture
ARG 7 x
ARG 8 y
ARG 9 width
COMMENT the width of the drawn rectangle and of the region in the texture
ARG 10 height
METHOD method_52709 drawSprite (Ljava/util/function/Function;Lnet/minecraft/class_1058;IIII)V
COMMENT the height of the drawn rectangle and of the region in the texture
METHOD method_52709 drawSpriteStretched (Ljava/util/function/Function;Lnet/minecraft/class_1058;IIII)V
ARG 1 renderLayers
ARG 2 sprite
ARG 3 x
ARG 4 y
ARG 5 width
ARG 6 height
METHOD method_52710 drawSprite (Ljava/util/function/Function;Lnet/minecraft/class_1058;IIIII)V
METHOD method_52710 drawSpriteStretched (Ljava/util/function/Function;Lnet/minecraft/class_1058;IIIII)V
ARG 1 renderLayers
ARG 2 sprite
ARG 3 x
ARG 4 y
ARG 5 width
ARG 6 height
ARG 7 color
METHOD method_52711 drawSprite (Ljava/util/function/Function;Lnet/minecraft/class_1058;IIIIIIIII)V
METHOD method_52711 drawSpriteRegion (Ljava/util/function/Function;Lnet/minecraft/class_1058;IIIIIIIII)V
ARG 1 renderLayers
ARG 2 sprite
ARG 3 textureWidth
Expand All @@ -418,7 +428,7 @@ CLASS net/minecraft/class_332 net/minecraft/client/gui/DrawContext
ARG 11 textureWidth
ARG 12 textureHeight
ARG 13 color
METHOD method_52713 drawSprite (Ljava/util/function/Function;Lnet/minecraft/class_1058;Lnet/minecraft/class_8690$class_8691;IIIII)V
METHOD method_52713 drawSpriteNineSliced (Ljava/util/function/Function;Lnet/minecraft/class_1058;Lnet/minecraft/class_8690$class_8691;IIIII)V
ARG 1 renderLayers
ARG 2 sprite
ARG 3 nineSlice
Expand Down

0 comments on commit 4eca8e4

Please sign in to comment.