TwitchAnnounce

Sends a Twitch chat message using either Twitch Broadcaster or Twitch Bot account

Signature

public void TwitchAnnounce(string message, bool bot = false, string color, bool fallback = false)

Parameters

message
string required

Enter the message contents

bot
bool
Default:
False

No description provided.

color
string

Select the color for the announcement. Valid values are:

  • default – Standard color
  • blue
  • green
  • orange
  • purple
fallback
bool
Default:
False
  • true - (If bot bool is set to True), this is the same behaviour as if you had Bot as your preferred account.
  • false - (If bot bool is set to True), it will try to send using only the Bot account, and do nothing if it can't (i.e, not logged in).

Return Type

void

Example

using System;
public class CPHInline
{
    public bool Execute()
    {
        //Set message for chat
        string message = "This is an announcement";

        //Send announcement with bot account, or fallback to broadcaster
        CPH.TwitchAnnounce(message, true, color, true); 
        return true;
    }
}