Reading this script I've noticed several problems:
1. It uses the dll function PrivateExtractIcons which "
is not intended for general use. It may be altered or unavailable in subsequent versions of Windows"
see
msdn
2. It doesn't take into account character codification and so tooltips dont display anything or just the first character or else display gibberish
3. It uses double derefs incorreclty in the function "Tray" and so all variables end up being globals (which is not the intended behavior) see
this topic