As the title says, i want my targets name to be shorten if the name is to long, like Raider's Training Dummy would become R. T. Dummy.
I found a thread on MMO about this and a guy said that this would do it ->
Originally Posted by Code
function(unit)
local name = UnitName(unit) or unit
name = name:gsub('(%S+) ',function(t) return t:sub(1,1)..'.' end)
return name
end
|
I do however don't have a clue what to do with this text, im quessing i should paste it in to stufs text.lua somewhere?
Could anyone give me som help with this? I really suck at this
I also wonder how it would look if i want the name to be class colored?
Thanks!