You can directly split the string and use ArrayGetCount to allocate the memory of the MCColor array