View Single Post
02-14-14, 09:04 PM   #25
Aanson
A Flamescale Wyrmkin
Join Date: Aug 2009
Posts: 124
Originally Posted by pelf View Post
Alright, I see the reason for both, now. I just got thrown off by the talk about "the color used by the last message" instead of just looking up the color once you have the chat type.

Incidentally, what is the chat type of a message that gets added like this?
Code:
DEFAULT_CHAT_FRAME:AddMessage("Hello, world.")
Does is it end up as "SAY", even though it isn't?

@Phanx
After ChatTypeGroup is defined, a reverse lookup table is created called ChatTypeGroupInverted. Couldn't that be used instead of the one you created in your code? The output is the key into ChatTypeInfo, so I assume it could be.
I'm not sure what it would default to actually.

I'd just assumed that Phanx had written it that way to avoid global table lookups all the time.
__________________
__________________
  Reply With Quote