Allow the formspec to adapt to inventories smaller than 32, for compatibility with various mods