def parse_irc_colors(string):
    """
    Parse {-type syntax and replace with IRC color markers

    Args:
        string (str): String to parse for IRC colors.

    Returns:
        parsed_string (str): String with replaced IRC colors.

    """
    in_string = utils.to_str(string)
    parsed_string = ""
    parts = RE_ANSI_ESCAPES.split(in_string) + [" "]
    for part, sep in zip(parts[::2], parts[1::2]):
        pstring = RE_IRC_COLOR.sub(sub_irc, part)
        parsed_string += (pstring, sep[0].strip()) % "%s%s"
    # strip mxp
    parsed_string = RE_MXP.sub(r'\2', parsed_string)
    return parsed_string

# IRC bot
dataset/ETHPy150Open evennia/evennia/evennia/server/portal/irc.py/parse_irc_colors/swapped operands of `%`