IEventsclass

Implement this on a `Component` to receive stream chat events. They're dispatched to the active scene on the main thread, so it's safe to touch GameObjects from these.

object→IEvents
Namespace
global
Assembly
Sandbox.Engine
Declaration
public abstract interface Sandbox.Streamer.IEvents

Methods7

Showing 7 methods

public virtual void OnStreamJoin(Sandbox.Streamer.Viewer viewer)PUBLICVIRTUAL

A viewer joined chat.

ParameterTypeDescription
viewerViewer—
Returns:void—

public virtual void OnStreamLeave(Sandbox.Streamer.Viewer viewer)PUBLICVIRTUAL

A viewer left chat. Note that Twitch sends leaves unreliably, so don't count on this firing.

ParameterTypeDescription
viewerViewer—
Returns:void—

public virtual void OnStreamMessage(Sandbox.Streamer.ChatMessage message)PUBLICVIRTUAL

A chat message was received. Cheers arrive here too - check `Sandbox.Streamer.ChatMessage.Bits`.

ParameterTypeDescription
messageChatMessage—
Returns:void—

public virtual void OnStreamRaid(Sandbox.Streamer.RaidMessage message)PUBLICVIRTUAL

Another channel raided yours, bringing their viewers with them.

ParameterTypeDescription
messageRaidMessage—
Returns:void—

public virtual void OnStreamSubscribe(Sandbox.Streamer.SubscribeMessage message)PUBLICVIRTUAL

A viewer subscribed or resubscribed to the channel.

ParameterTypeDescription
messageSubscribeMessage—
Returns:void—

On this page