You can short-circuit this loop entirely if dirSim == dirMax after the above loop.  This happens when the rename is just a file rename within the same directory, in which case you can just set dirScoreLtr and dirScoreRtl to 100.