ensure it fits in the actual array. fixes N64 binaries from triggering later panic. move the panic check itself into a common function that is called from a couple of new places too.