code: function getPiecesLeft() {
      $.getJSON("/games/" + enc($.cookie("game")) +
                "/pieces", function(data) {
          $(GAMEPIECES).empty();
          var npieces = 0;
          for (var i in data)
              npieces += data[i].count;
          $(GAMEPIECES).html(npieces);
      });
  }
docs: Publish the number of pieces left in the bag.