You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Add the TikTok Live Connector component to your game
Set the ttl_uri ConVar to a EulerStream WebSocket URI
It should roughly look like wss://ws.eulerstream.com?uniqueId=tv_asahi_news&apiKey=API_KEY_HERE
Run the Game
Example Component:
usingMinima.TikTokLive;publicclassTikTokExample:Component,ITikTokLiveEvents{voidITikTokLiveEvents.OnChat(WebcastChatMessagemsg){if(msg.Useris not {}user)return;Log.Info($"[{user.Nickname}]: {msg.Comment}");}voidITikTokLiveEvents.OnGift(WebcastGiftMessagemsg){if(msg.Useris not {}user||msg.GiftDetailsis not {}giftDetails)return;Log.Info($"[{user.Nickname}] sent a gift {giftDetails.GiftName} worth {giftDetails.DiamondCount} diamonds");}voidITikTokLiveEvents.OnLike(WebcastLikeMessagemsg){if(msg.Useris not {}user)return;Log.Info($"[{user.Nickname}] liked the stream {msg.LikeCount} times.");}voidITikTokLiveEvents.OnSubNotify(WebcastSubNotifyMessagemsg){if(msg.Useris not {}user)return;Log.Info($"[{user.Nickname}] subscribed to the stream.");}voidITikTokLiveEvents.OnSocialMessage(WebcastSocialMessagemsg){if(msg.Useris not {}user)return;if(msg.MessageKind==WebcastSocialMessage.Kind.Follow)Log.Info($"[{user.Nickname}] followed the stream.");elseif(msg.MessageKind==WebcastSocialMessage.Kind.Share)Log.Info($"[{user.Nickname}] shared the stream.");}voidITikTokLiveEvents.OnMemberMessage(WebcastMemberMessagemsg){if(msg.Useris not {}user)return;if(msg.MessageKind==WebcastMemberMessage.Kind.Join)Log.Info($"[{user.Nickname}] joined the stream.");}}
About
A simple library that allows you to develop S&Box experiences that integrate with TikTok Live