Here's a thought: would the wind direction change if you, for instance, did something like:
0 setovercast 0
~0.001
0 setovercast 1
If it were changed to a random direction each time you did the above, then you could add a check to see what that direction is, via the drop command. Then you could just keep repeating until you had the desired wind direction. Just a thought, but perhaps it would work?