if (%var == 1) { echo -a do this }
else echo -a do that

the %var is set to 1 .. then u halted ur script.. but if set to 2, then it shouldent halt..