mirror of
https://github.com/EssentialsX/Essentials.git
synced 2024-12-27 03:28:30 +01:00
Fixes for graphical /recipe issues. Closes #134
- Fixed shaped recipe ItemStacks displaying 0s - Fixed recipes supporting any data value of blocks missing textures
This commit is contained in:
parent
9307f9b9c1
commit
046752f8c2
@ -90,7 +90,9 @@ public class Commandrecipe extends EssentialsCommand {
|
||||
if (item == null) {
|
||||
continue;
|
||||
}
|
||||
item.setAmount(0);
|
||||
if (item.getDurability() == Short.MAX_VALUE) {
|
||||
item.setDurability((short) 0);
|
||||
}
|
||||
view.getTopInventory().setItem(j * 3 + k + 1, item);
|
||||
}
|
||||
}
|
||||
@ -129,7 +131,11 @@ public class Commandrecipe extends EssentialsCommand {
|
||||
user.setRecipeSee(true);
|
||||
final InventoryView view = user.getBase().openWorkbench(null, true);
|
||||
for (int i = 0; i < ingredients.size(); i++) {
|
||||
view.setItem(i + 1, ingredients.get(i));
|
||||
final ItemStack item = ingredients.get(i);
|
||||
if (item.getDurability() == Short.MAX_VALUE) {
|
||||
item.setDurability((short) 0);
|
||||
}
|
||||
view.setItem(i + 1, item);
|
||||
}
|
||||
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user