2013-12-27 16:59:59 -06:00
|
|
|
package appeng.client.texture;
|
|
|
|
|
2014-05-07 20:54:28 -05:00
|
|
|
import net.minecraft.init.Blocks;
|
2014-02-08 19:34:52 -06:00
|
|
|
import net.minecraft.util.IIcon;
|
2013-12-27 16:59:59 -06:00
|
|
|
|
|
|
|
public class TmpFlipableIcon extends FlipableIcon
|
|
|
|
{
|
|
|
|
|
2014-05-07 20:54:28 -05:00
|
|
|
private static final IIcon nullIcon = new MissingIcon( Blocks.diamond_block );
|
|
|
|
|
2013-12-27 16:59:59 -06:00
|
|
|
public TmpFlipableIcon() {
|
2014-05-07 20:54:28 -05:00
|
|
|
super( nullIcon );
|
2013-12-27 16:59:59 -06:00
|
|
|
}
|
|
|
|
|
2014-02-08 19:34:52 -06:00
|
|
|
public void setOriginal(IIcon i)
|
2013-12-27 16:59:59 -06:00
|
|
|
{
|
2014-08-10 00:15:14 -05:00
|
|
|
setFlip( false, false );
|
|
|
|
|
2013-12-27 16:59:59 -06:00
|
|
|
while (i instanceof FlipableIcon)
|
2014-08-10 00:15:14 -05:00
|
|
|
{
|
|
|
|
FlipableIcon fi = (FlipableIcon) i;
|
|
|
|
if ( fi.flip_u )
|
|
|
|
this.flip_u = !this.flip_u;
|
|
|
|
|
|
|
|
if ( fi.flip_v )
|
|
|
|
this.flip_v = !this.flip_v;
|
|
|
|
|
|
|
|
i = fi.getOriginal();
|
|
|
|
}
|
2013-12-27 16:59:59 -06:00
|
|
|
|
2014-05-07 20:54:28 -05:00
|
|
|
if ( i == null )
|
|
|
|
original = nullIcon;
|
|
|
|
else
|
|
|
|
original = i;
|
2013-12-27 16:59:59 -06:00
|
|
|
}
|
|
|
|
|
|
|
|
}
|