When I run through the loop attempting to class color the client locks and logs me out. Anyone have some insight for me?
Also, is there a better way to do class coloring? I'd prefer not to have to add a certain upcoming hero class to the addon and not have to change the coloring table when blizz decides to change paladin and shaman coloring. Thanks :)
You can, however, intercept the message before it gets to the ChatFrame and color it on your client.
See events: CHAT_MSG_WHISPER, CHAT_MSG_PARTY, CHAT_MSG_RAID, CHAT_MSG_GUILD, CHAT_MSG_SAY, CHAT_MSG_YELL, and CHAT_MSG_CHANNEL (ref: WoWWiki). Getting the class of the sender will be next to impossible given that Blizz delays /who lookups, but if they are on your friends list, party, raid, or guild, it won't be a problem.