In the presence of a local var, set -g alters the local var without affecting the global var. This also affects the -u0 switch, causing the global var to not be unset after the script.

There is no change regardless whether or not the -gu0 switches are used.

Code:
//set %a Global | var %a Local | echo -a %a / $var(%a,0) | set -gu0 %a Global2 | echo -a %a $var(%a,1).local $var(%a,1).value / $var(%a,2).local $var(%a,2).value | .timer 1 0 echo 5 -a % $+ a