A few comments... sme of which have already been said.
Your SetTime and WriteValue() requires additional rights. You should use the W32tm sevice to sync time and policies to RunLogonScriptSync.
Why do you need to set all those environment vars? WinSet.exe is not needed for Wintendos if using the current version of KiX.
You should include the /Persistent switch with:
Use "*" /DELETE /Persistent
The If InGroup() statements don't need the = 1 on the end.
All the USE commands should have quotes around the paths.
There are two ENDIFs that don't have corresponding IFs.
The CALL should include a full path or @ScriptDir before the filename.
Restructure your IF statements to avoid GOTOs.
_________________________
Give a man a fish and he will be back for more. Slap him with a fish and he will go away forever.