Wow is that the global namespace? Hmm that's really really interesting.
/script function CountGlobals(m) local t,j,k,i=getfenv(0),0,0 for i in t do j=j+1 if string.find(i,"^"..m) then k=k+1 end end DEFAULT_CHAT_FRAME:AddMessage(j.." entries in getfenv(0). Beginning with \""..m.."\":"..k) end
Then:
/script CountGlobals("Name or start of name of mod here")
34776 entries in getfenv(0). Beginning with "Gatherer":741
34776 entries in getfenv(0). Beginning with "Recap":1353
34776 entries in getfenv(0). Beginning with "CT_":4849
34775 entries in getfenv(0). Beginning with "ItemRack":1217
34777 entries in getfenv(0). Beginning with "BankStatement":1007
34777 entries in getfenv(0). Beginning with "Titan":789
34777 entries in getfenv(0). Beginning with "TITAN":436
34777 entries in getfenv(0). Beginning with "Atlas":80
Printing out the list, the XML stuff creates a ton of globals. But then my mods are pretty heavily involved in the XML.
This is fun stuff. I fear it becoming another "metric" to mods tho lol. I don't wanna make my mods slash-driven
I enjoy playing with the xml hehe