fixes  an error in a for loop variable that had a wide variety of undesired side effects
Merge pull request #3 from virtual-world-framework/branch/fix-loop-control-variable

Cherry-pick forgotten commit that fixes loop control variable