I'm getting some goofy issues with color formatting and combining strings in zo_strformat.
Lua Code:
changeColor = SomeColor1:ToHex -- Convert user defined color for context color (currency gain or loss)
currencyTypeColor = SomeColor2:ToHex -- Convert user defined color for type of currency.
currencyIcon = "|t16:16:/esoui/art/currency/alliancepoints.dds|t"
currencyName = "Gold" -- Variable for name of currency.
changeType = ZO_LocalizeDecimalNumber("VARIABLE HERE FOR CURRENCY AMOUNT") -- # of currency gained or lost.
messageUnformatted = "You deposit <<1>> in your bank." -- User defined Saved Variable for message format.
Lua Code:
currencyString = ("|r|c" .. currencyTypeColor .. currencyIcon .. " " .. changeType .. currencyName .. "|r|c" .. changeColor)
combine = zo_strformat(messageUnformatted, currencyString)
d(zo_strformat("|c<<1>><<2>>|r", changeColor, combine)
This outputs:
For some reason with certain color values when a ZO_LocalizeDecimalNumber variable has a comma added to it, the color formatting breaks. I tried removing other values here, but the only thing that fixes it is removing the trailing color formatting.
Is there some additional formatting ZO_LocalizeDecimalNumber is doing that could interfere with the color code? Or is the manner in which I'm combining several strings here outside of the intended scope for the usage of zo_strformat?
EDIT: Colors here for reference are:
0b610b (Green)
b30000 (Red)