more makecube diagnostic stuff - fix indexing bugs