Skip to content

Commit

Permalink
Fix half-drawer render glitch
Browse files Browse the repository at this point in the history
  • Loading branch information
jaquadro committed May 31, 2015
1 parent bdd3759 commit 63ab644
Showing 1 changed file with 25 additions and 4 deletions.
29 changes: 25 additions & 4 deletions src/com/jaquadro/minecraft/storagedrawers/block/BlockDrawers.java
Original file line number Diff line number Diff line change
Expand Up @@ -499,7 +499,7 @@ public IIcon getIcon (int side, int meta) {
switch (side) {
case 0:
case 1:
return halfDepth ? iconSideV[meta] : iconSide[meta];
return halfDepth ? iconSideH[meta] : iconSide[meta];
case 2:
case 3:
return halfDepth ? iconSideV[meta] : iconSide[meta];
Expand Down Expand Up @@ -560,16 +560,37 @@ else if (drawerCount == 2)
switch (tile.getDirection()) {
case 2:
case 3:
case 4:
case 5:
return (level > 0) ? iconOverlayH[level] : iconSideH[meta];
}
}
break;
case 2:
case 3:
if (halfDepth) {
switch (tile.getDirection()) {
case 2:
case 3:
return (level > 0) ? iconOverlay[level] : iconSide[meta];
case 4:
case 5:
return (level > 0) ? iconOverlayV[level] : iconSideV[meta];
}
}
break;
default:
if (halfDepth)
return (level > 0) ? iconOverlayV[level] : iconSideV[meta];
case 4:
case 5:
if (halfDepth) {
switch (tile.getDirection()) {
case 2:
case 3:
return (level > 0) ? iconOverlayV[level] : iconSideV[meta];
case 4:
case 5:
return (level > 0) ? iconOverlay[level] : iconSide[meta];
}
}
break;
}

Expand Down

0 comments on commit 63ab644

Please sign in to comment.