Rename the Ref methods that share a name with vanilla methods
WindowRef.getWidth/getHeight and ItemStackRef.isEmpty/getMaxDamage match methods of the classes they're mixed into, so the mixins can't implement them explicitly. With Mojang's names, Window.getWidth is also the framebuffer's width rather than the window's. They're now getWindowWidth/getWindowHeight and isEmptyStack/getMaxItemDamage (with getItemDamage to match). Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
@@ -20,9 +20,9 @@ public class ImageTexture extends Element {
|
||||
if (sprite.toString().endsWith(".svg")) {
|
||||
MinecraftClientRef client = Providers.saturn.getClient();
|
||||
|
||||
int renderWidth = (int) (width * client.getWindow().getFramebufferWidth() / client.getWindow().getWidth());
|
||||
int renderWidth = (int) (width * client.getWindow().getFramebufferWidth() / client.getWindow().getWindowWidth());
|
||||
int renderHeight = (int) (height * client.getWindow().getFramebufferHeight()
|
||||
/ client.getWindow().getHeight());
|
||||
/ client.getWindow().getWindowHeight());
|
||||
|
||||
IdentifierRef pngId = SvgTexture.getSvg(sprite, renderWidth * 2, renderHeight * 2);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user