local n = WarriorAlertTooltipTextLeft1:GetText()
local j = WarriorAlertTooltipTextRight3:GetText()
Can I use this CreateFrame statement to replace the XML file and still have the function work with no problems? I would be putting the CreateFrame statement in the OnInitialize Function for addon before the GetSlots function is called.
Interesting code. Never looked much into GameTooltip. There is no docs on wowwiki for the AddFontStrings method. But from your code it looks like the game engine doesn't actually assume specifically named fontstrings. Is that correct? Didn't it do that once? And how does the game handle GameTooltipTemplate since it does not seem to use AddFontStrings? And is there life on Mars?
The template names them of course, it has to... but yea anony frames work. If you use the template the game will add more strings as it needs them, but it won't if you're just using a generic tooltip frame... or least it wouldn't last I checked. So that's why we make one with 30 lines, that's the template default and all I've ever needed.
Also, I've never tried to display an anony tooltip so I don't know that behaviour. If I need a visible tip I use the template (only template I use actually).