Fix wayward global k
Add housekeeping to track distance we can skip to the next sprite. Nice optimization win