Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
…into twitch-name-color
  • Loading branch information
lexonegit committed Jan 23, 2023
2 parents 083d915 + b4b5e54 commit 3b49a59
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions Unity-Twitch-Chat/Assets/Package/Runtime/IRC.cs
Original file line number Diff line number Diff line change
Expand Up @@ -279,5 +279,19 @@ private void BlockingDisconnect()
if (showIRCDebug)
Debug.Log($"{Tags.alert} Disconnected from Twitch IRC");
}

/// <summary>
/// Sends a chat message to the channel
/// </summary>
/// <param name="message">The message to send</param>
public void SendChatMessage(string message)
{
if (useAnonymousLogin)
{
Debug.LogWarning("Chat messages cannot be sent with anonymous login");
return;
}
connection.SendChatMessage(message);
}
}
}

0 comments on commit 3b49a59

Please sign in to comment.