str GetColorCodeAt(str s, int i)
Returns the full text of the colorcode at position i. If there is no colorcode, returns an empty string. Shorthand for StrSlice(s, i, SkipColorCodeAt(s, i));
Print all colorcodes in a string:
int len = StrLen(s);
int i = 0;
while (i < len)
{
str cc = GetColorCodeAt(s, i);
if (!StrIsEmpty(cc))
print(s:StrSlice(cc, 1, StrLen(cc)));
i += StrLen(cc);
}