~v1 is the difference between Torque's and the enemy's y-coordinates, offset by -2.

~v2 is the difference between Torque's and the enemy's x-coordinates.

This line finds whether the enemy is on Torque's perimeter. , by checking for -1 < ~v2 < 1 and -3 < ~v1 < -1.

Also, there is an if value #enemy_x <> 0 so that it does not recieve a false result from a cloaked enemy.

Lastly there is an if value ~v9 = ~v9 for the following reason: When AI Wars is in the process of being updated, there are lots of beta versions, and aspects of the game change. In this case, the introduction of cloaking meant that there had to be a decision on whether a cloaked enemy's coordinates would be 0 or whether the coordinates would be those of the next-closest enemy. While this was still being decided, Shea put this statement in so that if necessary, he could add a statement to this line using a simple copy and replace. If no extra statements were needed, then this code doesn't affect the operation of Torque in any way, so it just gets left in.