Move dests cell-list of destinations to code/main.m
Fix bound correction for nextPos to use h and w