Solves the inconsistent direction problem
These are all versions of this script. Show only the versions where the code changed.