public static void sendItemContainer(Player p, int interfaceID, int child, int type, Container<Item> items) {
		MessageBuilder bldr = new MessageBuilder(255, PacketType.VAR_SHORT);
		bldr.writeShort(interfaceID);
		bldr.writeShort(child);
		bldr.writeShort(type);
		bldr.writeShort(items.getSize());
		for(Item i : items.getItems()) {
			int id = -1;
			int am = 0;
			if(i != null) {
				id = i.getItemId();
				am = i.getItemAmount();
			}
			if(am > 254) {
				bldr.writeByteS(255);
				bldr.writeInt2(am);
			} else {
				bldr.writeByteS(am);
			}
			bldr.writeLEShort(id + 1);
		}
		p.getSession().getChannel().write(bldr.toMessage());
	}