rename tpl -> item_tpl; handle more empty slots; print errors