aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/gregtech/common/render/GT_IconFlipped.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/gregtech/common/render/GT_IconFlipped.java')
-rw-r--r--src/main/java/gregtech/common/render/GT_IconFlipped.java17
1 files changed, 14 insertions, 3 deletions
diff --git a/src/main/java/gregtech/common/render/GT_IconFlipped.java b/src/main/java/gregtech/common/render/GT_IconFlipped.java
index c3eee2900f..d4f96fed4f 100644
--- a/src/main/java/gregtech/common/render/GT_IconFlipped.java
+++ b/src/main/java/gregtech/common/render/GT_IconFlipped.java
@@ -11,6 +11,8 @@ public class GT_IconFlipped implements IIcon {
private final boolean flipV;
public GT_IconFlipped(IIcon baseIcon, boolean flipU, boolean flipV) {
+ if(baseIcon == null)
+ System.out.println("HI");
this.baseIcon = baseIcon;
this.flipU = flipU;
this.flipV = flipV;
@@ -19,6 +21,7 @@ public class GT_IconFlipped implements IIcon {
/**
* Returns the width of the icon, in pixels.
*/
+ @Override
public int getIconWidth() {
return this.baseIcon.getIconWidth();
}
@@ -26,6 +29,7 @@ public class GT_IconFlipped implements IIcon {
/**
* Returns the height of the icon, in pixels.
*/
+ @Override
public int getIconHeight() {
return this.baseIcon.getIconHeight();
}
@@ -33,6 +37,7 @@ public class GT_IconFlipped implements IIcon {
/**
* Returns the minimum U coordinate to use when rendering with this icon.
*/
+ @Override
public float getMinU() {
return this.flipU ? this.baseIcon.getMaxU() : this.baseIcon.getMinU();
}
@@ -40,6 +45,7 @@ public class GT_IconFlipped implements IIcon {
/**
* Returns the maximum U coordinate to use when rendering with this icon.
*/
+ @Override
public float getMaxU() {
return this.flipU ? this.baseIcon.getMinU() : this.baseIcon.getMaxU();
}
@@ -47,14 +53,16 @@ public class GT_IconFlipped implements IIcon {
/**
* Gets a U coordinate on the icon. 0 returns uMin and 16 returns uMax. Other arguments return in-between values.
*/
+ @Override
public float getInterpolatedU(double p_94214_1_) {
- float f = this.getMaxU() - this.getMinU();
+ final float f = this.getMaxU() - this.getMinU();
return this.getMinU() + f * ((float) p_94214_1_ / 16.0F);
}
/**
* Returns the minimum V coordinate to use when rendering with this icon.
*/
+ @Override
public float getMinV() {
return this.flipV ? this.baseIcon.getMaxV() : this.baseIcon.getMinV();
}
@@ -62,6 +70,7 @@ public class GT_IconFlipped implements IIcon {
/**
* Returns the maximum V coordinate to use when rendering with this icon.
*/
+ @Override
public float getMaxV() {
return this.flipV ? this.baseIcon.getMinV() : this.baseIcon.getMaxV();
}
@@ -69,12 +78,14 @@ public class GT_IconFlipped implements IIcon {
/**
* Gets a V coordinate on the icon. 0 returns vMin and 16 returns vMax. Other arguments return in-between values.
*/
+ @Override
public float getInterpolatedV(double p_94207_1_) {
- float f = this.getMaxV() - this.getMinV();
+ final float f = this.getMaxV() - this.getMinV();
return this.getMinV() + f * ((float) p_94207_1_ / 16.0F);
}
+ @Override
public String getIconName() {
return this.baseIcon.getIconName();
}
-} \ No newline at end of file
+}