You want to call ZO_ColorDef.FromInterfaceColor instead of ZO_ColorDef:FromInterfaceColor as this is the definition:
function ZO_ColorDef.FromInterfaceColor(colorType, fieldValue)
return ZO_ColorDef:New(GetInterfaceColor(colorType, fieldValue))
edit: too slow...
Originally Posted by Enodoc
Anyone able to assist with the cause of a couple of UI Errors?
Checking type on argument interfaceColorType failed in GetInterfaceColor_lua
[C]: in function 'GetInterfaceColor'
EsoUI/Libraries/Utility/ZO_ColorDef.lua:46: in function 'ZO_ColorDef.FromInterfaceColor'
user:/AddOns/CyrodiilAlert/CyrodiilAlert.lua:134: in function 'CA.Initialise'
user:/AddOns/CyrodiilAlert/CyrodiilAlert.lua:210: attempt to index a nil value
user:/AddOns/CyrodiilAlert/CyrodiilAlert.lua:210: in function 'CA.InitKeeps'
EsoUI/Libraries/Globals/globalapi.lua:195: in function '(anonymous)'
This is line 210:
local initText = zo_strformat(CA.colOng:Colorize(GetString(SI_CYRODIIL_ALERT_INIT_TEXT)))
I haven't changed these lines for months and as far as I can remember it was all working fine on PTS. Based on the ESOUI Wiki, line 134 should be fine, as ZO_ColorDef:FromInterfaceColor still exists, as do the constants INTERFACE_COLOR_TYPE_KEEP_TOOLTIP and KEEP_TOOLTIP_COLOR_ACCESSIBLE, and I don't know what is nil in 210 as CA.colOng is defined in line 138 as
CA.colOng = ZO_ColorDef:New(0.84,0.4,0.05,1)
and the string SI_CYRODIIL_ALERT_INIT_TEXT is defined in my lang file: