fix bug where it was not syncing inv

This commit is contained in:
Raoul Van den Berge
2015-12-26 01:41:22 +01:00
parent 487fcb3cbe
commit f4ccd1e2ec
4 changed files with 4 additions and 2 deletions

View File

@@ -156,6 +156,7 @@ public abstract class GuiBase extends GuiContainer
{ {
font = stack.getItem().getFontRenderer(stack); font = stack.getItem().getFontRenderer(stack);
} }
if (font == null) if (font == null)
{ {
font = fontRendererObj; font = fontRendererObj;

View File

@@ -149,6 +149,6 @@ public class InventorySimple implements IInventory
@Override @Override
public IChatComponent getDisplayName() public IChatComponent getDisplayName()
{ {
return null; // @TODO: ... return null;
} }
} }

View File

@@ -105,6 +105,7 @@ public class MessageStoragePush implements IMessage, IMessageHandler<MessageStor
else else
{ {
player.inventory.setInventorySlotContents(message.slot, null); player.inventory.setInventorySlotContents(message.slot, null);
player.openContainer.detectAndSendChanges();
} }
} }
} }

View File

@@ -68,7 +68,7 @@ public class InventoryUtils
} }
} }
public static void dropStack(World world, ItemStack stack, int x, int y, int z) // @TODO: Take BlockPos here public static void dropStack(World world, ItemStack stack, int x, int y, int z)
{ {
float xo = world.rand.nextFloat() * 0.8F + 0.1F; float xo = world.rand.nextFloat() * 0.8F + 0.1F;
float yo = world.rand.nextFloat() * 0.8F + 0.1F; float yo = world.rand.nextFloat() * 0.8F + 0.1F;