optimize scripts for !=win